Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Keep direct link to trigger in EventListener #365

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Jimilian
Copy link
Contributor

@Jimilian Jimilian commented May 23, 2018

It would speed up event processing a lot. As scanning all jobs and looking for trigger needs significant amount of time.

screen shot 2018-05-23 at 15 11 54

It would speed up event processing a lot. As scanning all jobs and
looking for trigger needs significant amount of time.
@rinrinne
Copy link
Member

Can this patch avoid an issue "Job was triggered by previous configuration" in race condition? As far as I know, Trigger object is not updated but generated whenever job configuration is applied. (Even if no changes in job configuration)

I remember that a member of Jenkins core team said "trigger object should not be stored outside of job instance".

@rsandell
Copy link
Member

We used to have it similar to this, but that caused all kinds of problems when holding on to the live instance and changed it to always do a lookup. The lookup shouldn't be that big of a deal since the ItemGroups has the jobs in a map, so it's not like we are iterating over all the jobs all the time. the only iteration done is over the triggers of that one job and that list should in practice always be in single digit length.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants