Skip to content

fix(pool): guard decommission lifecycle recovery#176

Merged
GatewayJ merged 2 commits into
rustfs:mainfrom
GatewayJ:fix/pool-decommission-lifecycle
Jul 12, 2026
Merged

fix(pool): guard decommission lifecycle recovery#176
GatewayJ merged 2 commits into
rustfs:mainfrom
GatewayJ:fix/pool-decommission-lifecycle

Conversation

@GatewayJ

@GatewayJ GatewayJ commented Jul 11, 2026

Copy link
Copy Markdown
Member

Type of Change

  • New Feature
  • Bug Fix
  • Documentation
  • Performance Improvement
  • Test/CI
  • Refactor
  • Other:

Related Issues

Fixes rustfs/backlog#1078
Fixes rustfs/backlog#1079
Related to rustfs/backlog#1070

Summary of Changes

  • Count only live pools when evaluating pool decommission start requests, so pools already decommissioning or decommissioned cannot keep the last remaining live pool eligible for decommission.
  • Reject a batch of live-pool Start requests before issuing RustFS admin calls when that batch would decommission every live pool in the Tenant.
  • Restore normal workload reconciliation after a canceled or failed decommission request is removed, instead of leaving the pool permanently lifecycle-gated.
  • Add focused regression tests for last-live-pool protection, batch start protection, and terminal lifecycle recovery.

Checklist

  • I have read and followed the CONTRIBUTING.md guidelines
  • Passed make pre-commit (fmt-check + clippy + test + console-lint + console-fmt-check)
  • Added/updated necessary tests
  • Documentation updated (if needed)
  • CHANGELOG.md updated under [Unreleased] (if user-visible change)
  • CI/CD passed (if applicable)

Impact

  • Breaking change (CRD/API compatibility)
  • Requires doc/config/deployment update
  • Other impact: Preserves normal StatefulSet reconciliation after canceled or failed decommission requests are cleared; prevents decommissioning all live pools, including multi-request batches.

Verification

make pre-commit

Additional Notes

This change only adjusts operator lifecycle gating. It does not change RustFS admin API calls, CRD schema, StatefulSet deletion behavior, or PVC retention behavior.

@GatewayJ GatewayJ marked this pull request as ready for review July 12, 2026 07:42
@GatewayJ GatewayJ added this pull request to the merge queue Jul 12, 2026
Merged via the queue into rustfs:main with commit d6147a9 Jul 12, 2026
3 checks passed
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