Repository navigation
fix(node): count a skipped mid-stream pool re-check and test the serve-miss PoolExhausted stop - #2789
Merged
Merged
Conversation
…e-miss PoolExhausted stop Co-Authored-By: Claude Opus 5.5 <[email protected]>
There was a problem hiding this comment.
Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.
An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.
Code coverage overviewLanguages: Rust Rust / code-coverage/cargo-llvm-cov
View coverage of the 3 most impacted files.
ℹ️ Calculations represent line coverage. Results may change as calculations are updated. Updated |
…osed mid-stream The pool view drops a pool only once it is closed, so a skipped mid-stream re-check means a pool closed under a live stream, where redeemMany reverts. Say so in the helper, metric, ADR row and CHANGELOG, and replace the debug! with a throttled warn! that names the pool, signer and hash. Test the skip path inside a live stream in both loops: admission counts nothing, each skip counts, and the stream fails open to StreamEnd. In client_loopback.rs, assert a clean FIN rather than any read error, wait for the stop to be metered in the cache-hit drained-pool test, and correct the 16 MiB interval counts. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This was referenced Oct 31, 2026
Gas snapshotNo gas changes vs base. |
…-telemetry # Conflicts: # CHANGELOG.md
thiras
approved these changes
Oct 31, 2026
This was referenced Nov 1, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-ups for the mid-stream pool-solvency re-check (#2630).
drained_pool_stops_a_serve_miss_stream_after_its_floor_is_repaiddrives an own-origin, outboard-backed miss throughserve_via_backend_originand theserve_legloop, drains the pool, and asserts the in-bandPoolExhaustedstop, the clean FIN anddecdn_serve_stream_midstream_pool_exhausted_total. It proves the route withdecdn_local_outboard_serves_total == 1and no buffered origin fetch, and it fails when theserve_leg.rsre-check is deleted. The fs-origin-with-outboard setup is now a shared helper.pool_view_status_cachedcountsdecdn_serve_pool_recheck_skipped_totaland logs a throttledwarn!naming the pool, signer and hash. In production the view drops a pool only once it is closed, so a nonzero value means a pool closed under a live stream: the stream fails open, andredeemManyreverts on a closed pool, so the node is not paid for those bytes. The metric has an ADR registry row that says so.forgotten_pool_recheck_is_counted_and_a_{cache_hit,serve_miss}_stream_completesadmit on a funded view whose cached status is gone: admission counts nothing, each skip counts, and the stream runs toStreamEnd. Both fail when a loop bypasses the helper.PoolExhaustedtests assert a clean FIN (a reset now fails them), the cache-hit drained-pool test waits for the stop to be metered before reading the counter, and the 16 MiB interval counts are corrected.write_rejecttolerates a departed peer, so the stop is still returned and metered (a_departed_peer_does_not_fail_a_decided_end).pool_funds_committeddocuments the caveat, and nothing billable is at stake at rate 0.Follow-ups: #2805 (stop a stream whose pool closes mid-stream, including
Closingpast the dispute deadline) and #2806 (re-check on a stale projection).Closes #2630
🤖 Generated with Claude Code