Skip to content

id: investigate global (Mainline DHT) content discovery for public worlds #2263

Open

Description

@dezren39

Parent: #2050 (investigation: BitTorrent-style chunk retrieval for graph objects), epic #2056. Follow-up D of the #2050 investigation. Investigation-sized; gated on follow-up A (in-network holder discovery) landing first.

Question

Should pkgs/id add global holder discovery for public content, using the approach n0 demonstrates in the experimental iroh-content-discovery repo: announce SHA-1(BLAKE3 hash) on the BitTorrent Mainline DHT (announce_peer/get_peers), translate returned host:port pairs to EndpointIds via a small signed-record UDP address-index service, verify candidates with a size query, then hand off to the iroh-blobs downloader? (Write-up: iroh.computer blog, "Iroh global content discovery", 2026.)

Why it needs its own investigation

  • Privacy/trust: a Mainline announcement publicly states "an endpoint at this IP claims this hash". Right for public boards/files; wrong for membership-gated worlds. Needs a per-world opt-in model (default off) and a clear statement of what the address-index service learns and stores (in-memory, expiring records, signed by the endpoint key).
  • Fit: pkgs/id already ships optional Mainline address lookup (iroh-mainline-address-lookup, Cargo feature dht) — this is Mainline content discovery, a different use of the same network; evaluate sharing the DHT node/socket machinery.
  • The experiment is upstream-immature: assess what adopting it commits us to maintaining if n0's experiment stalls.

Deliverable

An investigation doc (on this issue or linked, per repo convention) covering: the announce/lookup flow as it would work for id's public worlds; the privacy model and per-world opt-in design; address-index deployment options (run our own vs rely on discovered services); maintenance risk; and a recommendation (adopt / adapt / skip) with the follow-on implementation issue filed if the recommendation is adopt/adapt.

Acceptance criteria

Activity

  1. 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
    Contributor
  3. added
    kind/questionQuestion or design decision to resolve
    source/humanFiled directly by a human
    priority/lowNice to have; do when convenient
    effort/lLarge: multi-day or open-ended; expect staged check-ins
    meta/enrichedIntake review done: acceptance criteria, links, and normalized labels added
    on Oct 29, 2026
  4. dezren39 commented on Oct 29, 2026

    @dezren39
    MemberAuthor

    Intake review — fleet monitor, 2026-10-29

  5. added
    work/assignedQueue worker lifecycle state
    queue/claimedQueue worker lifecycle state
    and removed on Nov 3, 2026
  6. dezren39 commented on Nov 3, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · picked-up

  7. 2 remaining items

  8. added
    queue/queuedHas a queued task in the Supabase agent queue
    task/triageQueue packet kind: verify, reproduce, and route this item
    and removed
    queue/claimedQueue worker lifecycle state
    work/assignedQueue worker lifecycle state
    on Nov 3, 2026
  9. developing-today commented on Nov 3, 2026

    @developing-today
    Contributor

    agent-note:v1
    state: triaged (coverage pass)
    Coverage pass 2026-11-03: reviewed in the fleet-wide per-issue pass (drift / overlap / already-handled / stale / blockers / ordering). Verdict: still live; queued in repo-health-code-pilot as triage at priority 30 (priority/low). If this is already handled at current main, the triage closes it with evidence; if it needs splitting, the triage files the split.
    Found via: coverage pass 2026-11-03

  10. dezren39 commented on Nov 5, 2026

    @dezren39
    MemberAuthor

    Raw-conversation cross-link (WS-F2 mining pass, 2026-11-04). The scaling constraint this investigation must answer, in Drew's words from the peer-discovery plan review:

    "if its a very busy topic is all those hashes landing on the dht or just advertise/join? how does gossip work without dht? does dht not replace relay at all separate layers? if we somehow had thousands of concurrent servers running, would this be a combinatoric issue? is there ways to reduce chatter atthat level?"
    — OpenCode session ses_2ec427b80ffeuCx6dCuANmiN6c ("Peer discovery plan review"), 2026-03-23

    Three questions the investigation should treat as acceptance criteria, not background:

    1. What actually lands on the DHT. For a busy discovery topic: every content hash, or only advertise/join records for nodes? The answer decides whether global discovery scales with nodes or with content — very different ceilings.
    2. Layer separation stated plainly. DHT, gossip, and relay are separate layers with separate jobs; the investigation's write-up should say what each one carries and what breaks if one is removed (gossip without DHT is explicitly asked).
    3. Chatter at thousands of servers. If every server gossips/DHT-publishes to every other, the combinatorics are the design problem: what reduces chatter at that level (topic sharding, publish-rate limits, hierarchical or sampled propagation) — or the honest finding that the current shape caps out at a stated N, with the cap named.

    Related bounds already in the tracker from the other direction: #2944 (peer table bounding, closed) and #4004 (presence node-count bound, open) bound what one node stores; this comment is about what the network carries.

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

Metadata

Metadata

Assignees

Labels

app/idPackage/app: id (pkgs/ or apps/ in this repo)effort/lLarge: multi-day or open-ended; expect staged check-inskind/questionQuestion or design decision to resolvemeta/enrichedIntake review done: acceptance criteria, links, and normalized labels addedpriority/lowNice to have; do when convenientsource/humanFiled directly by a humantask/triageQueue packet kind: verify, reproduce, and route this item

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions