joule-contrib: a retransmission of a packet not yet seen is recovered; the SRT tests count the first sends lost #510
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/srt-tests-first-send-losses"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
These are two fixes found while chasing an SRT ingest test that failed on #505's linux-arm64 leg (4 recoveries where it required 6).
1. A retransmission of a packet not yet seen is recovered, not a first try (live-contribution §6.1)
A receiver marked a packet as recovered only when a later arrival had shown its gap. Since #503, a sender re-sends its newest packet when its acknowledgements stall (§4.1). That probe arrives before anything shows the gap, so the SRT receiver took it, R flag set, as the next packet in order. It then counted a first try for a packet whose first send was lost. The signed link record came up short on recoveries.
Both receivers now treat an arrival flagged as a retransmission, of a sequence number not yet seen and not known to be missing, as found missing on arrival. It is counted as recovered, with a recovery time of 0 µs. The flag is SRT's R flag or RIST's retransmission SSRC. §6.1's definitions and the CHANGELOG say so.
2. The SRT tests count the first sends that were lost, instead of assuming a burst's size
Both tests drop a run of datagrams by index and required that many recoveries. Control packets (ACKACKs, keepalives) take some of those indexes as the timing falls. The lossy proxy now keeps the datagrams it drops (
Counts::dropped_log, protocol-agnostic). The tests read from it the sequence numbers whose first send was lost, and require exactly that many recovered.srt_linkalso requires a loss run at least as long as the longest run of them.Evidence (Framework box, x86_64 Linux; four at once pinned to two cores)
losses_each_way_are_recovered_within_the_windowan_srt_publisher_reaches_a_relay_subscriber_with_every_receiptsrt_linkfails ("the path lost first sends of data: {}")The job's suites pass:
joule-contrib --all-targetsjoule-contrib --all-targets --features ristjoule-moq-ingest --all-targetsjoule-moq-ingest --all-targets --features ristThe link-vector corpus is unchanged (101 files). Clippy reports nothing in the changed files. The comparative-prose, vanity, spec-refs and section-refs checks pass.
🤖 Generated with Claude Code