Skip to content
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

Sending RST_STREAM on closed Streams results in GOAWAY #119

Closed
bengreenberg opened this issue Feb 11, 2018 · 1 comment · Fixed by #120
Closed

Sending RST_STREAM on closed Streams results in GOAWAY #119

bengreenberg opened this issue Feb 11, 2018 · 1 comment · Fixed by #120

Comments

@bengreenberg
Copy link
Contributor

I'm seeing a race condition on pushes of small amounts of data that are canceled by the client. If the push data is small enough and transferred quickly enough, the server may receive a client's RST_STREAM frame after the pushed stream has already been closed. In this case, the http-2 server cannot find the stream id in the @streams hash, so it treats it as as unexpected stream identifier and sends GOAWAY with frame 0, killing the connection. Since the closed push stream is actually valid, I believe this is not correct and the RST_STEAM can be silently ignored in this case.

I have a fix for this that will not throw the error if the stream is in the @streams_recently_closed hash.

@bengreenberg
Copy link
Contributor Author

Looking into this more, I believe this was introduced with #88 . I don't think the intent of that patch was the delete closed immediately. My fix only deletes the stream if its been closed for 15 seconds or longer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant