Skip to content

[ENH]: add operator for garbage collection to list all files used by collection version #4466

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

Open
wants to merge 1 commit into
base: feat-gc-forked-compute-versions-to-delete
Choose a base branch
from

Conversation

codetheweb
Copy link
Contributor

@codetheweb codetheweb commented May 6, 2025

Description of changes

Does what the title says. Given a version file and a version, the operator constructs a complete list of files used by the collection version (including block files by traversing all sparse indices).

Test plan

How are these changes tested?

  • Tests pass locally with pytest for python, yarn test for js, cargo test for rust

Tested in the next PR.

Documentation Changes

Are all docstrings for user-facing APIs updated if required? Do we need to make documentation changes in the docs section?

n/a

Copy link

github-actions bot commented May 6, 2025

Reviewer Checklist

Please leverage this checklist to ensure your code review is thorough before approving

Testing, Bugs, Errors, Logs, Documentation

  • Can you think of any use case in which the code does not behave as intended? Have they been tested?
  • Can you think of any inputs or external events that could break the code? Is user input validated and safe? Have they been tested?
  • If appropriate, are there adequate property based tests?
  • If appropriate, are there adequate unit tests?
  • Should any logging, debugging, tracing information be added or removed?
  • Are error messages user-friendly?
  • Have all documentation changes needed been made?
  • Have all non-obvious changes been commented?

System Compatibility

  • Are there any potential impacts on other parts of the system or backward compatibility?
  • Does this change intersect with any items on our roadmap, and if so, is there a plan for fitting them together?

Quality

  • Is this code of a unexpectedly high quality (Readability, Modularity, Intuitiveness)

@codetheweb codetheweb changed the title [ENH]: add operator for garbage collection to list all files for collection version [ENH]: add operator for garbage collection to list all files used by collection version May 7, 2025
@codetheweb codetheweb marked this pull request as ready for review May 7, 2025 00:06
@codetheweb codetheweb requested a review from Sicheng-Pan May 7, 2025 00:06
@codetheweb codetheweb force-pushed the feat-gc-forked-compute-versions-to-delete branch from 8e4042e to 34ed231 Compare May 13, 2025 17:35
@codetheweb codetheweb force-pushed the feat-gc-list-files-at-version-operator branch from 0c85b47 to b989fec Compare May 13, 2025 17:35
Copy link
Contributor

propel-code-bot bot commented May 13, 2025

Add Garbage Collection Operator for File Listing

This PR adds a new ListFilesAtVersionsOperator to enable garbage collection by constructing a complete list of files used by a specific collection version. The operator traverses sparse indices to identify all related block files, supporting the cleanup of unused files in the storage system.

Key Changes:
• Created new ListFilesAtVersionsOperator that inventories all files used by a collection version
• Implemented logic to traverse sparse indices and collect block file references
• Added Debug implementation for RootManager to support the new operator

Affected Areas:
• rust/garbage_collector/src/operators/list_files_at_version.rs
• rust/blockstore/src/arrow/provider.rs
• rust/garbage_collector/src/operators/mod.rs

This summary was automatically generated by @propel-code-bot

@codetheweb codetheweb force-pushed the feat-gc-forked-compute-versions-to-delete branch from 34ed231 to 9ca2cd5 Compare May 15, 2025 16:52
@codetheweb codetheweb force-pushed the feat-gc-list-files-at-version-operator branch from b989fec to b793a23 Compare May 15, 2025 16:52
@codetheweb codetheweb force-pushed the feat-gc-forked-compute-versions-to-delete branch from 9ca2cd5 to 0725564 Compare May 15, 2025 20:11
@codetheweb codetheweb force-pushed the feat-gc-list-files-at-version-operator branch from b793a23 to 282d440 Compare May 15, 2025 20:11
@codetheweb codetheweb force-pushed the feat-gc-forked-compute-versions-to-delete branch from 0725564 to dd8eba1 Compare May 15, 2025 22:38
@codetheweb codetheweb force-pushed the feat-gc-list-files-at-version-operator branch from 282d440 to c0389ea Compare May 15, 2025 22:38
@codetheweb codetheweb force-pushed the feat-gc-forked-compute-versions-to-delete branch from dd8eba1 to d7546c4 Compare May 15, 2025 22:43
@codetheweb codetheweb force-pushed the feat-gc-list-files-at-version-operator branch from c0389ea to 8b8f1bf Compare May 15, 2025 22:43
@codetheweb codetheweb force-pushed the feat-gc-forked-compute-versions-to-delete branch from d7546c4 to 8242dc4 Compare May 15, 2025 23:27
@codetheweb codetheweb force-pushed the feat-gc-list-files-at-version-operator branch from 8b8f1bf to 9853786 Compare May 15, 2025 23:27
@codetheweb codetheweb force-pushed the feat-gc-forked-compute-versions-to-delete branch from 8242dc4 to 5f592dc Compare May 15, 2025 23:34
@codetheweb codetheweb force-pushed the feat-gc-list-files-at-version-operator branch from 9853786 to fc1cd49 Compare May 15, 2025 23:34
@codetheweb codetheweb force-pushed the feat-gc-forked-compute-versions-to-delete branch from 5f592dc to 3c829d0 Compare May 15, 2025 23:36
@codetheweb codetheweb force-pushed the feat-gc-list-files-at-version-operator branch from fc1cd49 to c9ec71e Compare May 15, 2025 23:36
@codetheweb codetheweb force-pushed the feat-gc-forked-compute-versions-to-delete branch from 3c829d0 to 8fa48f8 Compare May 15, 2025 23:38
@codetheweb codetheweb force-pushed the feat-gc-list-files-at-version-operator branch from c9ec71e to d357155 Compare May 15, 2025 23:38
@codetheweb codetheweb force-pushed the feat-gc-forked-compute-versions-to-delete branch from 8fa48f8 to c69db1a Compare May 15, 2025 23:47
@codetheweb codetheweb force-pushed the feat-gc-list-files-at-version-operator branch from d357155 to 414e653 Compare May 15, 2025 23:47
@codetheweb codetheweb force-pushed the feat-gc-forked-compute-versions-to-delete branch from c69db1a to cedd402 Compare May 16, 2025 00:26
@codetheweb codetheweb force-pushed the feat-gc-list-files-at-version-operator branch from 414e653 to 15fc32e Compare May 16, 2025 00:26
@codetheweb codetheweb force-pushed the feat-gc-forked-compute-versions-to-delete branch from cedd402 to 293492c Compare May 16, 2025 16:41
@codetheweb codetheweb force-pushed the feat-gc-list-files-at-version-operator branch from 15fc32e to f29b0bf Compare May 16, 2025 16:41
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