Repository navigation
Prevent Cluster Autoscaler in MultiKueue manager cluster from scaling up nodes for Pod workloads - #12262
Conversation
… up nodes for Pod workloads Signed-off-by: Fabio Grätz <fabio@cusp.ai>
|
Hi @fg91. 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 Regular contributors should join the org to skip this step. Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions 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-sigs/prow repository. |
📝 WalkthroughWalkthrough
ChangesGated PodScheduled condition preservation in MultiKueue sync
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
/ok-to-test |
|
@fg91 that is a nice PR, thak you, please post a release note in the PR description in a dedicated block. |
Done |
✅ Deploy Preview for kubernetes-sigs-kueue canceled.
|
|
I'll adapt |
Signed-off-by: Fabio Grätz <fabio@cusp.ai>
|
/release-note-edit |
|
Looks great, thank you for hardening the MultiKueue implementation 👍 |
|
@mimowo: once the present PR merges, I will cherry-pick it on top of DetailsIn 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-sigs/prow repository. |
|
LGTM label has been added. DetailsGit tree hash: e0f9c1d48492f4a8eeab645e507e6ee47e317b10 |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: fg91, mimowo The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
@mimowo: new pull request created: #12272 DetailsIn 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-sigs/prow repository. |
|
@mimowo: new pull request created: #12273 DetailsIn 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-sigs/prow repository. |
…ion when worker cluster did schedule (#13198) * Follow up #12262: MultiKueue sync pod scheduled condition when worker cluster did schedule Signed-off-by: Fabio Grätz <fabio@cusp.ai> * Fix existing and add new e2e test Signed-off-by: Fabio Grätz <fabio@cusp.ai> --------- Signed-off-by: Fabio Grätz <fabio@cusp.ai> Co-authored-by: Fabio Grätz <fabio@cusp.ai>
…ion when worker cluster did schedule (#13197) * Follow up #12262: MultiKueue sync pod scheduled condition when worker cluster did schedule Signed-off-by: Fabio Grätz <fabio@cusp.ai> * Fix existing and add new e2e test Signed-off-by: Fabio Grätz <fabio@cusp.ai> --------- Signed-off-by: Fabio Grätz <fabio@cusp.ai> Co-authored-by: Fabio Grätz <fabio@cusp.ai>
What type of PR is this?
/kind bug
/area multikueue
What this PR does / why we need it:
When a pod workload is admitted in a MultiKueue worker cluster, the cluster autoscaler in the management cluster triggers a scale up even though the pod will never run in the management cluster due to the scheduling gates. This PR prevents this.
Which issue(s) this PR fixes:
When a pod workload is created in the management cluster, the following is added to its spec and status:
Such a pod is not considered a scale up candidate by the cluster autoscaler.
However, once the pod is admitted in the worker cluster, the
PodScheduledcondition is currently overwritten with:The cluster autoscaler considers such a pod a scale up candidate despite the scheduling gates. Accordingly, I see a scale up event in the management cluster:
Pod triggered scale-up: [{https://... 0->1 (max: 1000)}]This scale up in the management cluster doesn't make any sense as the workload will never run there. To prevent it, we must preserve the
reason: SchedulingGatedfor thetype: PodScheduledcondition in the management cluster.Does this PR introduce a user-facing change?
Summary by CodeRabbit
Release Notes
Bug Fixes
PodScheduledcondition when a Pod is scheduling-gated, while still keeping other status details in sync with the remote Pod.Tests
PodScheduledremains unchanged during job status synchronization.E2E