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

[WIP]feat: Add UserAnnotedExpiration as a new disruption method #845

Conversation

tasdikrahman
Copy link
Member

Fixes #688

This PR introduces a custom disruption method which is evaluating candidates which need to be deprovisioned, which have been added an annotation

karpenter.sh/voluntary-disruption=drifted

to the Node object.

How was this change tested?

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 do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Dec 7, 2023
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: tasdikrahman
Once this PR has been reviewed and has the lgtm label, please assign gjtempleton for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

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
Copy link
Contributor

Welcome @tasdikrahman!

It looks like this is your first PR to kubernetes-sigs/karpenter 🎉. Please refer to our pull request process documentation to help your PR have a smooth ride to approval.

You will be prompted by a bot to use commands during the review process. Do not be afraid to follow the prompts! It is okay to experiment. Here is the bot commands documentation.

You can also check if kubernetes-sigs/karpenter has its own contribution guidelines.

You may want to refer to our testing guide if you run into trouble with your tests not passing.

If you are having difficulty getting your pull request seen, please follow the recommended escalation practices. Also, for tips and tricks in the contribution process you may want to read the Kubernetes contributor cheat sheet. We want to make sure your contribution gets all the attention it needs!

Thank you, and welcome to Kubernetes. 😃

@k8s-ci-robot k8s-ci-robot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Dec 7, 2023
@k8s-ci-robot
Copy link
Contributor

Hi @tasdikrahman. Thanks for your PR.

I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

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.

@k8s-ci-robot k8s-ci-robot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Dec 7, 2023
@njtran
Copy link
Contributor

njtran commented Dec 7, 2023

Hey @tasdikrahman, as I recall, we wanted to start off with a small design before continuing with this. Was there anyone you had talked to about this while I was on vacation? If not, let's see if we can sync up and get a design in this PR. This should help align us on naming and making sure we're considering how this impacts any other controllers in the project.

I added the needs-design label that we can remove once we add the design into the PR.

@@ -0,0 +1,74 @@
/*
Copy link
Member

Choose a reason for hiding this comment

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

I'm anticipating that we probably don't want to do something as verbose as karpenter.sh/voluntarily-disrupted=drifted. Realistically, it should probably something simple like karpenter.sh/disrupt=true since we've already got an annotation that's karpenter.sh/do-not-disrupt=false

@garvinp-stripe
Copy link
Contributor

I wonder if it would be better to start off with a quick design doc for RFC? This is adding a new controller and method of disruption. I am not fully sure how this fits in with other methods

@tasdikrahman
Copy link
Member Author

Hey folks, sorry for the delay, I will work on sharing a design doc first on this and share it here to align on the approach and changes. I opened the PR as a wip. @njtran @garvinp-stripe @jonathan-innis

@njtran
Copy link
Contributor

njtran commented Jan 2, 2024

Thanks. @tasdikrahman I'll set this as a Draft in the meantime.

@njtran njtran marked this pull request as draft January 2, 2024 17:24
@njtran
Copy link
Contributor

njtran commented Mar 4, 2024

Hey @tasdikrahman how are you doing? Happy to keep you assigned if you want, but want to make sure that you're making progress. I want to make sure the issue is tracked properly based on if you're getting progress here.

@jonathan-innis
Copy link
Member

/assign @njtran

@jonathan-innis
Copy link
Member

/assign @jigisha620

@k8s-ci-robot
Copy link
Contributor

@jonathan-innis: GitHub didn't allow me to assign the following users: jigisha620.

Note that only kubernetes-sigs members with read permissions, repo collaborators and people who have commented on this issue/PR can be assigned. Additionally, issues/PRs can only have 10 assignees at the same time.
For more information please see the contributor guide

In response to this:

/assign @jigisha620

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.

@jigisha620
Copy link
Contributor

/assign @jigisha620

@njtran
Copy link
Contributor

njtran commented Apr 23, 2024

@tasdikrahman hey, it seems like it's been a while since you've been able to work on this. I'll close this out and unassign you from the issue so someone else can take it up if they want, but feel free to take it up when you have more time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. needs-design needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Custom Deprovisioning Trigger Mechanism
7 participants