Hi,
From what I know, a job will keep an executor busy till it completes.
Hence, if an upstream job needs to do something after a downstream
completes, then Jenkins needs two executors.
Otherwise, if an upstream job doesn't need to anything after a
downstream completes, then you trigger a downstream with wait options
set to false and if there is only one executor Jenkins will queue the
downstream job till the upstream completes and the executor will be free
to run something else.
Is it clear?
Also, "waiting for something" even though doesn't need much CPU still
needs some processing power, hence you need an executor, hence is not
occupied unnecessarily ... it's occupied to do what you asked for: "wait
for something" ;-)
Hope that helps.
Cheers,
Gianluca.
On 05/04/2021 17:18, kamthe kirtee wrote:
Hi,
My question is if upstream job is running on executor 1 and when
downstream job is triggered, that should run on executor 1 or executor 2
As soon as downstream job started running, upstream job should not be
running on any of the executor.
Beacuse I don't want upstream job to wait for the downstream job to
complete
and also not to occupied executor unnecessarily.
Thanks
On Mon, 5 Apr, 2021, 8:49 pm Gianluca Massera, <gmax...@gmail.com
<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 occupied. So, the
downstream job needs to run on a different executor.
But, frankly, that seems more of https://xyproblem.info/
<https://xyproblem.info/> :-)
So, what is your problem? what do you need?
Cheers,
Gianluca.
On 05/04/2021 12:36, kamthe kirtee wrote:
---------- Forwarded message ---------
From: *kamthe kirtee* <kamthekirte...@gmail.com
<mailto:kamthekirte...@gmail.com>>
Date: Mon, 5 Apr, 2021, 4:36 pm
Subject: How to run upstream and downstream jobs on same executor
To: <jenkinsci-users+subscr...@googlegroups.com
<mailto:jenkinsci-users%2bsubscr...@googlegroups.com>>
Hi team,
Suppose in jenkins I have 1 slave and in that slave I have 1
executor
Also I have one upstream job and one downstream job
My question is:
If an upstream job is running on executor 1, and after that my
downstream job is starting on the same executor at the same time,
& I want upstream job to go aside/queue untill the downstream
job is over.
Once the downstream job is over, the paused upstream job should
again resume start running on the same executor.
So how We can achieve this? Because I don't want to increase the
number of executors
Can you please guide me for the same?
Thanks
--
You received this message because you are subscribed to the
Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it,
send an email to jenkinsci-users+unsubscr...@googlegroups.com
<mailto:jenkinsci-users+unsubscr...@googlegroups.com>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-users/CAD0fyGieWSsj%3DmAtLQEyuOkn0h5Y_q%2BGpf1oEZ%3DMKYfYS20mEw%40mail.gmail.com
<https://groups.google.com/d/msgid/jenkinsci-users/CAD0fyGieWSsj%3DmAtLQEyuOkn0h5Y_q%2BGpf1oEZ%3DMKYfYS20mEw%40mail.gmail.com?utm_medium=email&utm_source=footer>.
--
You received this message because you are subscribed to the Google
Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it,
send an email to jenkinsci-users+unsubscr...@googlegroups.com
<mailto:jenkinsci-users+unsubscr...@googlegroups.com>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-users/60c42944-94fb-b406-65d2-e5f905e81af6%40gmail.com
<https://groups.google.com/d/msgid/jenkinsci-users/60c42944-94fb-b406-65d2-e5f905e81af6%40gmail.com?utm_medium=email&utm_source=footer>.
--
You received this message because you are subscribed to the Google
Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to jenkinsci-users+unsubscr...@googlegroups.com
<mailto:jenkinsci-users+unsubscr...@googlegroups.com>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-users/CAD0fyGiVtQ5p%3DZGdNwaFTPXE6XJxVuEUvkXiJgv%3DF4hAGvb0vA%40mail.gmail.com
<https://groups.google.com/d/msgid/jenkinsci-users/CAD0fyGiVtQ5p%3DZGdNwaFTPXE6XJxVuEUvkXiJgv%3DF4hAGvb0vA%40mail.gmail.com?utm_medium=email&utm_source=footer>.
--
You received this message because you are subscribed to the Google Groups "Jenkins
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-users/3fd8068d-010e-a5e7-3992-ab26dd6721ed%40gmail.com.