Skip to content

docs(design): evaluate Repository pattern for file list (#2135) - #4211

Merged
oferchen merged 1 commit into
masterfrom
docs/repository-pattern-flist-2135
May 17, 2026
Merged

oferchen merged 1 commit into
masterfrom
docs/repository-pattern-flist-2135

Conversation

@oferchen

@oferchen oferchen commented May 17, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • Evaluates wrapping the file list (today Vec<FileEntry> + Arc<Vec<FileEntry>>) in a FileListRepository trait with queryable accessors.
  • Catalogs nine distinct query patterns currently used by crates/transfer/ and crates/engine/ consumers.
  • Recommends reject for now, reopen after docs(flist): audit arena allocator feasibility (#2210) #4166 arena prerequisites land: NDX lookup and contiguous-range iteration are O(1) on Vec and gain nothing from trait indirection; the asked-for find_by_path matches no existing call site; sort_by_inode would break NDX stability.

Test plan

  • cargo fmt --all (no diff)
  • No em-dashes or en-dashes
  • All file:line citations verified against current master

Recommends rejecting the queryable repository for now because the nine
distinct flist query patterns in transfer/engine are dominated by NDX
lookup and contiguous-range iteration; both are O(1) on Vec<FileEntry>
and gain nothing from trait indirection. The asked-for find_by_path
matches no existing call site and sort_by_inode breaks NDX stability.
Reopen after the #4166 arena prerequisites land.
@github-actions github-actions Bot added the documentation Improvements or additions to documentation label May 17, 2026
@oferchen
oferchen merged commit 0b6669f into master May 17, 2026
8 checks passed
@oferchen
oferchen deleted the docs/repository-pattern-flist-2135 branch May 17, 2026 18:51
oferchen added a commit that referenced this pull request May 18, 2026
Recommends rejecting the queryable repository for now because the nine
distinct flist query patterns in transfer/engine are dominated by NDX
lookup and contiguous-range iteration; both are O(1) on Vec<FileEntry>
and gain nothing from trait indirection. The asked-for find_by_path
matches no existing call site and sort_by_inode breaks NDX stability.
Reopen after the #4166 arena prerequisites land.
oferchen added a commit that referenced this pull request May 18, 2026
Recommends rejecting the queryable repository for now because the nine
distinct flist query patterns in transfer/engine are dominated by NDX
lookup and contiguous-range iteration; both are O(1) on Vec<FileEntry>
and gain nothing from trait indirection. The asked-for find_by_path
matches no existing call site and sort_by_inode breaks NDX stability.
Reopen after the #4166 arena prerequisites land.
oferchen added a commit that referenced this pull request Aug 24, 2026
Recommends rejecting the queryable repository for now because the nine
distinct flist query patterns in transfer/engine are dominated by NDX
lookup and contiguous-range iteration; both are O(1) on Vec<FileEntry>
and gain nothing from trait indirection. The asked-for find_by_path
matches no existing call site and sort_by_inode breaks NDX stability.
Reopen after the #4166 arena prerequisites land.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant