http2: emit error on canceled streams when aborted event is not emitted#62923
Open
mcollina wants to merge 1 commit intonodejs:mainfrom
Open
http2: emit error on canceled streams when aborted event is not emitted#62923mcollina wants to merge 1 commit intonodejs:mainfrom
mcollina wants to merge 1 commit intonodejs:mainfrom
Conversation
Collaborator
|
Review requested:
|
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #62923 +/- ##
==========================================
- Coverage 89.69% 89.66% -0.04%
==========================================
Files 706 706
Lines 218222 219419 +1197
Branches 41768 42077 +309
==========================================
+ Hits 195731 196735 +1004
- Misses 14411 14602 +191
- Partials 8080 8082 +2
🚀 New features to boost your workflow:
|
31d3521 to
abff173
Compare
When a client HTTP/2 stream's writable side is already ended (e.g. GET requests), receiving RST code 8 (NGHTTP2_CANCEL) emitted neither the 'aborted' nor the 'error' event, causing the stream to close silently. This happened because the 'aborted' event is only emitted when the writable side is still open, but the NGHTTP2_CANCEL code was unconditionally excluded from error generation assuming the 'aborted' event would cover it. Fix by only skipping error generation for NGHTTP2_CANCEL when the 'aborted' event was actually emitted. Fixes: nodejs#56627
abff173 to
f3dd59d
Compare
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.
When a client HTTP/2 stream's writable side is already ended (e.g. GET requests), receiving RST code 8 (
NGHTTP2_CANCEL) emitted neither theabortednor theerrorevent, causing the stream to close silently.The fix only skips error generation for
NGHTTP2_CANCELwhen theabortedevent was actually emitted.Fixes: #56627