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 — id: poc: bridge sync session — native store ↔ DO-shaped SQLite store over WebSocket, fork-proof exchange + withholding detection (from #2058) · Issue #2276 · developing-today/code

id: poc: bridge sync session — native store ↔ DO-shaped SQLite store over WebSocket, fork-proof exchange + withholding detection (from #2058) #2276

New issue
Copy link
New issue
Copy link
Closed
Closed
id: poc: bridge sync session — native store ↔ DO-shaped SQLite store over WebSocket, fork-proof exchange + withholding detection (from #2058)#2276
Copy link
Assignees
dezren39
Labels
app/idPackage/app: id (pkgs/ or apps/ in this repo)effort/mMedium: expected under 1 day of workkind/enhancementmeta/enrichedIntake review done: acceptance criteria, links, and normalized labels addedpriority/normalOrdinary priority (the default)source/humanFiled directly by a human

Description

@dezren39
dezren39
opened on Oct 29, 2026
Issue body actions

From the bridge-semantics investigation on #2058 (doc PR linked there): prove the hosted↔native seam with the smallest thing that exercises the real rules, reusing the native store machinery unchanged.

What to build (PoC only)

A bridge sync session between a native pkgs/id store and a DO-shaped SQLite store (same table shape as event_store/: events by (author, seq), chains, forks, proof_ids, proof_headers) over a WebSocket, reusing ingest_batch + resolve with no semantic changes: no bridge-assigned ordering, no re-signing, no authoritative snapshot.

Acceptance criteria

  • Push and pull across the session converge to identical applied sets and identical live tag claims on both stores
  • A fork authored on each side while disconnected is detected by the proof-carrying exchange (not LogSync height comparison) and both sides end holding the same fork proof
  • A withholding bridge (drops one author's events) is detected from chain-head / after-frontier evidence, and the detection is demonstrated in a test
  • Replaying the same journal into an empty hosted-shaped store and an empty native store yields identical stores (tables compared)
  • Findings (incl. measured fork-proof exchange cost in rows/CPU terms) recorded on this issue for the id: design: ID serverless edition v1 (Cloudflare Workers) #2046 sync-spec decision (Q1 on id: investigate: bridge semantics — hosted (HTTPS/WS) edition syncing with native Iroh nodes #2058)

Not in scope

Permanent feature work on top of this PoC (program rule: an unreviewed PoC making its own decisions is not a foundation), custodial keys, SSO binding (#2258), native multi-hop relay (#2249).

Activity

Next
  1. dezren39
    added
    app/idPackage/app: id (pkgs/ or apps/ in this repo)
    on Oct 29, 2026
  2. developing-today commented on Oct 29, 2026

    @developing-today
    developing-todayBot
    on Oct 29, 2026 – with developing.today
    Contributor
    More actions

    CODE-1137

  3. dezren39
    added
    queue/queuedHas a queued queue task
    on Oct 29, 2026
  4. github-actions
    assigned
    dezren39
    on Oct 29, 2026
  5. dezren39
    added
    kind/enhancement
    source/humanFiled directly by a human
    priority/normalOrdinary priority (the default)
    effort/mMedium: expected under 1 day of work
    status/needs-triageNot yet triaged; needs a first look
    meta/enrichedIntake review done: acceptance criteria, links, and normalized labels added
    on Oct 29, 2026
  6. dezren39 commented on Oct 29, 2026

    @dezren39
    dezren39
    on Oct 29, 2026
    MemberAuthor
    More actions

    Intake review — fleet monitor, 2026-10-29

    • Related: bridge-semantics investigation on id: investigate: bridge semantics — hosted (HTTPS/WS) edition syncing with native Iroh nodes #2058; epic epic: ID platform expansion — apps, comms, currency, hosting, boards (2026-10-28 directive, LIST 6–15) #2056. Already carries queue/queued — a live queue task exists for it (verified in this run's reconciliation).
    • Still live: filed today as a PoC; no bridge sync session exists yet.
    • Notes: body already carries acceptance criteria; none appended. Fork-proof exchange is the property under test — the PoC should state explicitly which fork case it exercises.
    • Risks: medium — WebSocket session semantics over two store shapes can sprawl; the issue's own "smallest thing that exercises the real rules" scoping is the guard.
    • Suggested approach: reuse the native store machinery unchanged (per the issue), one session, one fork case, then report back to id: investigate: bridge semantics — hosted (HTTPS/WS) edition syncing with native Iroh nodes #2058.
    • Labels normalized: kind/enhancement, source/human, priority/normal, effort/m, status/needs-triage, meta/enriched.
  7. dezren39
    added
    queue/claimedQueue worker lifecycle state
    work/assignedQueue worker lifecycle state
    and removed
    status/needs-triageNot yet triaged; needs a first look
    queue/queuedHas a queued queue task
    on Oct 30, 2026
  8. 32 remaining items

  9. dezren39
    added a commit that references this issue on Oct 30, 2026

    test(id): bridge sync session PoC — native store ↔ DO-shaped SQLite s…

    b3421ef
  10. dezren39 commented on Oct 30, 2026

    @dezren39
    dezren39
    on Oct 30, 2026
    MemberAuthor
    More actions

    🤖 Agent note · done (PoC delivered; PR awaiting CI)

    • Agent: queue worker (repo-worker-code), lane C shift
    • Session / ID: queue task 3431
    • Found via: queue claim
    • Task: Bridge sync session PoC per this issue's acceptance — delivered in PR test(id): bridge sync session PoC — native store ↔ DO-shaped SQLite store over WebSocket (#2276) #2848 (pkgs/id/tests/bridge_poc.rs, test-only)
    • Links: PR test(id): bridge sync session PoC — native store ↔ DO-shaped SQLite store over WebSocket (#2276) #2848 · branch queue/3431-2276-bridge-sync-poc · commit b3421ef

    Findings for the #2046 Q1 decision (fork-proof cadence)

    Measured on the PoC (laptop run, debug build; all 5 PoC tests pass, 10/10 with the shared test-common unit tests):

    • Fork set (2 authors' worth of state: 3 events, one fork at equal heights): proof-carrying range exchange = 4 flights, 163 reconciliation bytes — and it detected the fork that a height comparison provably misses (pre-session chains had identical next_seq, different heads).
    • Bootstrap set (100 events / 4 authors, one side empty): 4 flights, 3,235 reconciliation bytes ≈ 32.4 bytes/event — about half the naive bound of mailing every event ID both ways (6,400 B), and the flight count did not grow between the 3-event and 100-event sets at this fan-out. Session wall time 5.3 s in a debug build is dominated by per-event signature verification in ingest_batch, not by the exchange.
    • Cadence read: at wave-1 scale the exchange itself is cheap (bytes scale ~linearly at ~32 B/event with fingerprint flights, flights stayed at 4); the cost a cadence decision actually budgets is the verification of transferred events, which is paid only for the symmetric difference. Nothing in the measurements argues against running the proof exchange on every bridge session at this scale; the open part of Q1 remains the DO rows/CPU accounting on the Workers side, which this PoC does not measure (no Workers runtime here).

    What the PoC proved, per acceptance

    • Convergence: push+pull in one session → identical applied sets (store canonical state) and identical live tag claims on both stores.
    • Forks: a fork authored on each side while disconnected is detected by the proof-carrying exchange (≥1 Ingest::Fork outcome per side), and both sides end holding the identical fork proof (same seq, same first/second IDs).
    • Withholding: a relay that drops one author's events is detected from the announced chain head (seq 4 / head hash) plus the after-frontier reference inside a signed event that did arrive (the receiver holds that event waiting on exactly the withheld hash). Detection names the author, the announced head, and the undelivered event IDs; the honest-session control produces no evidence, and an author whose events arrived but waits on the withheld dependency is not itself flagged.
    • Replay identity: the same journal replayed into a fresh native store and a fresh hosted (SQLite) store — in opposite arrival orders — produces identical tables (events / chains / forks / proof_ids / proof_headers compared row-for-row).

    Limitations (stated in the PR as well)

    • The sync set is enumerated via the store's public read API, which exposes the lowest fork proof per author; the internal sync set also carries higher fork points' proof headers.
    • The hello's chain heads are unsigned in the PoC; production evidence for the head half of withholding detection arrives inside signed events (backlinks / after), which is the half the frontier test exercises with real signatures.
    • The hosted store's SQLite tables are mirrored from the same ingest outcomes in the same step (one batch = one transaction, the DO write shape); a rusqlite-native ingest port is separate work, not needed for the semantics questions this PoC answers.
  11. dezren39 commented on Oct 30, 2026

    @dezren39
    dezren39
    on Oct 30, 2026
    MemberAuthor
    More actions

    🤖 Agent note · parked

    • Agent: queue worker (repo-worker-code), lane C shift
    • Session / ID: queue task 3431
    • Found via: queue claim
    • Task: PoC delivered in PR test(id): bridge sync session PoC — native store ↔ DO-shaped SQLite store over WebSocket (#2276) #2848 and findings posted on this issue; parked pending CI on the PR (resume: read PR checks fresh, disposition any Codex findings, merge under the standing criteria, then complete task 3431).
    • Links: PR test(id): bridge sync session PoC — native store ↔ DO-shaped SQLite store over WebSocket (#2276) #2848
  12. dezren39
    added
    queue/parkedQueue task is parked (waiting on CI, time, or an event)
    status/parkedDeliberately paused with a recorded resume condition
    and removed
    status/in-progressQueue worker lifecycle state
    queue/claimedQueue worker lifecycle state
    on Oct 30, 2026
  13. dezren39
    added 2 commits that reference this issue on Oct 30, 2026

    test(id): address Codex review on bridge PoC — waiting-event snapshot…

    d14d26b

    Merge pull request #2848 from developing-today/queue/3431-2276-bridge…

    d2eb34e
  14. dezren39 commented on Oct 30, 2026

    @dezren39
    dezren39
    on Oct 30, 2026
    MemberAuthor
    More actions

    🤖 Agent note · done

    • Agent: queue worker (repo-worker-code), openchamber scheduled lane
    • Session / ID: queue task 3431
    • Task: Bridge sync session PoC per this issue acceptance (id: poc: bridge sync session — native store ↔ DO-shaped SQLite store over WebSocket, fork-proof exchange + withholding detection (from #2058) #2276) — delivered and merged in PR test(id): bridge sync session PoC — native store ↔ DO-shaped SQLite store over WebSocket (#2276) #2848 (merge commit d2eb34ed9d344a8cebd8e7caf0e9071ba38fbbae).
    • Codex review resolution:
      1. Added EventStore::waiting_event to look up and decode events directly from WAITING rows, updated held_events to retrieve waiting events, and added bridge_session_converges_with_waiting_events_on_both_sides.
      2. Added sparse_fork_reconciliation_scales_sublinearly_across_set_sizes demonstrating that for a single-fork difference against shared histories of 20, 60, and 100 events, exchange flights remain constant (5) and bytes grow sublinearly (1,036 to 1,356 bytes).
    • Verification: 12/12 tests in bridge_poc.rs passed cleanly on laptop; PR merged into main.
    • Links: PR test(id): bridge sync session PoC — native store ↔ DO-shaped SQLite store over WebSocket (#2276) #2848 · merge commit d2eb34ed9d344a8cebd8e7caf0e9071ba38fbbae
  15. dezren39
    closed this as completedon Oct 30, 2026
  16. dezren39
    removed
    status/parkedDeliberately paused with a recorded resume condition
    queue/parkedQueue task is parked (waiting on CI, time, or an event)
    work/assignedQueue worker lifecycle state
    on Oct 30, 2026
  17. dezren39
    added a commit that references this issue on Oct 31, 2026

    fix(id): make the no-SQLite guard read the resolved graph, not the ra…

    6aaef4b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @dezren39
    dezren39

Labels

app/idPackage/app: id (pkgs/ or apps/ in this repo)effort/mMedium: expected under 1 day of workkind/enhancementmeta/enrichedIntake review done: acceptance criteria, links, and normalized labels addedpriority/normalOrdinary priority (the default)source/humanFiled directly by a human

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    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.