feat: bucket soft-delete lifecycle support#106
Merged
Conversation
Wire up the soft-delete features added in @tigrisdata/storage 3.12: - buckets set: add --soft-delete enable|disable with --retention-days, and deprecate --enable-delete-protection in favor of --soft-delete - buckets list: add --deleted to list only soft-deleted buckets - buckets get: surface new getBucketInfo properties (Locations, Soft Delete, Additional Headers) - buckets restore: new command to recover a soft-deleted bucket within its retention window - support marking arguments as deprecated in --help output Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Address review feedback: - buckets set: reject --retention-days unless --soft-delete enable is set, instead of silently dropping it - buckets list: warn when --deleted is combined with --forks-of, which ignores --deleted (matches existing pagination-flag behavior) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Address review feedback: - cli-core: apply the deprecated annotation in formatArgumentHelp so the `help` subcommand surfaces deprecated flags, matching `--help` - buckets list: guard the forks path against a missing forks array, matching the existing listBuckets empty-result check Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 8b38422. Configure here.
When --soft-delete had an invalid value and --retention-days was present, the orphan-retention guard fired first with a misleading message. Reorder so the enable/disable value check reports first. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
MantasMiksys
approved these changes
Jun 9, 2026
|
🎉 This PR is included in version 3.1.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Xe
added a commit
that referenced
this pull request
Jun 16, 2026
`npm run updatedocs` regenerates the whole README from specs.yaml, which pulled in pre-existing soft-delete command docs that were never regenerated after #106. Restore the README to main and re-apply only the `project` command sections so this PR's docs are scoped to its change. Assisted-by: Claude Opus 4.8 via Claude Code Signed-off-by: Xe Iaso <xe@tigrisdata.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
Wires up the soft-delete features added in
@tigrisdata/storage3.12 across the bucket commands, completing the soft-delete lifecycle: configure → discover → recover.Changes
buckets set— new--soft-delete enable|disable(with--retention-days <N>required when enabling). Deprecates--enable-delete-protectionin favor of--soft-delete(still functional, flagged in--help).buckets list— new--deletedflag to list only soft-deleted buckets.buckets get— surfaces newgetBucketInfoproperties: Locations (structured, previously not shown at all), Soft Delete (with retention days), and Additional Headers.buckets restore— new command to recover a soft-deleted bucket within its retention window.Argumentspec gains adeprecatedfield; deprecated args render as(deprecated) … Use <x> instead.in help output.Lifecycle
Notes
--enable-delete-protectionis deprecated, not removed — existing behavior and the "Delete Protection" row ingetare preserved alongside the new "Soft Delete" row.@tigrisdata/storageto^3.12.0.Testing
test/utils/bucket-info.test.ts(Locations, Soft Delete, Additional Headers).buckets set --soft-deletevalidation andbuckets restore.npm run build, lint, format check, and 283 unit tests pass. Manually tested by the author.🤖 Generated with Claude Code
Note
Medium Risk
Changes bucket configuration and delete/recovery behavior against live storage APIs; misconfiguration or restore misuse could affect data availability, though validation and deprecation preserve existing delete-protection paths.
Overview
Adds end-to-end bucket soft-delete support by bumping
@tigrisdata/storageto ^3.12.0 and wiring new storage APIs into the CLI.Configure & inspect:
buckets setgains--soft-delete enable|disablewith required--retention-dayswhen enabling;--enable-delete-protectionis deprecated (still works) in favor of soft delete.buckets getnow shows Locations, Soft Delete (with retention), and Additional Headers.Discover & recover:
buckets listadds--deletedfor soft-deleted buckets only;--forks-ofnow useslistForksinstead of scanning all buckets with per-bucketgetBucketInfo. Newbuckets restorerecovers a bucket within its retention window.CLI infra: Spec
Argumenttype and help rendering supportdeprecated/replaced_by(parallel to existingremoved).Tests cover soft-delete validation, restore errors, and expanded
buildBucketInfooutput.Reviewed by Cursor Bugbot for commit b893233. Bugbot is set up for automated code reviews on this repo. Configure here.