resume: a route switch after a header-only payload stall never recovers, and hands a held group out past its max age
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 45/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Active
- Tech stack
- rust
- Domain
- backend, networking
Research direction
Start with rs/moq-net/tests/integration/route_health.rs, especially the payload_stall reproduction and a_standby_recovers_a_payload_stall_within_its_budget from linked PR #10314. Compare the Stall::Headers behavior with the Upstream and Downstream cases, then trace how resume chooses the switch boundary and handles held groups. Done when the reader recovers after a clean switch and held groups past the 2 s max age are cut as Old.
Written by the indexing model from the issue text.
Description
Problem
When the serving copy holds group headers whose frames never arrive (a header-only payload stall), resume mishandles the next route switch:
- A clean switch never recovers the reader. After a header-only stall on
M1 -> E, closing that session cleanly leavesEreading nothing for the rest of the run. One group fails asOld, and the subscription neither ends nor resumes on the healthy routeM2. The same close after an Upstream or Downstream stall (no headers held) recovers. - A held group is delivered far past its max age. With a route-health standby moving the track to
M2(https://github.com/moq-dev/moq/pull/10314), group 3, whose header the replaced copy held, is handed out about 8 s after its successors, past the reader's 2 s max age, and is never cut asOld.
Reproduction
The first reproduces on main (cbd27de054) with rs/moq-net/tests/integration/route_health.rs's payload_stall diamond (one-second groups, 2 s max age). In payload_stall, replace the stalled write(span.as_secs()).await with:
if matches!(stall, Stall::Headers) && span.as_secs() == 10 {
write(2).await;
m1_e.server.abort(Error::Stream(StreamError::Cancel));
m1_e.client.abort(Error::Stream(StreamError::Cancel));
write(span.as_secs() - 2).await;
} else {
write(span.as_secs()).await;
}
Then run payload_stall(Stall::Headers, Duration::from_secs(10)). E observes 0 frames and one Old failure. Stall::Upstream and Stall::Downstream with the same close observe 80 frames.
The second shows in #10314's a_standby_recovers_a_payload_stall_within_its_budget under Stall::Headers: group 3's frames arrive at the end of the run (stamped about 10.5 s after the stall began), while groups 4 to 11 arrive on time.
Suspect
Both involve a replaced copy that holds a group's header and none of its frames. The switch boundary is "the largest group any copy holds", so such a copy raises it, and its header-only groups are left to a copy that will never deliver them. They are then neither recovered from the serving route in time nor cut at the reader's budget.
(Written by Claude Opus 5.5)
- Dominant language
- Rust
- Stars
- 1.6k
- Forks
- 251
- Avg merge
- 10h 10m
- Merged PRs (30d)
- 822
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from moq-dev/moq
-
Difficulty 2/5 1-3 hours Newbie friendliness 77/100
moq-dev/moq#10463 · 1 comment · 1 reaction ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
moq-dev/moq#10460 · 1 comment · 1 reaction ·
Maintainers usually reply within 1 day
-
quest
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
moq-dev/moq#10373 · 2 comments · 1 reaction ·
Maintainers usually reply within 1 day
-
quest
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
moq-dev/moq#10336 · 2 comments · 1 reaction ·
Maintainers usually reply within 1 day
Similar issues
-
[Bug] AM Context Monitor (am-monitor): Session turns count is capped at 80 due to turns.slice(-80)Open
Difficulty 2/5 1-3 hours Newbie friendliness 83/100
lbjlaq/Antigravity-Manager#4180 ·
Maintainers usually reply within 1 day
-
bug triage
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
zizmorcore/zizmor#2608 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 79/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 83/100
longbridge/nsh#4201 ·
Maintainers usually reply within 1 day