-
Notifications
You must be signed in to change notification settings - Fork 41.6k
Initialize pod resource allocation checkpoint manager to noop #116351
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
Initialize pod resource allocation checkpoint manager to noop #116351
Conversation
|
This issue is currently awaiting triage. If a SIG or subproject determines this is a relevant issue, they will accept it by applying the The Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
|
/assign @liggitt @SergeyKanzhelev |
|
/assign |
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 the reasoning from the PR description to the commit message too?
8be2947 to
ca52eb9
Compare
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.
Still nitting about the commit message 🙈 Could you wrap the commit message body and add a period to the end of the sentence?
ca52eb9 to
6ff9dde
Compare
This avoids accidentally introducing null pointer access if manager functions were called outside of InPlacePodVerticalScaling feature gate.
6ff9dde to
1e01358
Compare
|
ping @liggitt .. does this follow-up look good? |
|
it looks reasonable to me, would like a kubelet approver to ack |
|
/assign @SergeyKanzhelev @Random-Liu |
|
/release-note-none |
|
/lgtm |
|
LGTM label has been added. Git tree hash: aa890cb9d5908a0100e6c9d31f9e2f9e470b7ce5
|
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.
/approve
/lgtm
|
|
||
| func (m *manager) Start() { | ||
| // Initialize m.state to no-op state checkpoint manager | ||
| m.state = state.NewNoopStateCheckpoint() |
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.
nit: if we uncover more like this, it can be easier to put this in the else block below so when the feature graduates, we can be sure we just remove the else block.
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: derekwaynecarr, vinaykul 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 |
What type of PR is this?
/kind cleanup
What this PR does / why we need it: This change initializes pod resource allocation checkpoint manager to no-op in order to avoid accidentally introducing null pointer access if the manager functions were to be called outside of the InPlacePodVerticalScaling feature gate.
Ref: #116271 (comment)
Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
I tested this by commenting out the block that allocated real pod resource allocation manager and verified local-cluster in kubeletonly mode for a single static pod. Additionally, with code committed in this PR, I verified kubeletonly mode as well as pod resize tests with local cluster. Rest is for CI.
Does this PR introduce a user-facing change? No.
Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.: