http2: GOAWAY NO_ERROR is not an error, just end of connection#2375
http2: GOAWAY NO_ERROR is not an error, just end of connection#2375
Conversation
|
I'm not a fan of the commit title, it reads more like an explanation in a commit message. |
|
I like your suggested commit message fix, I'll change.
Even if this fix isn't a 100% fix for GOAWAY, it still improves the situation since before this PR, libcurl treated the GOAWAY as an error and stopped. Now it "only" marks the connection for close, which is much more likely to be right. I totally agree that it leaves a risk that if we have stream A and B going, and we receive a GOAWAY, we should still allow both streams to terminate before we close the connection and I believe the current setup might now close the connection once the next stream ends instead of allowing all existing streams to end. It would be nice to be able to setup a test that does exactly that... |
|
Hm, actually I think it should be fine. |
No, that's not true either I think. It only returns false if there's data currently in the queues to "drain" for any stream. A complete fix will probably need to check if there's a non-closed stream still present on the connection before it allows it to get closed. It should still be marked for closure immediately on the receive of GOAWAY as it then makes sure the connection is not used further for new streams. |
Assisted-by: Jay Satiro Reported-by: Łukasz Domeradzki Fixes #2365
9f9133f to
ba0897f
Compare
|
We already had the check in |
Reported-by: Łukasz Domeradzki
Fixes #2365