-
Notifications
You must be signed in to change notification settings - Fork 105
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Handle HTTP/2 half-closed connections gracefully. #777
base: master
Are you sure you want to change the base?
Handle HTTP/2 half-closed connections gracefully. #777
Conversation
hyperframe.frame.WindowUpdateFrame( | ||
stream_id=0, window_increment=2147418112 | ||
).serialize() | ||
+ hyperframe.frame.WindowUpdateFrame( | ||
stream_id=1, window_increment=2147418112 | ||
).serialize() | ||
+ hyperframe.frame.HeadersFrame( | ||
stream_id=1, | ||
data=hpack.Encoder().encode( | ||
[ | ||
(b":status", b"413"), | ||
(b"content-type", b"plain/text"), | ||
] | ||
), | ||
flags=["END_HEADERS"], | ||
).serialize() | ||
+ hyperframe.frame.DataFrame( | ||
stream_id=1, | ||
data=b"Request body exceeded 1,000,000 bytes", | ||
flags=["END_STREAM"], | ||
).serialize() | ||
+ hyperframe.frame.RstStreamFrame(stream_id=1, error_code=0).serialize(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Interesting. Is it intentional/neccessary-for-the-test that the data for these frames is concatenated?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I ran into some issues without frame concatenation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Without cancatenation, the client has enough time to send the entire request and receives 413 with no stream errors.
Closes #775
TODO: