-
Notifications
You must be signed in to change notification settings - Fork 29.8k
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
http2: fix session memory tracking and small clean up #30351
Closed
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
nodejs-github-bot
added
c++
Issues and PRs that require attention from people who are familiar with C++.
http2
Issues or PRs related to the http2 subsystem.
labels
Nov 10, 2019
lundibundi
changed the title
http2: fix read memory track and small clean up
http2: fix session memory tracking and small clean up
Nov 10, 2019
addaleax
approved these changes
Nov 10, 2019
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 guess if you want to write a test for this, you could build something based on test-http2-generic-streams.js
that triggers this condition and takes a heap dump?
devnexen
approved these changes
Nov 10, 2019
jasnell
approved these changes
Nov 12, 2019
lundibundi
added
the
author ready
PRs that have at least one approval, no pending requests for changes, and a CI started.
label
Nov 17, 2019
3 tasks
lundibundi
added
blocked
PRs that are blocked by other issues or PRs.
and removed
author ready
PRs that have at least one approval, no pending requests for changes, and a CI started.
labels
Nov 27, 2019
Waiting for this #30684 to land. I'll then rebase and update this. |
* avoid consecutive decrement/increment session memory calls. * only Resize the buffer when it is needed. * flip `stream_buf_offset_` condition to the LIKELY case.
lundibundi
force-pushed
the
fix-http2-read-memory-track
branch
from
December 1, 2019 18:39
d004aaf
to
542924e
Compare
addaleax
approved these changes
Dec 5, 2019
addaleax
added
the
author ready
PRs that have at least one approval, no pending requests for changes, and a CI started.
label
Dec 5, 2019
jasnell
approved these changes
Dec 5, 2019
addaleax
pushed a commit
that referenced
this pull request
Dec 6, 2019
PR-URL: #30351 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: David Carlier <devnexen@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
addaleax
pushed a commit
that referenced
this pull request
Dec 6, 2019
* avoid consecutive decrement/increment session memory calls. * only Resize the buffer when it is needed. * flip `stream_buf_offset_` condition to the LIKELY case. PR-URL: #30351 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: David Carlier <devnexen@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Landed in bfd9de6...51ccf1b |
targos
pushed a commit
that referenced
this pull request
Dec 9, 2019
PR-URL: #30351 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: David Carlier <devnexen@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
targos
pushed a commit
that referenced
this pull request
Dec 9, 2019
* avoid consecutive decrement/increment session memory calls. * only Resize the buffer when it is needed. * flip `stream_buf_offset_` condition to the LIKELY case. PR-URL: #30351 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: David Carlier <devnexen@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Merged
targos
pushed a commit
that referenced
this pull request
Jan 13, 2020
PR-URL: #30351 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: David Carlier <devnexen@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
targos
pushed a commit
that referenced
this pull request
Jan 13, 2020
* avoid consecutive decrement/increment session memory calls. * only Resize the buffer when it is needed. * flip `stream_buf_offset_` condition to the LIKELY case. PR-URL: #30351 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: David Carlier <devnexen@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
BethGriggs
pushed a commit
that referenced
this pull request
Feb 6, 2020
PR-URL: #30351 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: David Carlier <devnexen@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
BethGriggs
pushed a commit
that referenced
this pull request
Feb 6, 2020
* avoid consecutive decrement/increment session memory calls. * only Resize the buffer when it is needed. * flip `stream_buf_offset_` condition to the LIKELY case. PR-URL: #30351 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: David Carlier <devnexen@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Merged
lundibundi
added a commit
to lundibundi/node
that referenced
this pull request
Jul 22, 2020
4 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
author ready
PRs that have at least one approval, no pending requests for changes, and a CI started.
c++
Issues and PRs that require attention from people who are familiar with C++.
http2
Issues or PRs related to the http2 subsystem.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passeshttp2: fix session memory tracking with pending input data
Previously
DecrementCurrentSessionMemory
call was made after the relevant variable was reset to0
.http2: small clean up in OnStreamRead
Extract pending input memory size in a variable and change code appropriately.
Not sure how to reliably hit the changed case, could someone help so I can write a test for
DecrementCurrentSessionMemory
?