-
Notifications
You must be signed in to change notification settings - Fork 29.7k
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
Initial proposal for additional http2settings #49025
Conversation
Review requested:
|
6b98fbb
to
9b23524
Compare
0b52839
to
2bfb762
Compare
The test now run through. So I think this one is ready for review. |
Are those custom settings passed through the connection/other peer? |
As far as I understand the settings should be sent to the other side of the connection, so for example to the browser. I am currently separated from my development computer until the end of the week, I will then try to fix the problems the automated test showed. |
doc/api/http2.md
Outdated
in node and the underlying libraries. The key of the object define the | ||
numeric ids of the settings and the values the numeric value of the settings. | ||
This property is not supported for remote and local settings. It is only | ||
supported for sending SETTINGS. |
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.
This needs to be explained in greater detail.
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.
This needs to be explained in greater detail.
So more like this:
The key of the object defines the numeric value of the settings type (as defined in the "HTTP/2 SETTINGS" registry established by [RFC7540]) and the values the actual numeric value of the settings.
It is only supported for sending SETTINGS.
Custom setiings are not supported for the functions retrieving remote and local settings as nghttp2 does not pass unknown HTTP/2 settings to node.js.
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.
yes
2bfb762
to
67fc63b
Compare
Ok, I am back at my development machine. |
you can lint with |
Yes, I know, but I checked out node at a commit where it was broken. And I did not find the time to recompile. |
67fc63b
to
f6b824e
Compare
I hopefully have fixed all failures by hand. |
f6b824e
to
f5f92d7
Compare
Hopefully the last correction for CI to work. |
I think you pushed way more commits than you should have, there are a few spurious ones. Can you fix it? |
Oh you are right. The rebasing went wrong...... |
Currently, node.js http/2 is limited in sending SETTINGs, that are currently implemented by nghttp2. However, nghttp2 has the ability to send arbitary SETTINGs, that are not known beforehand. This patch adds this feature including a fall back mechanism, if a SETTING is implemented in a later nghttp2 or node version. Fixes: nodejs#1337
Test for the http2 setting's custom settings were added.
Add an explanation to the documentation for Http2Settings to explain the usage of customSettings and its limitations. Co-authored-by: James M Snell <[email protected]>
a6d13b9
to
2860c65
Compare
Ok, I have now force-pushed the branch, with cherry picking the changing commits. I have now to run tests to check, if liniting is ok. |
Ok, |
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.
LGTM
I have no idea, why some of the jobs fail. One fails with "parallel.test-inspector-break-when-eval", which seems to be unrelated to the changes. The other fails with out of memory. |
Landed in 2c571c6 |
Currently, node.js http/2 is limited in sending SETTINGs, that are currently implemented by nghttp2. However, nghttp2 has the ability to send arbitary SETTINGs, that are not known beforehand. This patch adds this feature including a fall back mechanism, if a SETTING is implemented in a later nghttp2 or node version. Fixes: #1337 PR-URL: #49025 Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Marco Ippolito <[email protected]>
Currently, node.js http/2 is limited in sending SETTINGs, that are currently implemented by nghttp2. However, nghttp2 has the ability to send arbitary SETTINGs, that are not known beforehand. This patch adds this feature including a fall back mechanism, if a SETTING is implemented in a later nghttp2 or node version. Fixes: #1337 PR-URL: #49025 Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Marco Ippolito <[email protected]>
This PR implements the ability to send additional HTTP/2 settings with node.js, which are currently not directly implemented with node and the underlying nghttp2 lib. Receiving these settings is not possible, since nghttp2 actively checls for and passes only settings, that it knows. It is currently limited to 10 additional settings.
The intention of this PR is first to get feedback for the used interfacing before progressing further with the PR.
TODOs:
EDIT: Automated tests are added, and will be run soon.... (tested) EDIT2: Test run as part of node's test, which should suffcient.
Related issue
#48962