Re: Fwd: How to run upstream and downstream jobs on same executor

2021-04-05 Thread Gianluca Massera
ete  and also  not to occupied executor unnecessarily. Thanks On Mon, 5 Apr, 2021, 8:49 pm Gianluca Massera, <mailto:gmax...@gmail.com>> wrote: Hi, from what I know, it's not achievable. When a job is waiting for a downstream to complete, it keeps an executor

Re: Fwd: How to run upstream and downstream jobs on same executor

2021-04-05 Thread Gianluca Massera
Hi, from what I know, it's not achievable. When a job is waiting for a downstream to complete, it keeps an executor occupied. So, the downstream job needs to run on a different executor. But, frankly, that seems more of https://xyproblem.info/ :-) So, what is your problem? what do you need?

Re: Restart from stage

2021-03-23 Thread Gianluca Massera
Hi, I use the following code to walk through all stages of the pipeline for a different reason but it could be an hint for you to achieve your goal: WorkflowRun run = prevBuild.getRawBuild() NodeGraphBuilder graphBuilder = NodeGraphBuilder.NodeGraphBuilderFactory.getInstance(run);  def flowN

Re: Restart from stage

2021-03-22 Thread Gianluca Massera
Hi what-ever-is-your-name-:-) I use the "when" block to run only specific stages depending on the parameters: https://www.jenkins.io/doc/book/pipeline/syntax/#when I hope that fits your case too. Cheers, Gianluca. On 22/03/2021 22:47, unlimh...@gmail.com wrote: Are there any examples of th

Re: Execute a function from post actions in Jenkinsfile

2020-12-20 Thread Gianluca Massera
Hi, I'm not sure I understood your issue on calling functions. Maybe there is only a bit of confusion about the Jenkins pipeline syntax. From what you said, you are already calling functions into the post sections: "cleanWs()" is a function, "emailext body: ... " is a function. So, maybe yo