Skip to content

feat(client): add permanent flag to CLI and publisher #2281

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 4, 2025

Conversation

mlegner
Copy link
Contributor

@mlegner mlegner commented Jul 3, 2025

Description

Currently, blobs are "permanent" as default and can be stored as "deletable" through the --deletable CLI option and a deletable query parameter on the publisher. We want to change this default behavior in the future, at which point we need a way to specify a blob as "permanent". Adding the --permanent flag in the same release where the default is changed is a bit dangerous as all users would have to change their invocations at exactly that point.

Adding the --permanent flag now allows users to already start calling walrus store --permanent [...] to make sure the behavior is unaffected by the later default change. Additionally, we log a warning about the upcoming default change from permanent to deletable if neither flag is specified.

The plan would then be to keep the --deletable around for some time longer and log a different warning about the default change if neither flag is specified.

Contributes to WAL-911.

Test plan

Manual checks.


Release notes

  • Publisher: Add a permanent query parameter. Warning: In the future, blobs will be stored as deletable by default; to keep the current behavior, you need to add the permanent=true query parameter.
  • CLI: Add a --permanent option to the store and store-quilt commands. Warning: In the future, blobs will be stored as deletable by default; to keep the current behavior, you need to add the --permanent option when storing blobs.

@mlegner mlegner enabled auto-merge (squash) July 3, 2025 08:43
Copy link
Contributor

github-actions bot commented Jul 3, 2025

Warning: This PR modifies one of the OpenAPI files. Please consider the
following:

  • Make sure the API changes are backwards compatible.
  • Make sure to follow existing conventions for any added parameters, requests, and
    responses.
  • Make sure the generated HTML files do not contain errors.
  • This probably requires release notes and maybe changes to the documentation.

cc @jpcsmith @mlegner

Copy link
Contributor

github-actions bot commented Jul 3, 2025

Warning: This PR modifies the Walrus CLI. Please consider the following:

  • Make sure the changes are backwards compatible. Consider deprecating options before
    removing them.
  • Generally only use long CLI options, not short ones to avoid conflicts in the
    future.
  • If you added new options or features, or modified the behavior, please document the
    changes in the release notes of the PR and update the documentation in the docs/book
    directory.

@mlegner mlegner force-pushed the mlegner/warning-about-upcoming-default-change branch 2 times, most recently from 01ae437 to 963ccc6 Compare July 3, 2025 08:59
Also warn about the upcoming default change from permanent to deletable.
@mlegner mlegner force-pushed the mlegner/warning-about-upcoming-default-change branch from 963ccc6 to a68e9af Compare July 3, 2025 09:23
Copy link
Contributor

@liquid-helium liquid-helium left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @mlegner for adding this new behavior, looks good to me, I left only one comment.

@mlegner mlegner disabled auto-merge July 4, 2025 08:14
@mlegner mlegner enabled auto-merge (squash) July 4, 2025 08:14
@mlegner mlegner requested a review from liquid-helium July 4, 2025 08:23
Copy link
Contributor

@liquid-helium liquid-helium left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💯

@mlegner mlegner merged commit dabbe1f into main Jul 4, 2025
27 checks passed
@mlegner mlegner deleted the mlegner/warning-about-upcoming-default-change branch July 4, 2025 17:57
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