Skip to content

Recover v2 store ownership from task-bound catalog checkpoints - #182

Closed
linroid wants to merge 2 commits into
torrent-v2-07-checkpointfrom
torrent-v2-07-store-recovery
Closed

linroid wants to merge 2 commits into
torrent-v2-07-checkpointfrom
torrent-v2-07-store-recovery

Conversation

@linroid

@linroid linroid commented Sep 12, 2026

Copy link
Copy Markdown
Owner

Connect the v2 store to catalog-backed snapshots and checkpoint ownership recovery. Each store now has an explicit task ID. Snapshots publish authenticated catalog content first and capture consistent ownership, selections, generations, counters and hint bits under the store mutex; counters cannot move backwards.

Recovery checks the expected task, caller-authorized output, selection, content mapping and every OS identity/kind before adopting any records. Failed recovery leaves the store untouched and retryable. Hint bits are discarded; initialize and recheck/commit must establish availability again. Fully verified owned files are restored to exact declared lengths, while foreign replacements are neither adopted nor deleted.

Stack: based on #181, advancing #162 step 07. Atomic TaskStore publication, durable creation journals, missing-file repair/import, v1 migration, runtime state admission and engine resume wiring remain pending.

Validation: all 383 local torrent tests, both existing pinned-client v1 conformance scenarios and the native-runtime guard pass. Five recovery tests cover catalog reopening and persisted checkpoints, preserved generations/counters, failed binding retries, replacement preservation, changed payloads and exact file lengths.

@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-12T15:52:18.508542Z bbcdeb1 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

github-actions Bot commented Sep 12, 2026 •

Copy link
Copy Markdown
Contributor

Test Results

  584 files    584 suites   3m 59s ⏱️
2 536 tests 2 536 ✅ 0 💤 0 ❌
3 300 runs  3 300 ✅ 0 💤 0 ❌

Results for commit 83d22bd.

♻️ This comment has been updated with latest results.

@linroid

linroid commented Sep 20, 2026

Copy link
Copy Markdown
Owner Author

Superseded by #234 (V2 catalog, checkpoints and crash recovery) 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-07-store-recovery branch September 20, 2026 11:13
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