Skip to content

fix(buckets): confirm versioning changes before applying - #290

Merged
cxymds merged 1 commit into
mainfrom
houseme/fix/9198-versioning-confirmation
Nov 9, 2026
Merged

cxymds merged 1 commit into
mainfrom
houseme/fix/9198-versioning-confirmation

Conversation

@houseme

@houseme houseme commented Nov 6, 2026

Copy link
Copy Markdown
Contributor

Pull Request

Description

Bucket versioning currently changes as soon as its switch is clicked. Add a confirmation that names the bucket and explains that enabled versioning can only be suspended, not reset to an unconfigured state. Suspension also explains the risk of overwriting null-version objects.

Keep the current value until the request succeeds, retain failed changes for retry, distinguish unconfigured/enabled/suspended states, and explain irreversible versioning/Object Lock choices during bucket creation. New text is localized in all 15 locales.

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

Passed locally with Node 22 and pnpm 11.25:

pnpm install --offline --frozen-lockfile
pnpm type-check
pnpm lint
pnpm format:check
pnpm test:run
git diff --check

All 883 tests passed, including 13 focused confirmation-flow tests. Running the focused tests against the unchanged base reproduces the immediate-write and incorrect-status behavior.

Automated browser checks exercised the running Console with controlled S3/admin responses: Cancel and Escape send no write, focus returns to the switch, failed writes preserve state and can be retried, and mobile/Chinese/dark/short-screen layouts keep the actions reachable. Permission checks, Object Lock, failed reads, duplicate clicks, and bucket switching are covered by component tests.

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

Related to rustfs/rustfs#9198.

Screenshots (if applicable)

Running Console with controlled S3/admin responses. Before and after use the same bucket and desktop viewport.

Before: click applies immediately After: confirmation before applying
Before After
Mobile, Chinese/dark mode, and short-screen error recovery
Mobile write failure Chinese/dark confirmation
Mobile error Chinese dark mode

Short-screen long error

Additional Notes

The S3 request format is unchanged. Browser fixtures verify Console behavior, not live storage integration. Reverting this change restores the previous interaction; shipping the fix also requires updated Console assets in RustFS distributions.

Require an explicit decision before changing bucket versioning and explain
irreversible creation settings. Keep unconfigured and suspended states
distinct, retain failed changes for retry, and cover the confirmation flow.

Refs: rustfs/rustfs#9198

Co-Authored-By: heihutu <heihutu@gmail.com>
Co-Authored-By: zhi22915 <qiuzgang@gmail.com>
@cxymds
cxymds merged commit 04cf59a into main Nov 9, 2026
10 checks passed
@cxymds
cxymds deleted the houseme/fix/9198-versioning-confirmation branch November 9, 2026 02:29
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.

2 participants