Source Code Build Artifact Redeployment
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
In continuous integration systems, rolling back failed source code deployments is time-consuming and unreliable, as it typically requires creating a new build pipeline and rebuilding artifacts, which can lead to inconsistencies due to dependency version changes.
Innovation Solution
A method and system that allow redeploying a previous source code revision in a target environment without restarting the entire build pipeline, enabling the reuse of previously created artifacts and reducing the time and uncertainty associated with rolling back to a previous version.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If a new build pipeline is created to rollback failed deployments, then the deployment can be reverted to a previous version, but the process becomes time-consuming and unreliable due to rebuilding artifacts and dependency version changes
Solution Approach 1:
The system performs preliminary actions by creating and storing artifact representations (hashes, metadata) during the initial build process. These pre-prepared artifacts are stored in an artifact store, allowing rapid rollback without re-executing the build pipeline. When rollback is needed, the system simply retrieves the pre-stored artifact representation instead of rebuilding from scratch.
Solution Approach 2:
The system creates copies of build artifacts in the form of artifact representations (hashes, metadata, and actual artifacts) during the initial build. These copies are stored separately in an artifact store, enabling the rollback process to use these pre-existing copies rather than regenerating them. This copying mechanism eliminates the need to re-execute build steps during rollback.
2Stability of the object's composition
If the entire build pipeline is restarted for rollback, then a consistent deployment state can be achieved, but the complexity and duration of the rollback process increases
Solution Approach 1:
The build pipeline is segmented into distinct components: build execution, artifact generation, artifact storage, and artifact retrieval. The artifact store is separated from the build pipeline itself, allowing rollback operations to access historical artifacts without involving the build pipeline execution. This segmentation enables simple artifact retrieval for rollback without triggering complex build pipeline restarts.
Solution Approach 2:
The artifact store acts as an intermediary between the build pipeline and deployment processes. Instead of directly restarting the build pipeline for rollback, the system queries the artifact store for previous artifact representations and retrieves them. This intermediary layer simplifies the rollback process by decoupling it from the complex build pipeline execution.
3Reliability
If artifacts are rebuilt during rollback, then the latest dependency versions are used, but inconsistencies may arise and the process becomes unreliable
Solution Approach 1:
The system performs the dependency resolution and artifact creation actions preliminarily during the initial build process. The artifact representations stored in the artifact store capture the exact dependency versions used at build time. During rollback, these pre-captured dependency states are reused, ensuring consistency with the original build while avoiding the need to re-resolve dependencies, which could introduce variations.
Data Source
AI summary
Systems and methods for redeploying source code are disclosed. The method includes receiving a request for previewing redeployment of a selected source code deployment in a target environment. The request includes an identifier of the selected source code deployment and an identifier of the target environment. In addition, the method includes identifying a source code revision identifier of the selected source code deployment, and identifying a source code revision identifier of the latest source code deployment in the target environment. Based on this information, the method retrieves a list of source code revisions between the selected deployment and the latest deployment in the target environment. The retrieving is based on the source code revision identifiers of the selected source code deployment and the latest source code deployment. The method forwards the retrieved list of source code revisions to a client device for rendering on a display of the client device.


