Uh oh!
There was an error while loading. Please reload this page.
http2: do no throw in writeHead if state.closed - #27682
Conversation
nodejs-github-bot
commented
May 13, 2019
Uh oh!
There was an error while loading. Please reload this page.
BridgeAR
left a comment
There was a problem hiding this comment.
The code change is LGTM. Should we not change the behavior in http to throw an error as well instead? Writing while already closed seems wrong?
mcollina
commented
May 14, 2019
That would break a significant number of applications unfortunately. Most applications and frameworks relies on the fact that calling |
The http1 implementation does not throw if the connection is down. The http2 compat implementation should do the same. See: fastify/fastify-http-proxy#51. See: fastify/fastify#1494.
003cef5 to
04c715fComparemcollina
commented
May 17, 2019
1 similar comment
nodejs-github-bot
commented
May 17, 2019
nodejs-github-bot
commented
May 17, 2019
nodejs-github-bot
commented
May 17, 2019
mcollina
commented
May 18, 2019
Landed in a49ab0f |
The http1 implementation does not throw if the connection is down. The http2 compat implementation should do the same. See: fastify/fastify-http-proxy#51. See: fastify/fastify#1494. PR-URL: #27682 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com>
The http1 implementation does not throw if the connection is down. The http2 compat implementation should do the same. See: fastify/fastify-http-proxy#51. See: fastify/fastify#1494. PR-URL: #27682 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com>
I think it's still not completely fixed, getting the issue a bit later here: It does not throw when using http1, but does when using http2 compat implemenation |
mcollina
commented
Nov 15, 2019
@mokimo would you mind opening a new issue with instructions on how to reproduce? (ideally a server + client that calls it). |
If I can get a simple example running that'd be perfect... Been unsuccessful so far but will give you a quick ping you once I got something hands-on |
The http1 implementation does not throw if the connection is down.
The http2 compat implementation should do the same.
See: fastify/fastify-http-proxy#51.
Checklist
make -j4 test(UNIX), orvcbuild test(Windows) passes