Would you know if it is possible, in case of scheduled pipeline run failure, to rerun it until it’s successful?
A Kind of retry until completes successful.
Yes. what you described can be done by a couple of pipelines utilizing Pipeline Monitoring API
The basic idea is to capture parameters in runtime history and rerun the failed pipeline with the captured parameters. This solution only work for a subset of the pipelines that meet following pre-requisites:
- The pipeline in question is parameterizable
- You need to check the Capture checkbox for the pipeline in question. Selecting this checkbox will send the value of the parameter to the pipeline runtime history if the pipeline is run through a task or another pipeline with PipeExecute or ForEach This means that the existing way that you schedule this pipeline will need to be changed a little bit.
- Example pipeline in question with pipeline parameters
- The pipeline used to discovery one or many failed pipelines within a given folder within last given hours. Output is a list of ruuids. In you case, you may use “Failed” as the state.
- The pipeline that takes a ruuid, read the captured the parameters from the runtime history and rerun the same pipeline with the captured parameters.
Here’s what you would see in the Dashboard for the testing:
As a general discussion, I am not going into the detail of how do you define successfulness.
Thanks eguo, another good and well described answer from your side.
Let me review this.