-
Notifications
You must be signed in to change notification settings - Fork 39.8k
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
Fix scheduler cache panic when updating pod condition #56733
Fix scheduler cache panic when updating pod condition #56733
Conversation
@davidopp or @timothysc Could one of you guys add 1.7 milestone to this PR please? |
plugin/pkg/scheduler/scheduler.go
Outdated
@@ -270,16 +270,21 @@ func (sched *Scheduler) scheduleOne() { | |||
|
|||
// Tell the cache to assume that a pod now is running on a given node, even though it hasn't been bound yet. | |||
// This allows us to keep scheduling without waiting on binding to occur. | |||
assumedPod := *pod | |||
podCopy, err := api.Scheme.DeepCopy(pod) |
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.
Could you add a comment to why you are doing this, it's totally non-obvious.
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.
Done.
834b823
to
d1513ca
Compare
/retest |
@timothysc or @davidopp could one of you lgtm this? I think we should merge this ASAP. |
/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: bsalamat, timothysc, wojtek-t Associated issue: #56730 The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these OWNERS Files:
You can indicate your approval by writing |
/retest Review the full test history for this PR. |
2 similar comments
/retest Review the full test history for this PR. |
/retest Review the full test history for this PR. |
/retest |
/test all [submit-queue is verifying that this PR is safe to merge] |
Automatic merge from submit-queue. |
What this PR does / why we need it:
This PR fixes an issue in the scheduler code which could cause a cache panic. More details are given in the referenced issue.
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when PR gets merged):Fixes #56730
Special notes for your reviewer:
Release note:
/sig scheduling