Repository navigation
fix(net): keep a backup for a group read from a single route - #6485
Conversation
Quest-Claim: b3652e0b6cb136bf
A resumed reader recorded a handed-out group only while copies overlapped, so a group first read from one route was never backed: a later copy that held it was dropped, and a failure of the original copy stalled the read until the reader's budget ended it with Error::Old. Record every handed-out group, as JS already does; the existing sweep keeps the list at the live group count. Adds origin/passthrough, reading one-frame groups through a single-route front over readers and groups held open, so the per-group record shows up. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EeyiEy5FWz3z44DYZVo7vU
|
Outcome: quest complete. Reproduced on main with a polling regression test, fixed at the source by recording every handed-out group in Suggested follow-up: two (Written by Claude Opus 5.5) |
|
Warning Review limit reachedYou'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 34 minutes. View limit details
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. Comment |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Merging. The maintainer chose /quest-merge. CI is green, the current head has a non-Grok review, and (Written by Claude Opus 5.5) |
Completes
quest/m1/resume-handed-out.md.Problem
Reader::hand_out(rs/moq-net/src/model/resume.rs) recorded a handed-out group on the reader'soutlist only whilecopies.len() > 1. A group first read while only one copy existed was never recorded, so a later copy holding it was let go. Reproduction: read the first frame of group 0 from A; swap to B, which holds all of group 0; B's route fails, keeping its finished group; swap to C, which lacks group 0, and read group 1; A's partial group 0 fails. B was already dropped, so the read stalled until the reader'smax_delayended it withError::Old.Fix
Record every handed-out group, dropping the guard, matching JS (#6136). The existing sweep in
hand_outkeeps the list at the live group count.a_group_read_from_a_single_route_keeps_its_backup(explicit polling, no wall clock); fails on main, passes here.origin/passthroughinrs/moq-net/benches/origin.rs: one-frame groups through a single-route front, swept over readers (1, 100) and groups each holds open (1, 64), so the per-group record shows up as a slope.Bench, fixed vs. guard restored (
--baseline), per group read:All within noise; no slope over open groups. (The guard run still allocated the
Arc, so it slightly understates the old path's saving.)JS
js/net/src/resume.tsalready records every group (Recoverconstructor adds toreader.outunconditionally), and the existing test "a clean end keeps the serving copy while a group handed out before the swap may continue from it" fails if the guard is reintroduced. No JS change.Impact
Checks
just check: passed (2 pre-existing SLOW flags in unrelatedmoq-muxTS import tests).just rs test -p moq-net: 3058 passed.cargo bench -p moq-net --bench origin -- origin/passthrough: ran, numbers above.just test interop --all(no wire or FFI change).🤖 Generated with Claude Code
https://claude.ai/code/session_01EeyiEy5FWz3z44DYZVo7vU