Skip to content

Conversation

shafeeqes
Copy link
Contributor

How to categorize this PR?

/area usability
/kind bug

What this PR does / why we need it:
Currently, the defaulting is a bit wrong, with

  • maxSurge not defaulted to 0 and maxUnavailable not defaulted to 1 for AutoInPlaceUpdate strategy
  • maxSurge and maxUnavailable are always getting overwritten for ManualInPlaceUpdate strategy

We already have validation to prevent maxSurge from being set > 0 for ManualInPlaceUpdate strategy,

if getIntOrPercentValue(ptr.Deref(worker.MaxSurge, intstr.IntOrString{})) != 0 && ptr.Deref(worker.UpdateStrategy, "") == core.ManualInPlaceUpdate {
// MaxSurge must be 0 when update strategy is ManualInPlaceUpdate.
allErrs = append(allErrs, field.Invalid(fldPath.Child("maxSurge"), worker.MaxSurge, "must be 0 when `updateStrategy` is `ManualInPlaceUpdate`"))
}
. Previously, this was never reached because of the overwriting in defaulting.

Which issue(s) this PR fixes:
Part of #10219

Special notes for your reviewer:
/cc @ary1992 @acumino

Release note:

For worker pools with in-place update strategies, the `maxSurge` and `maxUnavailable` fields are now correctly defaulted to `0` and `1` respectively.
A bug causing the `maxSurge` and `maxUnavailable` fields for worker pools with update strategy `ManualInPlaceUpdate` always getting overwritten is now fixed.

@gardener-prow gardener-prow bot requested review from acumino and ary1992 July 2, 2025 08:33
@gardener-prow gardener-prow bot added the area/usability Usability related label Jul 2, 2025
@gardener-prow gardener-prow bot added kind/bug Bug cla: yes Indicates the PR's author has signed the cla-assistant.io CLA. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Jul 2, 2025
@shafeeqes
Copy link
Contributor Author

/cherry-pick release-v1.122

@gardener-ci-robot
Copy link
Contributor

@shafeeqes: once the present PR merges, I will cherry-pick it on top of release-v1.122 in a new PR and assign it to you.

In response to this:

/cherry-pick release-v1.122

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.

@shafeeqes
Copy link
Contributor Author

/cherry-pick release-v1.121

@gardener-ci-robot
Copy link
Contributor

@shafeeqes: once the present PR merges, I will cherry-pick it on top of release-v1.121 in a new PR and assign it to you.

In response to this:

/cherry-pick release-v1.121

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.

@shafeeqes
Copy link
Contributor Author

/cherry-pick release-v1.120

@gardener-ci-robot
Copy link
Contributor

@shafeeqes: once the present PR merges, I will cherry-pick it on top of release-v1.120 in a new PR and assign it to you.

In response to this:

/cherry-pick release-v1.120

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.

Copy link
Contributor

@ary1992 ary1992 left a comment

Choose a reason for hiding this comment

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

/lgtm

@gardener-prow gardener-prow bot added the lgtm Indicates that a PR is ready to be merged. label Jul 2, 2025
Copy link
Contributor

gardener-prow bot commented Jul 2, 2025

LGTM label has been added.

Git tree hash: 36b016e0ba46906adda91a8bfbd9f8b7cd1d483c

Copy link
Member

@rfranzke rfranzke left a comment

Choose a reason for hiding this comment

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

/approve

Copy link
Contributor

gardener-prow bot commented Jul 3, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: rfranzke

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:

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

@gardener-prow gardener-prow bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jul 3, 2025
@gardener-prow gardener-prow bot merged commit 2e7fd91 into gardener:master Jul 3, 2025
19 checks passed
@gardener-ci-robot
Copy link
Contributor

@shafeeqes: new pull request created: #12454

In response to this:

/cherry-pick release-v1.122

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.

@gardener-ci-robot
Copy link
Contributor

@shafeeqes: new pull request created: #12455

In response to this:

/cherry-pick release-v1.121

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.

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. area/usability Usability related cla: yes Indicates the PR's author has signed the cla-assistant.io CLA. kind/bug Bug lgtm 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