Skip to content

fix: skip decommission status for unsupported topology - #199

Open
ccccpj wants to merge 1 commit into
rustfs:mainfrom
ccccpj:agent/fix-single-pool-decommission-status
Open

fix: skip decommission status for unsupported topology#199
ccccpj wants to merge 1 commit into
rustfs:mainfrom
ccccpj:agent/fix-single-pool-decommission-status

Conversation

@ccccpj

@ccccpj ccccpj commented Aug 6, 2026

Copy link
Copy Markdown

Description

Fix the Pool Decommission page so it determines topology support from the pools overview before requesting decommission status.

The page previously started /pools/list, /rebalance/status, and /decommission/status together. In a single-pool deployment, the backend intentionally does not provide decommission status and returns 501, so the otherwise valid unsupported topology was rendered as Load Failed.

This change:

  • loads the pools overview first;
  • skips /decommission/status when supportState is unsupported;
  • renders the trusted single-pool state as Unsupported with no mutation actions;
  • preserves fail-closed behavior for overview failures and supported-topology status failures;
  • keeps rebalance and decommission status reads concurrent after a supported overview.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update
  • Code refactoring
  • Performance improvement
  • Test improvements
  • Security fix

Testing

  • Unit tests added/updated
  • Manual testing completed
pnpm install --frozen-lockfile
pnpm type-check
pnpm lint
pnpm test:run
pnpm prettier --check 'app/(dashboard)/pool-decommission/page.tsx' lib/pool-decommission-load.ts tests/lib/pool-decommission-load.test.ts tests/lib/pool-operations-safety.test.js
git diff --check
  • pnpm test:run: 392 tests passed.
  • Deterministic regression coverage verifies unsupported single-pool status calls are 0, supported multi-pool status calls occur, overview failures stop dependent reads, and supported status failures reject.
  • Adversarial reviewer, tester, UX, and simplifier passes completed.
  • Full pnpm format:check remains blocked by the unchanged upstream file components/object/tiff-viewer.tsx; every file in this PR passes Prettier.

Checklist

  • Code follows the project's style guidelines
  • Self-review completed
  • TypeScript types are properly defined
  • All commit messages are in English (Conventional Commits)
  • All existing tests pass
  • No new dependencies added, or they are justified

Related Issues

Fixes rustfs/rustfs#5773

Screenshots (if applicable)

The after captures use a deterministic local mock with one active 1 TiB pool. The mock returns 501 for /decommission/status, matching the reported backend behavior.

Before

Single-pool page showing Load Failed

After

Desktop

Single-pool page showing Unsupported

Mobile

Single-pool page showing Unsupported on mobile

Additional Notes

This PR does not change the RustFS backend's 501 contract for unsupported single-pool decommission status. Supported multi-pool status failures continue to render an error and keep interactions locked.

@cxymds cxymds self-assigned this Aug 7, 2026
@cxymds
cxymds marked this pull request as ready for review August 7, 2026 02:32
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.

GET /rustfs/admin/v3/decommission/status returns 501 NotImplemented on 1.0.0-beta.12

2 participants