Skip to content

Add verified fresh-directory v2 and hybrid piece storage - #178

Closed
linroid wants to merge 1 commit into
torrent-v2-06-output-mappingfrom
torrent-v2-06-piece-store
Closed

linroid wants to merge 1 commit into
torrent-v2-06-output-mappingfrom
torrent-v2-06-piece-store

Conversation

@linroid

@linroid linroid commented Sep 12, 2026

Copy link
Copy Markdown
Owner

Connect authenticated v2/hybrid metadata, output mapping and payload verification to fresh-directory filesystem storage. Selected files retain logical IDs and file-relative offsets; virtual padding is never written. A reserved private copy ensures verification and blocking I/O use the same bytes even if the caller reuses its receive buffer. Flush and the cancellation boundary precede committed progress publication.

Initialization exclusively creates a new root and rejects existing destinations. Live cleanup checks recorded OS identities. A shared handle permit and payload lease remain held until blocking I/O returns, including cancellation. Duplicate commits do not double-count progress.

Stack: based on #177, advancing #162 step 06. This adapter is not yet installed in the engine. Session state admission, persistent ownership/checkpoint v2, resume/import/recheck, committed reads/proof serving, generation-tagged sessions and alternate providers remain pending.

Validation: all 362 torrent JVM tests, both existing pinned-client v1 conformance scenarios and the native-runtime guard pass. New tests cover corrupt/valid/duplicate commits, empty and selected files, preserving existing destinations, buffer exhaustion, hybrid offsets/padding/IDs, cleanup and blocked-I/O cancellation with caller buffer mutation. V2 client interoperability remains unverified.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 12, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-12T14:54:29.838537Z 4f7301d PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

Copy link
Copy Markdown
Contributor

Test Results

  556 files  + 8    556 suites  +8   3m 58s ⏱️ +10s
2 475 tests +16  2 475 ✅ +16  0 💤 ±0  0 ❌ ±0 
3 197 runs  +28  3 197 ✅ +28  0 💤 ±0  0 ❌ ±0 

Results for commit 4f7301d. ± Comparison against base commit a1a0fc5.

@linroid

linroid commented Sep 20, 2026

Copy link
Copy Markdown
Owner Author

Superseded by #233 (V2 layout and verified storage) in the consolidated eight-PR stack for #162.

The replacement preserves this PR's code and subsequent fixes; its description links the original head and review discussions. The only additional consolidation fix is the CI-discovered listener cancellation regression, documented on the replacement. All eight replacements have passed their required CI checks.

Closing without merging. This branch and its discussions remain available for reference. Review index: #162 (comment)

@linroid linroid closed this Sep 20, 2026
@linroid
linroid deleted the torrent-v2-06-piece-store branch September 20, 2026 11:12
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.

1 participant