Skip to content

id: PoC — multi-provider chunk-range retrieval in the get path (swarm scheduler over iroh-blobs) #2261

Open

Description

@dezren39

Parent: #2050 (investigation: BitTorrent-style chunk retrieval for graph objects), epic #2056. Follow-up B of the #2050 investigation. Depends on the holder-discovery follow-up A (provider table) — a hand-fed provider list is acceptable for the PoC's benchmarks.

Problem

Retrieval in pkgs/id is single-source: src/commands/get.rs does one store.remote().fetch(conn, hash) over one connection. iroh-blobs (0.103, in Cargo.toml) already supports the swarm-shaped pieces — (hash, ChunkRanges) requests per provider, bao verified streaming (each 16 KiB chunk group verified against the blob's BLAKE3 root hash as it arrives, from any source, in any order), partial-blob state in FsStore, and providers reporting the exact missing location when they close a stream for data they lack. What does not exist is the scheduling policy that uses several holders at once.

Scope — PROOF OF CONCEPT (review-gated; do not build the permanent feature on it)

Implement the #2050 §5 retrieval flow as a PoC in the get path:

  • Wanted-set = chunk-group ranges of the hash; assign ranges rarest-first across the provider set; disjoint ranges per holder; start with ≤4 concurrent sources.
  • Verified groups persist to FsStore immediately (resume + become servable partial state). Bad group → discard, requeue range, deprioritise that holder for the hash. Missing-range stream close → shrink that holder's ranges, requeue elsewhere.
  • Endgame: duplicate-request trailing in-flight ranges; first verified copy wins.
  • Works in both discovery modes from id: investigate: BitTorrent-style chunk retrieval for graph objects #2050: observe-informed (held ranges known) and optimistic (observe off/refused — learn from missing-range reports).
  • Nobody-home case surfaces distinctly ("0 holders for ranges X–Y", resumable from persisted partial state), never as a generic transfer failure.

Benchmarks required (n0 notes multiprovider single-blob download efficiency is still maturing upstream — measure, don't assume)

  • 1 vs 2 vs 4 holders, complete holders; a partial-holder mix (e.g. two 50% holders with disjoint ranges); one holder leaving mid-transfer; observe-off mode.
  • Report wall time + bytes duplicated vs the single-source baseline on the same blob sizes.

Acceptance criteria

  • PoC branch/PR demonstrates a zero-local-copy fetch of a blob from ≥2 holders with per-range provenance logged.
  • Benchmark table posted on this issue; failure/stall cases above behave as specified.
  • The PR is explicitly a PoC: a review round decides what (if anything) becomes the permanent retrieval path. Nothing merges to main as "the feature" without that review (program rule from id: investigate: BitTorrent-style chunk retrieval for graph objects #2050 / Drew 2026-10-28).

Activity

  1. added
    app/id
    on Oct 29, 2026
  2. developing-today commented on Oct 29, 2026

    @developing-today
    Contributor
  3. added
    queue/queued
    status/needs-triage
    task/small-fix
    on Nov 1, 2026
  4. dezren39 commented on Nov 1, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · handed off

  5. added
    work/assigned
    queue/claimed
    status/in-progress
    and removed
    status/needs-triage
    queue/queued
    on Nov 1, 2026
  6. dezren39 commented on Nov 1, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · picked up

  7. dezren39 commented on Nov 1, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · parked

  8. added
    queue/parked
    on Nov 1, 2026
  9. 194 remaining items

  10. dezren39 commented on Nov 26, 2026

    @dezren39
    MemberAuthor

    Coverage triage — OpenChamber lane oc-code-05, 2026-11-26.

    Verdict: not a small fix; return to real work. The core scheduler and fixture-simulated matrix are present via merged PR #10660, but #2261's acceptance remains incomplete: the live id-cli get path has not demonstrated multi-holder retrieval with per-range provenance, and the live-holder benchmark matrix is still outstanding. The issue's recorded Adapt decision is respected: any continuation remains an experimental PoC and must not be merged/described as the permanent feature without the review round.

    The previous queue tasks for this issue (#5810 and #21503) are done, not live coverage. Fresh fleet shell targets reports laptop and Codespaces unreachable (Actions and local reachable); this is noted for the implementation task, not treated as a reason to leave the issue uncovered.

    Enqueued a distinct continuation task for the remaining PoC integration and live measurements. It requires fresh premise checks, isolated worktree, targeted tests and review-gated PR/evidence.

  11. dezren39 commented on Nov 26, 2026

    @dezren39
    MemberAuthor

    Progress — Lane oc-code-07 (task 24313)

    Experimental PoC only; Adapt boundary preserved. Default get path untouched; no merge.

    • Branch oc-code-07/2261-live-poc, commit 70b28729219: doc-only clarification in pkgs/id/crates/id-core/src/swarm.rs. Pinned iroh-blobs 0.103.1 finding: Remote::fetch is whole-hash only and cannot drive holder-specific assignments; viable primitive is Remote::execute_get(conn, GetRequest::blob_ranges(hash, ChunkRanges)), with chunk/group alignment 16 KiB. Open gap named: progress reports bytes, so completion/error to Verified/Missing/BadGroup translation (including missing-vs-failed) is still unwritten.
    • Draft review-gated PR opened: Clarify #2261 swarm PoC transport boundary #15735 (Part of #2261, draft, base main). It does not close id: PoC — multi-provider chunk-range retrieval in the get path (swarm scheduler over iroh-blobs) #2261.
    • Remote targeted CI dispatched: https://github.com/dezren39/fleet/actions/runs/45902208654 (cargo test --manifest-path pkgs/id/Cargo.toml -p id-core --test swarm_bench, handle fp_1f040fe2a4cf55418491ccbd9f772b19). Still in_progress at this checkpoint; compilation otherwise unverified. Parent did not run a local build.
    • Remaining, in order: new id-core scheduler-to-fetch driver module; holder (name, Connection, HeldRanges) identity decision; two-holder loopback proof test; opt-in get wiring plus ProviderTable input; then live benchmark matrix. Parking this claim with those resume points; not awaiting a person.
  12. developing-today-fleet commented on Nov 28, 2026

    @developing-today-fleet
    Contributor

    Re-check (code-f, task 24313): PR #15735 still OPEN on branch oc-code-07/2261-live-poc (single commit 70b2872, no activity since 2026-11-26T22:02Z); #2261 still OPEN. Owning lane oc-code-07 still holds the branch — per one-writer rule, no second writer. Re-parked deferred-to-owning-lane; resume when #15735 merges/closes or the branch is released.

  13. developing-today-fleet commented on Nov 28, 2026

    @developing-today-fleet
    Contributor

    Second-pass re-check (~00:57Z): owning lane still holds the branch — parking with a time-based resume, no second writer.

    Fresh verification:

    Per the one-writer rule the slice stays with oc-code-07. Parking task 24313 with not_before 2026-11-28T02:00Z for the next re-check; resume condition is time, not a person.

  14. added a commit that references this issue on Nov 28, 2026
  15. developing-today-fleet commented on Nov 28, 2026

    @developing-today-fleet
    Contributor

    oc-code-06 PoC slice landed as draft #16409 (own branch oc-code-06/2261-live-poc; oc-code-07's branch untouched; default get path untouched; review-gated, do not merge as the feature).

    What it proves (live loopback, real Remote::execute_get + ChunkRanges, 8 groups = 128 KiB):

    • two-holder split: 1 wave, ~133ms wall, duplicated_bytes=0, provenance names both holders, bytes match.
    • holder-leaving mid-fetch: partial wave with both alive, B killed (router shutdown + endpoint close); endgame duplicate onto survivor A wins, completes, bytes match (~38ms wall, waves=1, provenance names both).
    • driver mapping pinned by fake-transport unit tests (Verified/BadGroup-failover/endgame-dup accounting).

    Scheduler fix in slice: Missing on a Complete holder downgrades to explicit ranges (a dead Complete holder was otherwise retried forever); Unknown loses score. Prior stalled form of the leaving test hit 3x20s timeouts (60s wall); restructured to kill between waves so endgame is exercised and the suite runs in <1s.

  16. removed
    queue/claimed
    on Nov 28, 2026
  17. dezren39 commented on Nov 28, 2026

    @dezren39
    MemberAuthor

    Lane 1322-D triage disposition (queue task 24320, delta PRESS run 2026-11-28) — remainder in flight under owning lanes; no second writer.

    Premise + ownership check, fresh firsthand this lane (gh CLI only, issue + all 62 comments read):

    Disposition: queue task 24320 parked. Ready condition (non-person): PR #16409 or PR #15735 merges or closes — then re-triage the remainder against the issue's acceptance criteria (benchmark table posted + review-round decision recorded).

  18. dezren39 commented on Nov 28, 2026

    @dezren39
    MemberAuthor

    Lane 1422-F (delta PRESS 2026-11-28) concurs with lane 1322-D's disposition (comment 7244584679) after independent firsthand re-check: issue + all 63 comments read; draft PR #16409 and draft PR #15735 both still OPEN drafts / CLEAN / MERGEABLE, owned by oc-code-06/07, review-gated. Queue task 24320 re-parked with non-person wake: PR #16409 or #15735 merges or closes → re-triage remainder.

  19. added
    priority/normal
    on Nov 29, 2026
  20. dezren39 commented on Nov 29, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · census 2026-11-29 (lane CEN-C03)

    Census verified: status/in-progress is accurate; scope and PoC guardrails are fully specified (review-gated, do not build the permanent feature on it). Blocker: none — a hand-fed provider list is acceptable for the PoC per the body. Labels: added priority/normal (none existed).

  21. developing-today-fleet commented on Nov 29, 2026

    @developing-today-fleet
    Contributor

    Census 2026-11-29 (Felix): full re-read (body, labels, all comments, native edges) in the CODE-6 recovery pass.

    STRENGTHS: complete decision record (PoC landed review-gated via PR #10660; draft PRs #16409/#15735 carry the review surface); criteria 1-2 verified met in-thread.
    GAPS: none material for pickup.
    FIXES I APPLIED: none needed — priority/normal was added by the parallel census pass today; status labels are accurate.
    REMAINS: criterion 3 is Drewry's Adopt / Drop / Adapt call on the swarm substrate — FOR DREWRY. It also gates #2262's remainder.

  22. developing-today-fleet commented on Nov 29, 2026

    @developing-today-fleet
    Contributor

    Issue census — 2026-11-29

    Wave-2 census pass (group code-01409-03205): rechecked live state, body, labels and recent comments firsthand via fleet gh immediately before editing.

    Strengths: detailed body (2631 chars) with context a picker-up can start from; acceptance criteria present in the body; single taxonomy priority band (priority/normal) — verified against live labels.

    Gaps found: none material.

    Actions taken this pass: labels: +['kind/enhancement'] -[].

    Priority: priority/normal — checked against content, unchanged (no reprioritization). No closing keywords used; issue left open.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    app/idepic/id-programkind/enhancementpriority/normalsource/creatorstatus/in-progresstask/small-fixwork/assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions