cancel
Showing results for 
Search instead for 
Did you mean: 

Rerun Pipeline until success

eric_sou
New Contributor III

Hi guys,
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.
Thanks,

2 REPLIES 2

eguo
Former Employee

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:

Pre-requisites:

  1. The pipeline in question is parameterizable
  2. 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 ... This means that the existing way that you schedule this pipeline will need to be changed a little bit.

Sample pipelines:

  1. Example pipeline in question with pipeline parameters image
  2. 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.
    image image
  3. The pipeline that takes a ruuid, read the captured the parameters from the runtime history and rerun the same pipeline with the captured parameters.
    image image image

Here’s what you would see in the Dashboard for the testing:
image

As a general discussion, I am not going into the detail of how do you define successfulness.

Job-DoSomething_2017_09_19 (1).slp (2.4 KB)
Runtime-List_2017_09_19.slp (4.6 KB)
pipeRerunByRuuid_2017_09_19.slp (5.7 KB)

eric_sou
New Contributor III

Thanks eguo, another good and well described answer from your side.
Let me review this.
Thanks,