GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — docs(fleet): settle namespaced KV storage, sweep and blob design (#10359) by dezren39 · Pull Request #13294 · developing-today/code

Conversation

@dezren39

@dezren39 dezren39 commented Nov 23, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Summary

fleet kv design (no implementation)
├── local SQLite + namespaced overrides + durable session sweep
├── central CAS / conflict history / five-agent topology
└── shared ID content plane + authenticated blob references

Standalone design-mill record for #10359, coordinated with #9107, #9120 and #9084. Human-review: None; defaults are agent-preliminary, not human-confirmed.

Build sub-issues (all require this design merge): #13314 → #13316 → #13318. GitHub blocked-by edges and same-pass pilot coverage are recorded (tasks 21316 / 21317 / 21318). Phase 3 is blob-only; lists/tables remain later expansion.

Lane any-n, task 21123, parent 20571. Sole document writer on the supplied worktree; fresh independent compatibility, primary-source, challenge and spec reviews. Parent lane retains queue completion and merge to main.

Closes #10359. Closes #12892.

Evidence

  • Before: Design: fleet kv — namespaced key-value store (local + global), blob offload to content-addressed R2 #10359 had no fleet-kv decision record or phased build issues; repeated route-capacity parks produced no design.
    After: cohesive decision record and human-review sheet; Design: fleet kv — namespaced key-value store (local + global), blob offload to content-addressed R2 #10359 acceptance updated with reviewed source and three concrete build handoffs. Fresh spec reviewer reports Must fix: none at 5ac3ddcec60017b05b655b8fe665b06c61369ec3; later changes are only delivery bookkeeping plus merges from main. Challenge/re-investigation/re-challenge completed (D001/D008 retained, D002→D014 and D013→D015); published-issue zero-context reader reports blocking questions: NONE.
  • Focused checks: git diff --check; prettier --check on both new documents; python3 -I scripts/research_workflow.py check --path <design-record> --path <human-review> (workflow/link/profile validator). Final head/base/SHA gate recorded in the PR comment before handoff.
  • .github/ci-policy.md: no automatic PR CI or required PR checks. No runtime suite dispatched for this documentation-only design; the future phase commands/oracles are requirements, not claimed passes.
  • No KV implementation, database provisioning, deployment, or runtime tests claimed.

Merge Danger

Door: two-way

Documentation only; design choices remain agent-preliminary and reversible.

Blast Radius: planning

Actual main merge belongs to parent lane any-n after its own diff verification and fresh SHA-gate check. This executor leaves the PR open, not merged.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
dezren39 added 2 commits November 23, 2026 06:58
@dezren39
docs(fleet-kv): reconciled sole design prose + human-review for #10359
a40d74e
Compat: threshold subordinate to shared partition policy (#9084 16KiB),
Part A preserved, hosted data-plane refusal, F12.5 not-this-surface,
Turso embedded-replica vs Sync distinguished, fixture figures labelled.
@dezren39
Merge remote-tracking branch 'origin/main' into lane-any-n/12892-flee…
ba786bc
…t-kv-design
@coderabbitai

coderabbitai Bot commented Nov 23, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 16 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 6565872b-513a-409f-851d-a4fdadb72baf
Commits

Reviewing files that changed from the base of the PR and between a9f95bd and 4434259.

Files selected for processing: 2

  • doc/2026-11-23T12-45-00Z_design_fleet_kv/2026-11-23T12-45-00Z_design_fleet_kv.md
  • doc/2026-11-23T12-45-00Z_design_fleet_kv/human-review.md
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

  • X
  • Mastodon
  • Reddit
  • LinkedIn
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dezren39 dezren39 mentioned this pull request Nov 23, 2026
Design: fleet kv — namespaced key-value store (local + global), blob offload to content-addressed R2 #10359
Closed
2 tasks done
dezren39 added 3 commits November 23, 2026 07:06
@dezren39
docs(fleet-kv): challenge outcomes D014/D015, reverse D002/D013, mini…
774920d
…mal human-review

Adopts readonly investigator outcomes dated 2026-11-23:
D001 retained (standalone Turso local-only steelmanned/rejected),
D002 reversed/superseded by D014 hybrid placement (shared primary
default + explicit-grant group DBs, fail-closed policy, v1 ops
integration required), D008 retained (5 attempts/jitter cap 1s,
ordinary cache age 1s, --global bypass, KV != queue lease),
D013 reversed/superseded by D015 (blob-only phase 3, versionable
envelope seam). Human-review reduced to None per minimal policy.
Phase drafts (tmp/opencode) updated: standalone #10359 links,
decision IDs, #13294 prereq, blob-only phase 3.
@dezren39
docs(fleet-kv): round2 correctness repairs — ScopeId, fence, idem key…
6126077
…s, publication= CAS

(1) Central key is (scope_id, registry_id, ns, key); shared scope
per shared namespace, private scopes separate, plain read checks
overlay then one selected scope only. (2) clear-override advances
a generation fence cancelling pending intents; in-flight CAS states
linearization. (3) 15m is a checkpoint TARGET; Phase 2 archives
inline-only, over-threshold reports
protection_unavailable_needs_phase3; local working files streamed +
atomic ref. (4) cache miss/expiry refreshes or typed stale;
--allow-stale opt-in. (5) GC roots incl. versions/conflicts/
archive refs/pins. (6) group DBs inline-only;
blob_requires_shared_primary. (7) idem key
(writer, incarnation, outbox UUID) + fingerprint; rebase is new
intent. Final re-challenge recorded (D001/D008/D014/D015 sound).
@dezren39
docs(fleet-kv): closure repairs — full central key, clear serializati…
5ac3ddc
…on, RPO wording

Full (scope_id, registry_id, namespace, key) in every CAS/history/
conflict/receipt/fingerprint/schema reference. clear-override holds
the per-key local lock against sweeper network submission (5s
bounded wait, typed busy); in-flight = irrevocably submitted only.
15-min is an online checkpoint target; unarchived offline loss
unbounded (line71, Consequences, D006). Phase drafts: pinned design
URL, Phase1 identity accessor/session_state.rs bound, --to version
ID, terminal cancellation, working-file backup, proposed
fleet-kv test crate + nonzero-count done checks; Phase2 FLEET_KV_URL,
scope-derived central key, backup/archive command, REQUIRED
correctness-only probe, pending_needs_phase3; Phase3 effective=min
formula, scope-policy jurisdiction/tier, shared-primary
partition_fences, no lists/tables.
This was referenced Nov 23, 2026
Build: fleet kv phase 1 — local verbs, scoped SQLite and backup #13314
Closed
Build: fleet kv phase 2 — central CAS, shared namespaces and session sweep #13316
Open
Build: fleet kv phase 3 — authenticated blob offload and reference-safe GC #13318
Open
@dezren39
docs(fleet-kv): delivery update — phase issues, chain, signoff
ea76fc8
Append dated delivery section: build issues #13314/#13316/#13318
(subissues of #10359, pilot tasks 21316-21318, tier crucial, hard
chain #13314 -> #13316 -> #13318, all gated on #13294), reviewer
signoff (Mustfix NONE at 5ac3ddc), challenge final, truthful
no-runtime-tests statement. Phase-2 draft ref -> live issue;
human-review link clickable. Bookkeeping only, no arch change.
This was referenced Nov 23, 2026
epic(id): Part A — ID core: namespaces, ID shapes, triples, user attributes #9107
Closed
design(id): content-addressed namespace (core a) spec #9120
Closed
design(pm-stack): content-addressed media/data plane — R2 dedup, reference-based access, GC when the last reference drops #9084
Open
@dezren39
Merge remote-tracking branch 'origin/main' into lane-any-n/12892-flee…
7be310b
…t-kv-design
@dezren39
dezren39 marked this pull request as ready for review November 23, 2026 13:28
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 23, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

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

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-23T13:38:26.175120Z 4434259 New commits
ℹ️ 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.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dezren39
Merge remote-tracking branch 'origin/main' into lane-any-n/12892-flee…
7926080
…t-kv-design
chatgpt-codex-connector[bot]
chatgpt-codex-connector Bot reviewed Nov 23, 2026
View reviewed changes

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 7be310b318

ℹ️ 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".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread doc/2026-11-23T12-45-00Z_design_fleet_kv/2026-11-23T12-45-00Z_design_fleet_kv.md
Comment on lines +164 to +165
- **Upload safety:** `put_staged → verify (length + BLAKE3-256 recomputed on receipt, streaming) → publish`. Upload→verify yields a staged/verified object held only by a temporary staging pin/lease — staging state, never an accepted object (same invariant as A-9120.1 and component-F staging). **Publication is the CAS + authoritative ref-registration transaction** (publish-CAS, §4–§5): only that transaction makes the reference row writable/readable. Crash before CAS leaves a staging-pinned object that staging TTL may safely reap (no read path can reference it). Crash after CAS leaves a retained ref root that only grace/GC may retire. An object marked "published" anywhere before its CAS is an orphan: it is retained under grace/GC rules, never reaped by staging TTL — there is no gap between the ref check and the deletion fence because both run against the same primary (§10 ordering below). Multipart completion is not publication; only the service verification step plus the publish-CAS makes the reference row writable.
- **GC safety:** mark-and-sweep per partition exactly as component F §6. GC roots are the full retained set: **published** rows in `kv_heads`/`kv_blobs`, plus retained `kv_versions` rows, proposed refs recorded in `kv_conflicts`, archive/snapshot refs until their actual expiry, dedup active pins, and every other DB root that names a content id. Intermediate `staged`/`verified` states live only in the endpoint's staging area under the staging pin, never in central rows — central accepts `published` only, and only via publish-CAS. The sweep shares component F's per-partition serialization point concretely: KV reference creation (publish-CAS) and the GC delete fence are transactions against the same central primary, ordered by the per-partition sequence the primary assigns. A reference created during candidate/grace/re-verify races is thereby ordered: a publish-CAS landing before the fence's re-verify is seen and clears candidacy; one landing after finds no verified replica under the fence and the writer re-stages from its held bytes (a re-upload, not data loss). Per-jurisdiction dedup partitions from #3401 bound every sweep (D012); the derived index is a cache; re-verify at grace expiry; epoch-fenced delete; audit event per delete.

@chatgpt-codex-connector chatgpt-codex-connector Bot Nov 23, 2026

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Retain losing blob proposals when the head CAS fails

When an over-threshold write loses CAS, §5 requires its proposed value to remain retrievable in kv_conflicts, but that value must be a blob reference and this protocol only publishes the blob when the head CAS succeeds. The losing object therefore remains staged and eligible for staging-TTL deletion; listing conflict references as GC roots does not protect it from that separate cleanup path. After staging expiry and loss of the source host, the conflict record cannot recover the losing bytes. Define a failed-CAS transaction that also publishes/registers the retained conflict reference, or another durable retention path, before acknowledging the conflict.

Useful? React with 👍 / 👎.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread doc/2026-11-23T12-45-00Z_design_fleet_kv/2026-11-23T12-45-00Z_design_fleet_kv.md
**Backup/restore (§7, D001 detail; numbers are defaults in effect).** Two destinations, both concrete:

1. **Local file snapshot** (survives process death, not disk loss): SQLite backup API or filesystem snapshot of file + WAL into `~/.local/share/fleet/kv/backups/` every **6 h**, plus a `backup manifest` row (host, file hash, WAL frame, timestamp) in the outbox. RPO for process-death recovery: last write (WAL replay).
2. **Survival archive** (survives disk loss when reachable): the sweeper uploads the session dirty set to the central archive scope on session end and every **15 min** during a live session. The 15-minute figure is an online successful-checkpoint TARGET, not an unconditional RPO: with no network, no successful checkpoint, or disk destruction before the next upload, the loss window for unarchived writes is unbounded, and the CLI must report that plainly. The Phase 2 archive carries inline payloads only, up to the effective threshold (§8); over-threshold bytes stay local-working (§8) until Phase 3 exists, and the archiver explicitly reports them as `protection_unavailable_needs_phase3` instead of pretending they are archived. Large working blobs are part of the snapshot only once reference placement exists: the manifest lists staged content ids, and restore re-publishes or re-links them.

@chatgpt-codex-connector chatgpt-codex-connector Bot Nov 23, 2026

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Include cleared overrides in survival-archive checkpoints

If an inline override is archived and then removed with clear-override, later successful checkpoints have no removal to upload: §3 deletes the overlay and cancels its unsent intents without creating replacement work, while §4 obtains the dirty set from the outbox. Restoring the archive after disk loss can therefore resurrect the cleared override and shadow central state again, even after a successful post-clear checkpoint. Specify an archive-only removal/generation record or a complete overlay snapshot so archive restoration preserves the clear without modifying central heads.

Useful? React with 👍 / 👎.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@dezren39

dezren39 commented Nov 23, 2026

Copy link
Copy Markdown
Member Author

Final handoff — lane any-n, task 21123 / parent 20571

PR remains OPEN, not merged. Parent lane any-n owns diff verification, merge to main and terminal queue disposition.

SHA gate (2026-11-23 13:30 UTC)

  • Local reported HEAD = git ls-remote origin refs/heads/lane-any-n/12892-fleet-kv-design = PR head = 7926080c4630df0e86a2a05685816472a3bce275.
  • Fetched origin/main = GitHub PR base = git merge-base HEAD origin/main = 57743078f35481eb12dd4dc315b0a3cc888d79f5.
  • git merge-base --is-ancestor <base> HEAD: passed. Reviewed source 5ac3ddcec60017b05b655b8fe665b06c61369ec3 is also an ancestor of HEAD; changes since it are delivery links/signoff bookkeeping and merges from main.
  • GitHub: OPEN, not draft, MERGEABLE / CLEAN at this head/base snapshot. Recheck immediately before parent merge because main moves.
  • HEAD is not an ancestor of origin/main: intentionally unmerged. Worktree clean; no worker still writing.
  • origin/main...HEAD: exactly 2 new documentation files, 269 insertions under doc/2026-11-23T12-45-00Z_design_fleet_kv/; no implementation changes.

Validation and artifacts

  • git diff --check: pass.
  • prettier --check on the design record and human-review.md: pass.
  • python3 -I scripts/research_workflow.py check --path <design-record> --path <human-review>: ok: true (link/profile validation; two existing packages also checked). No synthetic research package/lease was fabricated for this standalone design issue.
  • Final independent spec reviewer: Must fix: none. Decision challenge → investigation → final re-challenge completed; active D001/D003–D012/D014/D015; D002 and D013 retained as reversed/superseded. Human-review: None.
  • Published-issue zero-context reader: blocking questions NONE; SHA-pinned source and root-runnable future done checks verified.
  • Design: fleet kv — namespaced key-value store (local + global), blob offload to content-addressed R2 #10359 acceptance checkboxes updated with explicit open/unmerged caveat, reviewed source, phases and evidence. Coordination posted to epic(id): Part A — ID core: namespaces, ID shapes, triples, user attributes #9107, design(id): content-addressed namespace (core a) spec #9120, design(pm-stack): content-addressed media/data plane — R2 dedup, reference-based access, GC when the last reference drops #9084.
  • Build subissues: Build: fleet kv phase 1 — local verbs, scoped SQLite and backup #13314 → Build: fleet kv phase 2 — central CAS, shared namespaces and session sweep #13316 → Build: fleet kv phase 3 — authenticated blob offload and reference-safe GC #13318, with GitHub blocked-by edges and design-merge prerequisites. No phase executed.
  • Same-pass triage tasks: 21316 / 21317 / 21318. During this run other lanes completed triage 21316/21317 and created live build successors: 21319 (parked, Build: fleet kv phase 1 — local verbs, scoped SQLite and backup #13314) and 21320 (parked, Build: fleet kv phase 2 — central CAS, shared namespaces and session sweep #13316); 21318 remains blocked for Build: fleet kv phase 3 — authenticated blob offload and reference-safe GC #13318. Thus all open phase issues still have live pilot coverage. Do not treat completed triage as the current implementation task.
  • CI policy: no required or automatic PR CI. Only CodeRabbit completed NEUTRAL at the snapshot; not a runtime test. Runtime suites, provisioning, deployment and performance/billing claims are not run/not made in this docs-only work.

Non-blocking implementation evidence gaps

Turso group-DB limits/pricing, production grant/admission wiring, actual workload performance, true-delete retention and future list/table schemas remain implementation-owned evidence or explicitly deferred scope, not owner-approval gates. Offline/unarchived disk loss has an unbounded loss window; 15 minutes is an online checkpoint target only.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dezren39 dezren39 mentioned this pull request Nov 23, 2026
Summit design owner for #10359 fleet kv #12892
Closed
@dezren39
Merge remote-tracking branch 'origin/main' into lane-any-n/12892-flee…
4434259
…t-kv-design
@dezren39
dezren39 merged commit 50241f4 into main Nov 23, 2026
1 check passed

Uh oh!

There was an error while loading. Please reload this page.

@dezren39
dezren39 deleted the lane-any-n/12892-fleet-kv-design branch November 23, 2026 13:37
@dezren39 dezren39 added the audit:complete PR fully implemented spawning issue label Nov 24, 2026
@dezren39 dezren39 mentioned this pull request Nov 24, 2026
pm stack: close authority — automation must never close an issue #10136
Open
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@chatgpt-codex-connector chatgpt-codex-connector[bot] chatgpt-codex-connector[bot] left review comments

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

audit:complete PR fully implemented spawning issue

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Summit design owner for #10359 fleet kv Design: fleet kv — namespaced key-value store (local + global), blob offload to content-addressed R2

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@dezren39
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.