-
Notifications
You must be signed in to change notification settings - Fork 30k
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
https: defines maxHeadersCount in the constructor #20359
Conversation
@nodejs/http @nodejs/http2 PTAL |
|
||
process.on('exit', () => { | ||
assert.strictEqual(requests, maxAndExpected.length); | ||
assert.strictEqual(responses, maxAndExpected.length); |
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 should not be needed if you use common.mustCall()
.
let max = maxAndExpected[requests][0]; | ||
let expected = maxAndExpected[requests][1]; | ||
|
||
const server = https.createServer(serverOptions, (req, res) => { |
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.
the callback should be wrapped in common.mustCall()
.
]; | ||
doRequest(); | ||
|
||
function doRequest() { |
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 function should be wrapped in common.mustCall()
, with the total number of time it needs to be called.
In Refs, http.Server's maxHeadersCount field was defined in the constructor to make hidden class stable and so on. Also in https.Server, we can use maxHeadersCount the same as http via connectionListener. So, defines it in the constructor and documentation. Refs: nodejs#9116
990a69a
to
cee0ad3
Compare
@mcollina Thanks for your reviews. PTAL |
In http.ClientRequest's doc, add maxHeadersCount as a public property. And in the description of server's one, change a hyphen to a comma. PR-URL: #20361 Refs: #20359 Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Colin Ihrig <[email protected]>
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
In http.ClientRequest's doc, add maxHeadersCount as a public property. And in the description of server's one, change a hyphen to a comma. PR-URL: #20361 Refs: #20359 Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Colin Ihrig <[email protected]>
Landed in 6779096 |
In Refs, http.Server's maxHeadersCount field was defined in the constructor to make hidden class stable and so on. Also in https.Server, we can use maxHeadersCount the same as http via connectionListener. So, defines it in the constructor and documentation. Refs: #9116 PR-URL: #20359 Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]>
In Refs, http.Server's maxHeadersCount field was defined in the constructor to make hidden class stable and so on. Also in https.Server, we can use maxHeadersCount the same as http via connectionListener. So, defines it in the constructor and documentation. Refs: #9116 PR-URL: #20359 Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]>
In http.ClientRequest's doc, add maxHeadersCount as a public property. And in the description of server's one, change a hyphen to a comma. PR-URL: #20361 Refs: #20359 Reviewed-By: Rich Trott <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Colin Ihrig <[email protected]>
In Refs, http.Server's maxHeadersCount field was defined in the constructor to make hidden class stable and so on. Also in https.Server, we can use maxHeadersCount the same as http via connectionListener. So, defines it in the constructor and documentation. Refs: #9116 PR-URL: #20359 Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]>
In Refs, http.Server's maxHeadersCount field was defined in the constructor to make hidden class stable and so on. Also in https.Server, we can use maxHeadersCount the same as http via connectionListener. So, defines it in the constructor and documentation. Refs: #9116 PR-URL: #20359 Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]>
In Refs, http.Server's maxHeadersCount field was defined in the constructor to make hidden class stable and so on.
Also in https.Server, we can use maxHeadersCount the same as http via connectionListener.
So defines it in the constructor and documentation.
Refs: #9116
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passes