-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
clusterapi provider for cluster autoscaler should expose labels and taints when scaling from zero #7685
Comments
/triage accepted |
I'm not sure I understand what the requirement for Cluster API is. This sounds a bit like it's something for the autoscaler "I would like to ensure that the cluster autoscaler will use ". But I assume I'm misunderstanding it :) What does this mean:
Does the autoscaler want to set labels on nodes via Cluster API resources? Or is it about mapping the labels Cluster API will apply to nodes based on Cluster API resources to the labels which are found on the nodes by the autoscaler? |
it's about this, we need to agree on a way to expose those labels and annotations (although i think we already agreed on a method for the labels). essentially, when the autoscaler is attempting a prediction for a node group with zero replicas, it needs a way to understand what the labels and annotations will be present on the nodes created from the node group. when there are |
@cnmcavoy has proposed a novel solution in kubernetes/autoscaler#5382 |
updated this to talk about labels and taints, i don't think we need the annotations from the nodes. |
Thx, I think now I've got it. I think the situation is the following:
P.S. also answered on kubernetes/autoscaler#5382 |
This issue has not been updated in over 1 year, and should be re-triaged. You can:
For more details on the triage process, see https://www.kubernetes.dev/docs/guide/issue-triage/ /remove-triage accepted |
/priority important-longterm |
@elmiko is that ok to close this issue now that we have well defined rules for label propagation from Cluster API objects down to nodes? |
Q: I know we have those well-defined rules for MD => MS => Machine. What is the state of MachinePools? (that are also supported by cluster-autoscaler) |
@fabriziopandini i think we could close, aside from the question @sbueringer raised about MachinePools. i need to study the label propagation method though just to make sure. |
i looked at the rules for label propagation and think they solve the issue for labels, but we probably want to open a card for the taints separately. i think the restriction rules make it a little complicated because two of the options require the user to keep things in the |
@elmiko not sure if I understood correctly. We're blocking certain labels / domains and karpenter only allows specific labels? What would be the ones we would need to support? IIRC we already allow some specific labels that just make sense, maybe we should just allow them |
cc @mboersma @willie-yao @Jont828 for the comment about MP /close FYI Those are the criteria for label propagation from machines to nodes:
The third option allows to have labels outside Same if we want to start thinking to Taint propagation, which probably requires some API design work since we don't have such a concept in core machine APIs |
@fabriziopandini: Closing this issue. In response to this:
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. |
@sbueringer i don't think we have a problem yet, but i just wanted to highlight a possible bad interaction with karpenter. for example, as Fabrizio points out in order for labels to be propagated they must contain one of the three domain prefixes: as i said, i don't think we need to do anything immediately, but it's something to consider as we move forward. |
Sounds good. Our main goal with limiting the labels we propagate was to only allow it for labels that make sense + |
Alternative to allow-listing would be make it configurable in some way (e.g. via a flag). |
i think this make good sense, we just want to inform users about preferring to use
+1, would be interested to hear more about this idea |
I think whenever possible we should avoid adding additional flags to keep CAPI as simple as possible and also so it behaves the same for everyone (as much as possible). So if there is a general use case for specific standard Kubernetes labels, let's talk about it and not make it configurable so everyone has to allowlist them by themselves. |
is it worth opening another issue to capture the taint use case? |
User Story
As a user I would like to ensure that the cluster autoscaler will use the labels and taints associated with my cluster api scalable resources (MachineDeployment, MachineSet, etc) when predicting the node shape in scale from zero scenarios so that i can be sure that pod scheduling will occur as expected.
Detailed Description
Currently, the clusterapi provider for the cluster autoscaler does not have a convenient way to expose the labels and taints that will be applied to nodes created from the scalable resources. Part of this is due to the fact that the cluster api community is still coordinating about how these labels and taints will be propagated to the nodes that are created.
Anything else you would like to add:
This will require some coordination with the cluster api community to solve completely, there are a couple pieces of prior art around the labels that should be noted:
/kind feature
The text was updated successfully, but these errors were encountered: