-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Cluster Autoscaler: align workload-level APIs with Karpenter #6648
Comments
@MaciekPytel @gjtempleton @jonathan-innis I want to discuss this during the next sig meeting if possible, could you take a look? |
BTW, if you're looking at the key prefix for annotations and / or labels, these things aren't called “API groups”. We use the term API group purely for resource kinds that you find within Kubernetes' HTTP API. |
This feels accurate: |
Good point about the "API group" being a precisely defined term, changed to "API prefix". Unless we have a name for such concept as well? I'm struggling to understand how the new title is accurate. "Aligning labels and annotations" could mean many things in the Cluster Autoscaler/Karpenter context, since labels and annotations are important for various parts of the logic (e.g. something around node templates would probably be my first guess for something related to "aligning labels and annotations"). "Workload-level APIs", on the other hand, should be pretty clear in Cluster Autoscaler/Karpenter context. /retitle Cluster Autoscaler: align workload-level APIs with Karpenter |
If you mean the |
thanks for bringing this up @towca , i think that if we make an api around this it will be beneficial to the wider community. i don't have super strong opinions on the naming part, but i think de-emphasizing the "autoscaling" part of it would be nice. that said, i like the distinction you call about what would be expected from something with the |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues. This bot triages un-triaged issues according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
The kubernetes/kubernetes#124800 PR defining the first common annotation is in review. The review has stalled a bit, I bumped it for the reviewers during the sig-autoscaling meeting today. |
/remove-lifecycle stale |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues. This bot triages un-triaged issues according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues. This bot triages un-triaged issues according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle rotten |
/remove-lifecycle stale |
/remove-lifecycle rotten |
Which component are you using?: Cluster Autoscaler
Is your feature request designed to solve a problem? If so describe the problem this feature should solve.:
Recently, Karpenter officially joined sig-autoscaling, and we now have 2 Node autoscalers officially supported by Kubernetes.
Both autoscalers provide workload-level APIs that a workload owner can use to influence autoscaling behavior related to the workloads. Some of these APIs have identical semantics, but different naming. Because of this, workloads taking advantage of such APIs aren't portable between clusters using different autoscalers (e.g. in a multi-cloud setting).
Cluster Autoscaler provides the following workload-level APIs:
cluster-autoscaler.kubernetes.io/safe-to-evict: false
cluster-autoscaler.kubernetes.io/safe-to-evict: false
cluster-autoscaler.kubernetes.io/safe-to-evict-local-volumes: "volume-1,volume-2,.."
cluster-autoscaler.kubernetes.io/pod-scale-up-delay: <duration>
cluster-autoscaler.kubernetes.io/enable-ds-eviction: true/false
cluster-autoscaler.kubernetes.io/daemonset-pod: true
To my knowledge, right now Karpenter only provides the following workload-level API:
karpenter.sh/do-not-disrupt: true
Describe the solution you'd like.:
node-autoscaling.kubernetes.io
. Going forward, any new APIs using this prefix would have to be approved by both CA and Karpenter owners. Note that this doesn't prevent the autoscalers from adding new autoscaler-specific APIs, but the goal should be to use the common prefix if possible.node-autoscaling.kubernetes.io/do-not-disrupt: true
to CA and Karpenter, while still honoringcluster-autoscaler.kubernetes.io/safe-to-evict: false
andkarpenter.sh/do-not-disrupt: true
for backwards compatibility.node-autoscaling.kubernetes.io/do-not-disrupt: false
, mapping tosafe-to-evict: true
in CA. Not sure what the semantics for that in Karpenter would be (need to check if it has any consolidation-blocking conditions triggered by a pod).Describe any alternative solutions you've considered.:
The CA/Karpenter alignment AEP also mentions aligning on Node-level APIs related to scale-down/consolidation. However, the scope of these APIs will likely be Node lifecycle altogether, not just Node autoscaling. IMO we shouldn't mix the two API prefixes together, and the Node-level API migration should be handled separately. Taking
do-not-disrupt: true
as an example: if we put it in anode-autoscaling.kubernetes.io
prefix, all we need to guarantee is that the 2 supported autoscalers handle it correctly. If we were to put it into a broadernode-lifecycle.kubernetes.io
prefix, every component interacting with node lifecycle through this API would have to honor it going forward, or break the expectations. Honoringdo-not-disrupt: true
might not be an option for certain components (e.g. a component Upgrading nodes with strict FedRAMP requirements has to violate it at some point), limiting the usefulness of that broader node-lifecycle API.Additional context.:
2024-03-25TBD.The text was updated successfully, but these errors were encountered: