Repository navigation
Acknowledge form data that was buffered before the demuxer was created - #14456
Merged
Merged
Conversation
Data the body had buffered reaches the FormDemuxer while it subscribes, before its upstream is set, so it was counted but not acknowledged. If that data ended between two parts nothing acknowledged it later, and the upstream stopped reading once that much was outstanding.
A form that fails on the data the body had buffered fails while the demuxer subscribes, before its upstream is set, so the upstream was never told that the rest may be discarded, and the connection stalled after the error response once the buffered data had used up the read demand.
dstepanov
marked this pull request as ready for review
November 13, 2026 10:40
graemerocher
approved these changes
Nov 13, 2026
…mpleted The demand update after the demuxer starts also told the upstream that the rest of the body may be discarded when the buffered data had already completed the form, after the request body had ended. It now only runs for a form that is still open or that failed.
|
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.



Data the body had buffered reaches the FormDemuxer while it subscribes, before
its upstream is set, so it was counted but not acknowledged. If that data ended
between two parts nothing acknowledged it later, and the upstream stopped
reading once that much was outstanding.
Tests:
FormDemuxerInitialDemandTest, which fails without the change.Follow-up commit: when the buffered data already fails the form, the upstream is now also told that the rest may be discarded. New test
dataBufferedBeforeTheDemuxerThatFailsTheFormLetsTheRestBeDiscardedfails without it.