Why workflow engine of Jenkins is designed in a continuation passing style way? Why workflow engine of Jenkins is designed in a continuation passing style way? jenkins jenkins

Why workflow engine of Jenkins is designed in a continuation passing style way?


The purpose of CPS is that a pipeline execution can be resumed after a Jenkins master restart.

During the execution of a pipeline, every single step executed by an agent is stored on the master (IIRC it was like 4 calls to the master per step).

As CPS is not compatible with all Groovy features, you sometimes have to disable it (or if you have a simple loop etc. and want to avoid the overhead introduced by CPS).