IP Library Granted Patent US 11,681,522
Granted Patent B2
US 11,681,522 · App. 17/507,652 · Granted Jun 20, 2023

Self-healing build pipelines for an application build process across distributed computer platforms

Inventors: Kalyan Chakravarthy Thatikonda (San Francisco, CA); Prabhjot Singh (San Francisco, CA)
Assignee: SALESFORCE, INC.
G06F8/71G06F9/541
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 11,681,522
App. No.
17/507,652
Granted
Jun 20, 2023
Kind
B2
Abstract

A self-healing build pipeline architecture for a software application build job across a distributed computer platform comprises a public API that receives configuration data describing the build job, stores the configuration data in a decentralized database, serves requests to/from a pipeline tracker API, and stores states of build pipelines during the build job. The decentralized database stores the configuration data and a project identifier for the build, and metadata regarding states of the build pipelines collected across the distributed computer platform. The pipeline tracker API runs local to the build environment in the distributed computer platform and sends a build status to public API for updating the decentralized database. For any failures in any of the build pipelines, the state is retrieved from the decentralize database and a new build pipeline is triggered locally that resumes from the failed state to provide a self-healing build pipeline architecture.

Claims (57)

1. A method comprising:

implementing a public application programming interface (API) for a build tool, the public API executing on one or more processors and capable of being configured to:

onboard one or more build pipelines from a user computer platform, including receiving configuration data for the one or more build pipelines, the configuration data comprising a description of a build job for a software application, including a retry limit, and a description of build environments of a distributed computer platform on which instances of the one or more build pipelines are to run, and

store a respective data map identifier for the build environments in a decentralized database; and

implementing one or more instances of a private tracker API that run local to the build environments of the distributed computer platform, the one or more instances of the private tracker API capable of being configured to:

assign a pipeline identifier for the one or more build pipelines and post the pipeline identifier to the public API for storage in the decentralized database based on the data map identifier of the build environments;

periodically post a status of the one or more build pipelines to the public API for storage in the decentralized database;

push build artifacts generated by the one or more build pipelines to an artifact repository;

during a failed state of the one or more build pipelines, trigger a new build pipeline that resumes from the failed state stored in the decentralized data-base; and

responsive to the one or more build environments being unable to provision the new build pipeline within the retry limit defined in the configuration data, send an exhaust retry request to the public API,

wherein the public API instructs the one or more instances of the pipeline tracker API on a different one or more build environments to trigger the new build pipe-line that resumes from the failed state stored in the decentralized database and to use the build artifacts stored in the artifact repository to avoid an entire rebuild of the one or more build pipelines.

2. The method of claim 1 , further comprising: configuring the one or more instances of the private tracker API to:

receive the configuration data for the build job;

assign a project identifier for the build job;

assign the respective data map identifier for the build environments; and

relay the configuration data to the public API.

3. The method of claim 1 , wherein trigger the new build pipeline further comprises: trigger the one or more build pipelines, by the instances of the private tracker API, to run on spot instances of the distributed computer platform, and if the build job completes successfully, sending a success message to the public API along with a pipeline identifier of the new build pipeline.

4. The method of claim 3 , further comprising the public API updating the decentralized database based on the corresponding pipeline identifier and the data map identifier of the build environment, and pushing any generated artifacts to the artifact repository.

5. The method of claim 1 , wherein responsive to the one or more build environment being unable to provision the new build pipeline further comprises: determining, by the instances of the private tracker API what the retry limit is by requesting the public API, to fetch the retry limit from the decentralized database.

6. The method of claim 1 , wherein responsive to the one or more build environments being unable to provision the new build pipeline further comprises: sending, by the one or more instances of the private tracker API, a number of attempted retries to the public API, which then compares the attempted number of retries to the retry limit stored in the decentralized database and provides a result to the private tracker API.

7. The method of claim 1 , wherein responsive to the one or more build environments being unable to provision the new build pipeline and the retry limit has been reached further comprises: configuring the private tracker API to send an exhaust retry signal to the public API that informs the public API that retry attempts have been exhausted on the one or more build environment and to search the decentralized database to find a different one or more build environments on which to resume triggering the new build pipeline.

8. The method of claim 7 , further comprising: responsive to the new build pipeline on the different one or more build environments failing, send another exhaust retry to the public API for the public API to search the decentralized database to find another of the one or more build environments on which to resume the new build pipeline.

9. The method of claim 1 , further comprising: once the one or more build pipelines are triggered during build execution, directly updating, by the public API, the decentralized database by: i) updating a pipeline status with a status of “Success,” “Retry,” or “Retry Exhaust”; and ii) updating a pipeline execution time with an actual execution time of the corresponding build pipeline.

10. A non-transitory machine-readable storage medium that provides instructions that, if executed by a processor, are configurable to cause said processor to perform operations comprising:

implement a public application programming interface (API) for a build tool, the public API executing on one or more processors and capable of being configured to:

onboard one or more build pipelines from a user computer platform, including receiving configuration data for the one or more build pipelines, the configuration data comprising a description of a build job for a software application, including a retry limit, and a description of build environments of a distributed computer platform on which instances of the one or more build pipelines are to run, and implement one or more instances of a private tracker API that run local to the build environments of the distributed computer platform, the one or more instances of the private tracker API capable of being configured to:

periodically post a status of the one or more build pipelines to the public API for storage in a decentralized database;

push build artifacts generated by the one or more build pipelines to an artifact repository;

during a failed state of the one or more build pipelines, triggering a new build pipeline that resumes from the failed state stored in the decentralized database; and

responsive to the one or more build environments being unable to provision the new build pipeline within the retry limit defined in the configuration data, send an exhaust retry request to the public API,

wherein the public API instructs the one or more instances of the pipeline tracker API on a different one or more build environments to trigger the new build pipeline that resumes from the failed state stored in the decentralized database and to use the corresponding build artifacts stored in the artifact repository to avoid an entire rebuild of the one or more build pipelines.

11. The non-transitory machine-readable storage medium of claim 10 , further comprising: configuring the public API to: assign a respective submission sub-folder in the artifact repository for a first build pipe-line; and when the first build pipeline generates an artifact on a local machine, save the artifact under the submission sub-folder assigned to the first build pipeline in the artifact repository.

12. The non-transitory machine-readable storage medium of claim 11 , further comprising: configuring the public API to: if the first build pipeline fails, retrieve the artifact generated by the first build pipeline from the submission sub-folder and send the artifact to the new build pipeline; and when the build pipeline completes, delete the artifact from the submission sub-folder.

13. The non-transitory machine-readable storage medium of claim 12 , further comprising: configuring the public API to:

if the new build job succeeds, merge the artifact to a main space in the artifact repository in a standard format.

14. The non-transitory machine-readable storage medium of claim 10 , further comprising: configuring the one or more instances of the private tracker API to:

receive the configuration data for the build job;

assign a pipeline identifier for the corresponding build pipeline;

assign a project identifier for the build job;

assign a respective data map identifier for the build environments; and

relay the configuration data, the pipeline identifier, the project identifier, and the respective data map identifiers to the public API for the onboarding.

15. The non-transitory machine-readable storage medium of claim 14 , wherein trigger the new build pipeline further comprises: trigger the build pipelines, by the instances of the private tracker API, to run on spot instances of the distributed computer platform, and if the build job completes successfully, sending a success message to the public API along with a pipeline identifier of the new build pipeline.

16. The non-transitory machine-readable storage medium of claim 15 , further comprising the public API updating the decentralized database based on the corresponding pipeline identifier and the data map identifier of the build environment, and pushing any generated artifacts to the artifact repository.

17. The non-transitory machine-readable storage medium of claim 10 , wherein responsive to the one or more build environment being unable to provision the new build pipeline further comprises: sending, by the one or more instances of the private tracker API, a number of attempted retries to the public API, which then compares the attempted number of retries to the retry limit stored in the decentralized database and provides a result to the private tracker API.

18. The non-transitory machine-readable storage medium of claim 10 , wherein responsive to the one or more build environment being unable to provision the new build pipeline and the retry limit has been reached further comprises: configuring the private tracker API to send an exhaust retry signal to the public API that informs the public API that retry attempts have been exhausted on the build environment and to search the decentralized database to find a different one or more build environments on which to resume the new build pipeline.

19. The non-transitory machine-readable storage medium of claim 18 , further comprising: responsive to the new build pipeline on the different one or more build environments failing, sending another exhaust retry to the public API for the public API to search the decentralized database to find another of the one or more build environments on which to resume the nre build pipeline.

20. An apparatus comprising:

a processor;

a non-transitory machine-readable storage medium that provides instructions that, if executed by the processor, are configurable to cause the apparatus to perform operations comprising,

implementing a public application programming interface (API) capable of being configured to:

onboard one or more build pipelines from a user computer platform, including receiving configuration data for the one or more build pipelines, the configuration data comprising a description of a build job for a software application, including a retry limit, and a description of build environments of a distributed computer platform on which instances of the one or more build pipelines are to run, and

implementing one or more instances of a private tracker API that run local to the one or more build environments of the distributed computer platform, the one or more instances of the private tracker API capable of being configured to:

periodically post a status of the corresponding one or more build pipelines to the public API for storage in a decentralized database;

push build artifacts generated by the one or more build pipelines to an artifact repository;

during a failed state of the build pipelines, triggering a new build pipeline that resumes from the failed state stored in the decentralized database; and

responsive to the one or more build environments being unable to provision the new build pipeline within the retry limit defined in the configuration data, send an exhaust retry request to the public API,

wherein the public API instructs the one or more instances of the pipeline tracker API on a different one of the or more build environments to trigger a-the new build pipeline that resumes from the failed state stored in the decentralized database and to use the build artifacts stored in the artifact repository to avoid an entire rebuild of the one or more build pipelines.

Assignments (2)
CHANGE OF NAME Recorded Oct 30, 2023
From: SALESFORCE.COM, INC.
To: SALESFORCE, INC.
Reel/Frame 065394/0169 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Nov 18, 2021
From: THATIKONDA, KALYAN CHAKRAVARTHY; SINGH, PRABHJOT
To: SALESFORCE.COM, INC.
Reel/Frame 058150/0268 →
Continuity (1)
Related Publication 20230129453A1 · Apr 27, 2023