Skip to content

rollout: Make maxNew configurable#4746

Merged
p-se merged 3 commits into
rancher:mainfrom
p-se:issue-3829
Mar 16, 2026
Merged

rollout: Make maxNew configurable#4746
p-se merged 3 commits into
rancher:mainfrom
p-se:issue-3829

Conversation

@p-se
Copy link
Copy Markdown
Contributor

@p-se p-se commented Mar 4, 2026

Refers to #3829

Additional Information

Checklist

@p-se p-se requested a review from a team as a code owner March 4, 2026 08:11
Copilot AI review requested due to automatic review settings March 4, 2026 08:11
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Makes the per-reconcile “new BundleDeployment creation” limit configurable via bundle.spec.rolloutStrategy.maxNew, instead of being hard-coded to 50, addressing the need to stage large rollouts more conservatively (#3829).

Changes:

  • Add rolloutStrategy.maxNew to the Bundle API and CRDs (default 50).
  • Update rollout partitioning logic to use the configured maxNew when creating new BundleDeployments.
  • Add unit tests covering the new maxNew behavior and status initialization.

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
pkg/apis/fleet.cattle.io/v1alpha1/bundle_types.go Adds RolloutStrategy.MaxNew and updates BundleStatus.MaxNew documentation.
pkg/apis/fleet.cattle.io/v1alpha1/zz_generated.deepcopy.go Updates deepcopy generation for the new field.
internal/cmd/controller/target/partition.go Applies maxNew limiting when creating new BundleDeployments.
internal/cmd/controller/target/rollout_test.go Adds unit tests validating UpdatePartitions behavior with maxNew.
internal/cmd/controller/reconciler/bundle_status.go Sets status.MaxNew from rollout strategy (with default).
internal/cmd/controller/reconciler/bundle_controller.go Passes rollout strategy into resetStatus.
charts/fleet-crd/templates/crds.yaml Updates CRD schema/docs to include rolloutStrategy.maxNew.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread internal/cmd/controller/target/partition.go
Comment thread pkg/apis/fleet.cattle.io/v1alpha1/bundle_types.go Outdated
Comment thread internal/cmd/controller/reconciler/bundle_status.go Outdated
@weyfonk weyfonk added this to Fleet Mar 5, 2026
@weyfonk weyfonk moved this to 👀 In review in Fleet Mar 5, 2026
@weyfonk weyfonk added this to the v2.15.0 milestone Mar 5, 2026
Copy link
Copy Markdown
Collaborator

@thardeck thardeck left a comment

Choose a reason for hiding this comment

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

lgtm, only needs formatting in target_test.go

@p-se p-se merged commit 48eb18e into rancher:main Mar 16, 2026
22 checks passed
@github-project-automation github-project-automation Bot moved this from 👀 In review to ✅ Done in Fleet Mar 16, 2026
@p-se p-se moved this from ✅ Done to Needs QA review in Fleet Mar 16, 2026
@p-se p-se moved this from Needs QA review to ✅ Done in Fleet Mar 16, 2026
@p-se p-se moved this from ✅ Done to Needs QA review in Fleet Mar 18, 2026
@p-se p-se moved this from Needs QA review to ✅ Done in Fleet Mar 31, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

4 participants