IP Library Granted Patent US 12,229,137
Granted Patent B1
US 12,229,137 · App. 18/412,438 · Granted Feb 18, 2025

Checkpoint and restore based startup of executor nodes of a distributed computing engine for processing queries

Inventors: Xinyang Ge (Kirkland, WA); Lixiang Ao (Sunnyvale, CA); Haonan Jing (San Jose, CA); Aaron Daniel Davidson (Berkeley, CA)
Assignee: Databricks, Inc.
G06F16/24549G06F16/24542
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 12,229,137
App. No.
18/412,438
Granted
Feb 18, 2025
Kind
B1
Abstract

A system performs efficient startup of executors of a distributed computing engine used for processing queries, for example, database queries. The system starts an executor node and processes a set of queries using the executor node to warm up the executor node. The system performs a checkpoint of the warmed-up executor node to create an image. The image is restored in the target executor nodes. The system may store a checkpoint image for each configuration of an executor node. The configuration is determined based on various factors including the hardware of the executor node, memory allocation of the processes, and so on. The user or restore based on checkpoint images improves efficiency of execution of the startup of executor nodes.

Claims (56)

1. A method, comprising:

starting execution of one or more processes for processing queries in a source executor node of a distributed computing engine configured for receiving and processing queries, the one or more processes including a runtime execution engine of a programming language used for implementing instructions for the processing queries;

sending the queries to the source executor node for execution of the queries on the source executor node;

performing checkpoint of the one or more processes executing on the source executor node to generate a checkpoint image, wherein the execution of the queries on the source executor node causes just-in-time compilation of at least a portion of code used for the processing queries, the just-in-time compilation causing generation of native instructions for the source executor node, wherein the native instructions are stored in the checkpoint image;

storing the checkpoint image in a checkpoint image repository in the source executor node;

providing the checkpoint image from the checkpoint image repository to a plurality of target executor nodes of the distributed computing engine;

for each target executor node of the plurality of target executor nodes of the distributed computing engine, performing restore of checkpoint image to restore a check point image on said each target executor node of the plurality of target executor nodes based on the native instructions of the provided checkpoint image; and

processing additional queries using the plurality of target executor nodes in the distributed computing engine to perform operations related to creation of data structures after the performing the restore of checkpoint image.

2. The method of claim 1 , wherein the execution of the queries on the source executor node causes loading of classes used for execution of the queries, wherein the classes are stored in the checkpoint image.

3. The method of claim 1 , wherein the execution of the queries on the source executor node causes initialization of variables and creation of data structures used for processing the queries, wherein the variables and data structures are stored in the checkpoint image.

4. The method of claim 1 , wherein the checkpoint image repository stores a plurality of checkpoint images, each checkpoint image associated with a particular configuration of executor nodes.

5. The method of claim 4 , wherein a configuration of an executor node is associated with one or more of: a CPU (central processing unit) type of the executor node, an amount of memory allocation of the executor node, or a version of a particular software running on the executor node.

6. The method of claim 1 , further comprising:

generating a plurality of checkpoint images for a configuration of executor nodes, wherein different checkpoint images of the plurality of checkpoint images have different address space layouts.

7. The method of claim 1 , further comprising:

responsive to restoring the checkpoint image on a target executor node, modifying one of more random numbers used by instructions for processing queries.

8. The method of claim 1 , further comprising:

detecting a new configuration of an executor node;

triggering generation of a new checkpoint image corresponding to the new configuration; and

storing the new checkpoint image in the checkpoint image repository.

9. A non-transitory computer readable medium comprising stored instructions, the stored instructions when executed by at least one processor of one or more computing devices, cause the one or more computing devices to:

start execution of one or more processes for processing queries in a source executor node of a distributed computing engine configured for receiving and processing queries, the one or more processes including a runtime execution engine of a programming language used for implementing instructions for the processing queries;

send the queries to the source executor node for execution of the queries on the source executor node;

perform checkpoint of the one or more processes executing on the source executor node to generate a checkpoint image, wherein the execution of the queries on the source executor node causes just-in-time compilation of at least a portion of code used for the processing queries, the just-in-time compilation causing generation of native instructions for the source executor node, wherein the native instructions are stored in the checkpoint image;

store the checkpoint image in a checkpoint image repository in the source executor node;

provide the checkpoint image from the checkpoint image repository to a plurality of target executor nodes of the distributed computing engine;

for each target executor node of the plurality of target executor nodes of the distributed computing engine, perform restore of checkpoint image to restore a check point image on said each target executor node of the plurality of target executor nodes based on the native instructions of the provided checkpoint image; and

process additional queries using the plurality of target executor nodes in the distributed computing engine to perform operations related to creation of data structures after the performing the restore of checkpoint image.

10. The non-transitory computer readable medium of claim 9 , wherein the execution of the queries on the source executor node causes loading of classes used for execution of the queries, wherein the classes are stored in the checkpoint image.

11. The non-transitory computer readable medium of claim 9 , wherein the execution of the queries on the source executor node causes initialization of variables and creation of data structures used for processing the queries, wherein the variables and data structures are stored in the checkpoint image.

12. The non-transitory computer readable medium of claim 9 , wherein the checkpoint image repository stores a plurality of checkpoint images, each checkpoint image associated with a particular configuration of executor nodes.

13. The non-transitory computer readable medium of claim 12 , wherein a configuration of an executor node is associated with one or more of: a CPU (central processing unit) type of the executor node, an amount of memory allocation of the executor node, or a version of a particular software running on the executor node.

14. The non-transitory computer readable medium of claim 9 , the instructions causing the one or more computing devices to:

generate a plurality of checkpoint images for a configuration of executor nodes, wherein different checkpoint images of the plurality of checkpoint images have different address space layouts.

15. The non-transitory computer readable medium of claim 9 , the instructions causing the one or more computing devices to:

responsive to restoring the checkpoint image on a target executor node, modify one of more random numbers used by instructions for processing queries.

16. The non-transitory computer readable medium of claim 9 , the instructions causing the one or more computing devices to:

detect a new configuration of an executor node;

trigger generation of a new checkpoint image corresponding to the new configuration;

and store the new checkpoint image in the checkpoint image repository.

17. A computer system, comprising:

a computer processor; and

a non-transitory computer-readable storage medium comprising instructions that when executed by the computer processor, cause the computer system to:

start execution of one or more processes for processing queries in a source executor node of a distributed computing engine configured for receiving and processing queries, the one or more processes including a runtime execution engine of a programming language used for implementing instructions for the processing queries;

send the queries to the source executor node for execution of the queries on the source executor node;

perform checkpoint of the one or more processes executing on the source executor node to generate a checkpoint image, wherein the execution of the queries on the source executor node causes just-in-time compilation of at least a portion of code used for the processing queries, the just-in-time compilation causing generation of native instructions for the source executor node, wherein the native instructions are stored in the checkpoint image;

store the checkpoint image in a checkpoint image repository in the source executor node;

provide the checkpoint image from the checkpoint image repository to a plurality of target executor nodes of the distributed computing engine;

for each target executor node of the plurality of target executor nodes of the distributed computing engine, perform restore of checkpoint image to restore a check point image on said each target executor node of the plurality of target executor nodes based on the native instructions of the provided checkpoint image; and

process additional queries using the plurality of target executor nodes in the distributed computing engine to perform operations related to creation of data structures after the performing the restore of checkpoint image.

18. The computer system of claim 17 , wherein the instructions further cause the computer system to:

detect a new configuration of an executor node;

trigger generation of a new checkpoint image corresponding to the new configuration;

and store the new checkpoint image in the checkpoint image repository.

19. The computer system of claim 17 , wherein the execution of the queries on the source executor node causes loading of classes used for execution of the queries, wherein the classes are stored in the checkpoint image.

20. The computer system of claim 17 , wherein the execution of the queries on the source executor node causes initialization of variables and creation of data structures used for processing the queries, wherein the variables and data structures are stored in the checkpoint image.

Assignments (2)
SECURITY INTEREST Recorded Jan 6, 2025
From: DATABRICKS, INC.
To: JPMORGAN CHASE BANK, N.A., AS COLLATERAL AGENT
Reel/Frame 069825/0419 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Feb 9, 2024
From: GE, XINYANG; AO, LIXIANG; JING, HAONAN; DAVIDSON, AARON DANIEL
To: DATABRICKS, INC.
Reel/Frame 066423/0710 →
References Cited (13)
US 20120265875A1 · Moran · 2012 [cited by examiner]
US 20170193012A1 · Gupta · 2017 [cited by examiner]
US 20170371761A1 · Piga · 2017 [cited by examiner]
Amazon. “Amazon Athena for Apache Spark.” Amazon Web Services, Inc., Nov. 30, 2022, 7 pages, [Online] [Retrieved Aug. 27, 2024], Retrieved from the Internet <URL:https://aws.amazon.com/athena/spark/>. [cited by applicant]
Apache Spark. “Apache Spark: Unified Engine for Large-Scale Data Analytics.” Apache Software Foundation, Jul. 9, 2013, 9 pages, [Online] [Retrieved Aug. 27, 2024], Retrieved from the Internet <URL:https://spark.apache.o… [cited by applicant]
Chalios, B. “Firecracker Snapshotting.” Github.com, Jan. 5, 2021, 9 pages, [Online] [Retrieved Aug. 27, 2024], Retrieved from the Internet <URL:https://github.com/firecracker- microvm/firecracker/blob/main/docs/snapshot… [cited by applicant]
Cloudera. “Apache Spark Guide.” Cloudera, Inc., Version: CDH 6.3.x, Sep. 30, 2021, pp. 1-66. [cited by applicant]
Criu. “Checkpoint/Restore.” Checkpoint/Restore In Userspace, May 12, 2017, 3 pages, [Online] [Retrieved Aug. 27, 2024], Retrieved from the Internet <URL:https://criu.org/Checkpoint/Restore>. [cited by applicant]
Criu. “Memory Dumping and Restoring.” Checkpoint/Restore In Userspace, Feb. 5, 2019, 4 pages, [Online] [Retrieved Aug. 27, 2024], Retrieved from the Internet <URL:https://criu.org/Memory_dumping_and_restoring>. [cited by applicant]
Databricks. “Apache Spark: What is Apache Spark?” Databricks.com, Mar. 4, 2019, 6 pages, [Online] [Retrieved Aug. 27, 2024], Retrieved from the Internet <URL:https://www.databricks.com/glossary/what-is-apache-spark>. [cited by applicant]
Shin, W et al. “Fireworks: A Fast, Efficient, and Safe Serverless Framework Using VM-Level Post-JIT Snapshot.” Euro Sys '22, Rennes, France, Apr. 5-8, 2022, pp. 663-677. [cited by applicant]
Virtuoso, A. “Anthony (9baf) Virtuoso's Post.” LinkedIn, Nov. 30, 2022, 12 pages, [Online] [Retrieved Aug. 27, 2024], Retrieved from the Internet <URL:https://www.linkedin.com/posts/avirtuos_interactive-analytics-amazon… [cited by applicant]
Wikipedia. “Apache Spark.” Wikipedia: The Free Encyclopedia, Jun. 18, 2022, 9 pages, [Online] [Retrieved Aug. 27, 2024], Retrieved from the Internet <URL:https://en.wikipedia.org/wiki/Apache_Spark>. [cited by applicant]