GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||||||||||||||||
GeezerVison is showing github.com — Http2ConnectionHandler: report at most one stream error for a CompositeStreamException by normanmaurer · Pull Request #17470 · netty/netty Conversation
Member
Motivation: RFC 9113, Section 5.4 states that implementations SHOULD report at Modifications:
Result: Only one RST_STREAM is written per CompositeStreamException, in line
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactions…teStreamException Motivation: RFC 9113, Section 5.4 states that implementations SHOULD report at most one stream and one connection error as a result of processing a single condition, even if multiple errors are discovered. When DefaultHttp2LocalFlowController accumulates per-stream failures (e.g. while applying a new SETTINGS initial window size) into a single CompositeStreamException, Http2ConnectionHandler.onError iterated all contained StreamExceptions and wrote an RST_STREAM for each one, exceeding the recommended limit of one stream error per result. Modifications: - Http2ConnectionHandler.onError only reports the first StreamException contained in a CompositeStreamException instead of iterating and reporting every one of them. - Add unit tests Result: Only one RST_STREAM is written per CompositeStreamException, in line with the RFC 9113 recommendation.
Member
Author
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
violetagg
approved these changes
Uh oh!
There was an error while loading. Please reload this page. Uh oh!
There was an error while loading. Please reload this page.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think for the more general case we have de-dup logic below in the Unfortunately it suffers from being to fast and streams are removed from the connection before the next reset occurs.
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactions…eamException Motivation: Bryce Anderson pointed out on PR #17470 that the previous commit's change to only report the first StreamException contained in a CompositeStreamException is incorrect for the actual production code path: DefaultHttp2LocalFlowController's WindowUpdateVisitor builds a CompositeStreamException while applying a new SETTINGS_INITIAL_WINDOW_SIZE across all active streams, adding at most one StreamException per distinct, independently affected stream. If only the first were reported, the remaining affected streams would be left open with a corrupted flow-control window instead of being reset. The RFC 9113, Section 5.4 guidance to report at most one stream error is about not sending multiple redundant reports for the same underlying violation; it does not apply across genuinely independent errors on different streams. That guidance is already satisfied here since each stream contributes at most one exception to the composite. The quote attributed to the RFC in the previous commit's comment was also not an accurate quotation of the spec text. Modifications: - Revert Http2ConnectionHandler.onError to reset every stream contained in a CompositeStreamException, restoring the pre-#17470 behavior, and document why that is correct. - Update the accompanying test to assert that every affected stream is reset. Result: Each independently affected stream is still correctly reset when a CompositeStreamException is thrown from flow-control window processing. …positeStreamException Motivation: Every StreamException currently contained in a CompositeStreamException belongs to a distinct stream, so resetting each one individually is correct. However, nothing enforced RFC 9113, Section 5.4's guidance to report at most one stream error per stream if a composite were ever to contain more than one StreamException for the same stream id. Modifications: - Track which stream ids have already been handled while iterating a CompositeStreamException in Http2ConnectionHandler.onError, and skip any subsequent StreamException for a stream id that was already reported. - Add a test that verifies only the first StreamException for a given stream id results in a RST_STREAM. Result: At most one stream error is reported per stream id contained in a CompositeStreamException.
|
There was an error while loading. Please reload this page.
🚨 TestLens detected 2 failed tests 🚨Here is what you can do:
Test SummaryBuild PR / linux-x86_64-java26 build > Netty/Codec/HTTP2
Build PR / macos-x86_64-java11-boringssl build > Netty/Transport/Native/KQueue
🏷️ Commit: d20aacc Test FailuresHttp2MultiplexTransportTest (Netty/Codec/HTTP2 in Build PR / linux-x86_64-java26 build)KQueueDatagramUnicastIPv6MappedTest > testSimpleSendWithConnect(TestInfo) (Netty/Transport/Native/KQueue in Build PR / macos-x86_64-java11-boringssl build)Rerun ControlsSelect tests to mute in this pull request:
Reuse successful test results:
Click the checkbox to trigger a rerun:
Learn more about TestLens at testlens.app/docs. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
|
Auto-port PR for 4.1: #17595 |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Auto-port PR for 5.0: #17596 |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
…r for a CompositeStreamException (#17596) Auto-port of #17470 to 5.0 Cherry-picked commit: 9676719 --- Motivation: RFC 9113, Section 5.4 states that implementations SHOULD report at most one stream and one connection error as a result of processing a single condition, even if multiple errors are discovered. When DefaultHttp2LocalFlowController accumulates per-stream failures (e.g. while applying a new SETTINGS initial window size) into a single CompositeStreamException, Http2ConnectionHandler.onError iterated all contained StreamExceptions and wrote an RST_STREAM for each one, exceeding the recommended limit of one stream error per result. Modifications: - Http2ConnectionHandler.onError only reports the first StreamException contained in a CompositeStreamException instead of iterating and reporting every one of them. - Add unit tests Result: Only one RST_STREAM is written per CompositeStreamException, in line with the RFC 9113 recommendation. --------- Co-authored-by: Norman Maurer <[email protected]>
…r for a CompositeStreamException (#17595) Auto-port of #17470 to 4.1 Cherry-picked commit: 9676719 --- Motivation: RFC 9113, Section 5.4 states that implementations SHOULD report at most one stream and one connection error as a result of processing a single condition, even if multiple errors are discovered. When DefaultHttp2LocalFlowController accumulates per-stream failures (e.g. while applying a new SETTINGS initial window size) into a single CompositeStreamException, Http2ConnectionHandler.onError iterated all contained StreamExceptions and wrote an RST_STREAM for each one, exceeding the recommended limit of one stream error per result. Modifications: - Http2ConnectionHandler.onError only reports the first StreamException contained in a CompositeStreamException instead of iterating and reporting every one of them. - Add unit tests Result: Only one RST_STREAM is written per CompositeStreamException, in line with the RFC 9113 recommendation. Co-authored-by: Norman Maurer <[email protected]>
…r for a CompositeStreamException (netty#17595) Auto-port of netty#17470 to 4.1 Cherry-picked commit: 9676719 --- Motivation: RFC 9113, Section 5.4 states that implementations SHOULD report at most one stream and one connection error as a result of processing a single condition, even if multiple errors are discovered. When DefaultHttp2LocalFlowController accumulates per-stream failures (e.g. while applying a new SETTINGS initial window size) into a single CompositeStreamException, Http2ConnectionHandler.onError iterated all contained StreamExceptions and wrote an RST_STREAM for each one, exceeding the recommended limit of one stream error per result. Modifications: - Http2ConnectionHandler.onError only reports the first StreamException contained in a CompositeStreamException instead of iterating and reporting every one of them. - Add unit tests Result: Only one RST_STREAM is written per CompositeStreamException, in line with the RFC 9113 recommendation. Co-authored-by: Norman Maurer <[email protected]>
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.