Project

General

Profile

Bug #10903

Updated by Tom Clegg about 7 years ago

Extend the Job#cancel method to accept a "cascade: true" parameter. 

 Extend the jobs.cancel API to accept a "cascade=true" parameter. 

 Add a PipelineInstance#cancel method that accepts a "cascade: true" parameter (change to state=Paused if state is RunningOnServer or RunningOnClient; no-op if state is Paused; otherwise fail). 

 Add a pipeline_instances.cancel API that accepts a "cascade: true" parameter. 

 Update workbench to use the cascade=true flag when calling the jobs.cancel API. 

 Add a confirmation dialog which includes text warning that all unfinished child jobs will be canceled as well, even if well. Child (and descendants) jobs will be canceled regardless of whether they're also being used in queued by another job/pipeline. 

 Update Workbench to use Extend the pipeline_instances.cancel jobs#cancel API with cascade=true, instead of updating state to Paused. Add accept a confirmation dialog as with jobs. "cascade=true" parameter. 

 In Extend the model methods, if Job#cancel method to accept a "cascade: true" parameter. 

 If cascade: true is given, cancel any jobs listed in the pipeline instance's / job's components hash (subject to permissions), and propagate the @cascade:true@ cascade flag so an arbitrary number of generations of descendants can be cancelled. 

 Ensure the code cannot fall into an infinite loop or recursion (for example, make a test case where job A has job B in its components hash, and job B has job A in its components hash). 

 This is crunch1 only. Crunch2 already takes care of this. 

Back