-
Notifications
You must be signed in to change notification settings - Fork 64
update only running AWs #562
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
update only running AWs #562
Conversation
all test cases pass locally |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm confused about what we are trying to do here. Some things I notice:
- In line 1467 we check if the
newjob
exists in theeventQueue
, if it does then we continue. If it doesn't exist, then we will eventually get to line 1476 and delete it from theeventQueue
, even though it doesn't exists there. - Line 1478 adds
newjob
back in the event queue
So ok. If the job exists in the event
queue or job
queue then nothing happens, if it doesn't then it deletes it (maybe) and adds it to the event
queue. I'm not sure what this is supposed to accomplish. In the previous version there were some changes to the newjob
object, but this one doesn't. I just want to make sure I understand the logic of this function.
Thanks for the review @metalcycling , Multiple threads compete to add objects to the event queue, we want to make sure updatequeuejob thread adds the latest object from etcd into the event queue, I agree this is a best-effort solution. |
There's a small nitpick with a log message that needs to be addressed and that prevents me from approving this PR. I think changes from this PR are long overdue. If this the nitpick is addressed and there are no other objections I will approve this on Monday. /LGTM |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: metalcycling The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Issue link
#561
What changes have been made
Verification steps
Checks