Skip to content

OCM-21663 | feat: Allow min-replicas=0 for HCP nodepool autoscaling#3175

Open
jhjaggars wants to merge 2 commits intoopenshift:masterfrom
jhjaggars:allow-min-zero-replicas-hcp-nodepool
Open

OCM-21663 | feat: Allow min-replicas=0 for HCP nodepool autoscaling#3175
jhjaggars wants to merge 2 commits intoopenshift:masterfrom
jhjaggars:allow-min-zero-replicas-hcp-nodepool

Conversation

@jhjaggars
Copy link

Updated CLI validation to allow minimum of 0 replicas for HCP nodepool autoscaling, matching the relaxed API constraints for customers with that capability enabled.

Changes:

  • Updated validation in pkg/machinepool/machinepool.go to allow min >= 0
  • Updated interactive validator in pkg/machinepool/helper.go for HCP
  • Updated unit tests to verify min=0 succeeds and negative values fail
  • Added comprehensive HCP-specific test coverage in helper_test.go
  • Updated E2E tests to expect min=0 to succeed

The changes align HCP nodepool validation with Classic machinepool behavior while maintaining all other safety constraints (negative values still rejected, multi-AZ multiples of 3 still enforced).

🤖 Generated with Claude Code

@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jan 13, 2026
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 13, 2026

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 13, 2026

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: jhjaggars
Once this PR has been reviewed and has the lgtm label, please assign gdbranco for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details 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

@jhjaggars jhjaggars changed the title OCM-XXXXX | feat: Allow min-replicas=0 for HCP nodepool autoscaling OCM-21663 | feat: Allow min-replicas=0 for HCP nodepool autoscaling Jan 13, 2026
@jhjaggars jhjaggars marked this pull request as ready for review January 13, 2026 18:46
@openshift-ci openshift-ci bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jan 13, 2026
Updated CLI validation to allow minimum of 0 replicas for HCP nodepool
autoscaling, matching the relaxed API constraints for customers with
that capability enabled.

Changes:
- Updated validation in pkg/machinepool/machinepool.go to allow min >= 0
- Updated interactive validator in pkg/machinepool/helper.go for HCP
- Updated unit tests to verify min=0 succeeds and negative values fail
- Added comprehensive HCP-specific test coverage in helper_test.go
- Updated E2E tests to expect min=0 to succeed

The changes align HCP nodepool validation with Classic machinepool
behavior while maintaining all other safety constraints (negative
values still rejected, multi-AZ multiples of 3 still enforced).

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@jhjaggars jhjaggars force-pushed the allow-min-zero-replicas-hcp-nodepool branch from cd3e4e0 to 5dee9f4 Compare January 14, 2026 16:16
Fix undefined variable error in HCP machine pool test by properly
declaring expectErrMsg variable.

Co-Authored-By: Claude Sonnet 4.5 (1M context) <noreply@anthropic.com>
@jhjaggars
Copy link
Author

/retest

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant