Skip to content

feat: add tags for snapshot#23

Merged
InftyAI-Agent merged 3 commits into
InftyAI:mainfrom
kerthcet:feat/support-snapshot-tags
Jun 29, 2026
Merged

feat: add tags for snapshot#23
InftyAI-Agent merged 3 commits into
InftyAI:mainfrom
kerthcet:feat/support-snapshot-tags

Conversation

@kerthcet

@kerthcet kerthcet commented Jun 29, 2026

Copy link
Copy Markdown
Member

What this PR does / why we need it

Which issue(s) this PR fixes

part of #6

Special notes for your reviewer

Does this PR introduce a user-facing change?


Signed-off-by: kerthcet <kerthcet@gmail.com>
Copilot AI review requested due to automatic review settings June 29, 2026 20:32
@InftyAI-Agent InftyAI-Agent added needs-triage Indicates an issue or PR lacks a label and requires one. needs-priority Indicates a PR lacks a label and requires one. do-not-merge/needs-kind Indicates a PR lacks a label and requires one. labels Jun 29, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR introduces a Git-style tag reference mechanism for snapshots by persisting tag→snapshot mappings as files under refs/tags/, enabling O(1) lookup/filtering by tag and cleaning up tag refs on snapshot deletion.

Changes:

  • Add tags_dir storage and write tag ref files (refs/tags/<tag>) during snapshot creation.
  • Update snapshot listing and tag lookup to use tag refs (and change find_by_tag to return a single snapshot).
  • Extend the snapshot design proposal doc to document the new tag ref layout and semantics.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 5 comments.

File Description
sandd/src/snapshot/manager.rs Implements tag ref directory initialization, tag ref creation/removal/lookup, and updates list/find/delete behavior to use tag refs.
docs/proposals/SNAPSHOTS.md Documents the new refs/tags/ layout and updates API/examples to reflect tag ref lookup behavior.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread sandd/src/snapshot/manager.rs Outdated
Comment thread sandd/src/snapshot/manager.rs Outdated
Comment thread sandd/src/snapshot/manager.rs
Comment thread sandd/src/snapshot/manager.rs
Comment thread sandd/src/snapshot/manager.rs
kerthcet added 2 commits June 29, 2026 21:55
Signed-off-by: kerthcet <kerthcet@gmail.com>
Signed-off-by: kerthcet <kerthcet@gmail.com>
@kerthcet

Copy link
Copy Markdown
Member Author

/lgtm

@kerthcet

Copy link
Copy Markdown
Member Author

/kind feature
/approve

@InftyAI-Agent InftyAI-Agent added the lgtm Looks good to me, indicates that a PR is ready to be merged. label Jun 29, 2026
@InftyAI-Agent InftyAI-Agent added feature Categorizes issue or PR as related to a new feature. approved Indicates a PR has been approved by an approver from all required OWNERS files. and removed do-not-merge/needs-kind Indicates a PR lacks a label and requires one. labels Jun 29, 2026

@InftyAI-Agent InftyAI-Agent left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Approved: PR has both lgtm and approved labels

@InftyAI-Agent InftyAI-Agent merged commit c27926d into InftyAI:main Jun 29, 2026
28 checks passed
@kerthcet kerthcet deleted the feat/support-snapshot-tags branch June 29, 2026 22:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. feature Categorizes issue or PR as related to a new feature. lgtm Looks good to me, indicates that a PR is ready to be merged. needs-priority Indicates a PR lacks a label and requires one. needs-triage Indicates an issue or PR lacks a label and requires one.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants