Skip to content

Conversation

@edevil
Copy link
Contributor

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines

Addresses koajs/koa#1229 and #22135.

There is a race condition between onStreamCloseResponse(), which removes the wantTrailers listener, and Http2Stream.close(), which will invalidate the connection. IE, sendTrailers can be called on a closed connection which would crash with a: Error [ERR_HTTP2_INVALID_STREAM]: The stream has been destroyed
@nodejs-github-botnodejs-github-bot added dont-land-on-v6.x http2 Issues or PRs related to the http2 subsystem. labels Sep 28, 2018
@trivikr
Copy link
Member

@edevil
Copy link
ContributorAuthor

@trivikr I’m not familiar with node’s CI. Are those failures flakes, or can they be related to this PR? Thanks.

@trivikr
Copy link
Member

trivikr commented Sep 30, 2018

Resumed CI: https://ci.nodejs.org/job/node-test-pull-request/17512/ (:heavy_check_mark:)

@addaleaxaddaleax added the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Sep 30, 2018
@danbev
Copy link
Contributor

Landed in 1bfd035.

@danbevdanbev closed this Oct 3, 2018
danbev pushed a commit that referenced this pull request Oct 3, 2018
There is a race condition between onStreamCloseResponse(), which removes the wantTrailers listener, and Http2Stream.close(), which will invalidate the connection. IE, sendTrailers can be called on a closed connection which would crash with a: Error [ERR_HTTP2_INVALID_STREAM]: The stream has been destroyed PR-URL: #23146 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]>
targos pushed a commit that referenced this pull request Oct 4, 2018
There is a race condition between onStreamCloseResponse(), which removes the wantTrailers listener, and Http2Stream.close(), which will invalidate the connection. IE, sendTrailers can be called on a closed connection which would crash with a: Error [ERR_HTTP2_INVALID_STREAM]: The stream has been destroyed PR-URL: #23146 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]>
@damianobarbati
Copy link

@danbev is there an expected release date for v10.11.1 (or v10.12.0) shipping this fix?

@targostargos mentioned this pull request Oct 7, 2018
jasnell pushed a commit that referenced this pull request Oct 17, 2018
There is a race condition between onStreamCloseResponse(), which removes the wantTrailers listener, and Http2Stream.close(), which will invalidate the connection. IE, sendTrailers can be called on a closed connection which would crash with a: Error [ERR_HTTP2_INVALID_STREAM]: The stream has been destroyed PR-URL: #23146 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]>
@addaleaxaddaleax mentioned this pull request Oct 20, 2018
2 tasks
@StephenLynx
Copy link

I'm getting this issue sometimes when trying to write headers using http2. Node 10.13 on CentOS 7.

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author readyPRs that have at least one approval, no pending requests for changes, and a CI started.http2Issues or PRs related to the http2 subsystem.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants

@edevil@trivikr@danbev@damianobarbati@StephenLynx@jasnell@addaleax@nodejs-github-bot