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

fix: Use UUID as a precondition when calling the eviction API #998

Conversation

jonathan-innis
Copy link
Member

Fixes #N/A

Description

This change ensures that when we attempt to evict a pod, we don't accidentally evict a pod with a namespaced name that was recently re-created and shifted onto another node. This is particularly critical for StatefulSets, where pods can be re-created quickly with the same name.

How was this change tested?

make presubmit

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Feb 9, 2024
@k8s-ci-robot k8s-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Feb 9, 2024
@jonathan-innis jonathan-innis changed the title fix: Dequeue already evicted pods when calling the eviction API fix: Use UUID as a precondition when calling the eviction API Feb 9, 2024
@jonathan-innis jonathan-innis force-pushed the dequeue-already-evicted-pods branch 4 times, most recently from c8fbe26 to 733e091 Compare February 9, 2024 06:26
@coveralls
Copy link

coveralls commented Feb 9, 2024

Pull Request Test Coverage Report for Build 7849388308

  • 0 of 41 (100.0%) changed or added relevant lines in 1 file are covered.
  • 2 unchanged lines in 1 file lost coverage.
  • Overall coverage increased (+0.01%) to 80.577%

Files with Coverage Reduction New Missed Lines %
pkg/scheduling/requirements.go 2 97.59%
Totals Coverage Status
Change from base Build 7793658563: 0.01%
Covered Lines: 7932
Relevant Lines: 9844

💛 - Coveralls

Copy link
Contributor

@njtran njtran left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Super clean. Nice work. Just a couple of comments

Copy link
Contributor

@njtran njtran left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Feb 9, 2024
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jonathan-innis, njtran

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:
  • OWNERS [jonathan-innis,njtran]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot merged commit f7c5a89 into kubernetes-sigs:main Feb 9, 2024
12 checks passed
jonathan-innis added a commit to jonathan-innis/karpenter that referenced this pull request Feb 11, 2024
jonathan-innis added a commit to jonathan-innis/karpenter that referenced this pull request Feb 11, 2024
jonathan-innis added a commit to jonathan-innis/karpenter that referenced this pull request Feb 11, 2024
jonathan-innis added a commit to jonathan-innis/karpenter that referenced this pull request Feb 11, 2024
jonathan-innis added a commit to jonathan-innis/karpenter that referenced this pull request Feb 11, 2024
jigisha620 pushed a commit to jigisha620/karpenter that referenced this pull request Feb 16, 2024
jonathan-innis added a commit to jonathan-innis/karpenter that referenced this pull request Mar 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants