GeezerVison is showing github.com — impl(backups): mesh leg — OpenCode session DB backup (gated on research #9094) · Issue #13462 · developing-today/code
impl(backups): mesh leg — OpenCode session DB backup (gated on research #9094) #13462DescriptionParent: #9093 (backup mesh) · Program: #8983 · Design: doc/2026-11-23T16-34-18Z_design_backup_mesh/note.md (landed with the #9093 design PR).
House rules: any schedule this creates lands its doc/fleet-schedule-registry.md row in the same PR; secrets by name only (Bitwarden at runtime, repo-archive pattern); builds/tests run via remote dispatch, never on the laptop or sandbox.
Scope
The OpenCode session database joins the mesh. It is large on purpose (21.37 GB measured 2026-11-12, ~5.1 GB zstd) and has no scheduled off-laptop backup today (#10297, closed as the research tracker). Storage price is not the constraint; churn rate, restore time, and upload bandwidth are.
Gate
This leg is gated on research #9094 (OpenCode DB backup economics: measured churn, per-table growth model, costed comparison of full copy / zstd copy / restic deltas). Do not implement a scheme before #9094's comparison lands; the scheme choice is #9094's deliverable. When #9094 closes, this issue proceeds with the chosen scheme unmodified.
Terms (from the design, whichever scheme #9094 picks)
Acceptance
Activitydeveloping-today commented on Nov 23, 2026 dezren39 commented on Nov 23, 2026 Triage result for the OpenCode session DB backup leg:
This keeps the scheme choice with the evidence that #9094 is producing and preserves #13462's restore-verification acceptance step. developing-today-fleet commented on Nov 24, 2026
🤖 Agent note · triage re-verified, gate still closed — task 22319 (lane item-work-127)
dezren39 commented on Nov 24, 2026
Gate cleared — task 22319 triage (2026-11-24 ~19:40Z): #9094 is CLOSED with the scheme recorded (research doc §7 merged in PR #14513; handoff comment names the mesh leg unblocked). Gate-chain task 20300 is done.
Routing: enqueued follow-on implementation packet task 23638 (feature_slice, queue repo-health-code-pilot): daily zstd full copy of the OpenCode session DB to Drive + laptop archive per #9094 §7(2) beside the existing restic leg, scratch restore verification (integrity check + session row counts vs source manifest), freshness SLO against the measured ≥1-day Drive lag, registry row in the same PR. Scheme taken unmodified from the research — no re-decision in the build. dezren39 commented on Nov 24, 2026
🤖 Agent note · triage verdict, task 23639 (lane any-o)
dezren39 commented on Nov 24, 2026 Slice 1 status (lane oc-code-03, task 23638):
Scheme is #9094 section 7, implemented by #14539 (merged): restic backbone untouched, plus one daily zstd -3 full copy to the laptop archive and Drive with sha256 manifest + re-read verification.
One full cycle (2026-11-24, from #14515 drill + this slice's scratch verification):
- Source: restic snapshot 93937176c345 (06:27 CST run), 31.038 GiB restored in 125 s.
- Compress:
zstd -3, 41 s -> 5,605,852,153 B (5.22 GiB, 16.82%).
- Image sha256
973998ca03ae5dca675040d27fa40d9750c5796c42f64580d4061d53e1b8c0f8; artifact sha256 663a0bb93817399b2373e9911a8cb8a876906a34aaf88609a966033fd427bc74.
- Scratch restore (local artifact, live DB untouched): decompress 41 s, sha256 == manifest uncompressed_sha256,
PRAGMA integrity_check ok, row counts: session 515 / message 55004 / part 191248 / session_message 969724 / route_decision 4394570.
- Drive upload in flight (phase 2 on Implement daily zstd full-copy leg for the OpenCode session DB (fast-restore path) #14515, ~1.6 MB/s class); freshness SLO budgets >=1-day Drive lag, same-day off-laptop coverage not promised.
Registry: PR #14583 registers opencode-db-backup.timer (Surface 2b, daily 06:05 + 15m jitter, live-verified) with both legs and the SLO.
Two open items, both noted on #14515: (1) my drill accidentally unlinked the local 2026-11-24 .zst (stray --rm); the running Drive upload holds the inode and continues — the planned Drive-download step restores it byte-identical. (2) This morning's scheduled timer run timed out on the restic Drive leg (4h TimeoutStartSec, killed 10:11 CST after local+R2 legs verified) — the Drive restic throughput needs attention before the freshness SLO can be re-measured.
MetadataMetadataDevelopmentNo branches or pull requestsIssue actions
|