Remove selected backup snapshots without breaking retained restores - #78
Merged
Conversation
The hook-install test checks that an existing file keeps mode 0640, but creating it under a restrictive umask produces mode 0600. Set the fixture mode before installation so the test checks preservation, not the shell's default creation mask. Generated with Codex Co-authored-by: Codex <noreply@openai.com>
Applications need to expire backup recovery points without deleting a parent that a retained incremental backup still needs. Add explicit snapshot removal with a preview and a separate last-snapshot override. Delete children durably before parents so an interrupted operation leaves the remaining dependency chains intact. Keep packs and indexes unchanged; reclaiming their unused bytes is a separate operation. Generated with Codex Co-authored-by: Codex <noreply@openai.com>
roborev: Combined Review (
|
A symlinked snapshots directory could redirect removal into another repository. Refuse that layout and keep manifest reads, deletion, and directory syncing bound to the same validated directory handle. Cancellation also needs to stop an exclusive-lock attempt waiting for active readers. Release only that attempt's claim when canceled so the reader can continue and later operations are not blocked. Generated with Codex Co-authored-by: Codex <noreply@openai.com>
roborev: Combined Review (
|
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.
Applications can remove selected backup recovery points, with a dry run to preview the removal. Kit refuses to delete the last snapshot without explicit permission or an older snapshot that a retained incremental backup still needs.
Dependent snapshots are removed before their parents, with each deletion synced before the next. The operation works from the backup repository alone; the original application data is not required.
This removes snapshot records, not the packed content. Reclaiming unused disk space is a separate follow-up.