<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/node-new.git/test/parallel/test-http-parser.js, branch devsnek-patch-1</title>
<subtitle>github.com: nodejs/node.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/'/>
<entry>
<title>async_hooks: fixup do not reuse HTTPParser</title>
<updated>2019-05-03T14:02:55+00:00</updated>
<author>
<name>Gerhard Stoebich</name>
<email>18708370+Flarna@users.noreply.github.com</email>
</author>
<published>2019-04-22T22:57:12+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=8876ac5c358114f0f88424f6737ca4b89fc9e6c7'/>
<id>8876ac5c358114f0f88424f6737ca4b89fc9e6c7</id>
<content type='text'>
Fix some issues introduced/not fixed via
https://github.com/nodejs/node/pull/25094:
* Init hook is not emitted for a reused HTTPParser
* HTTPParser was still used as resource in init hook
* type used in init hook was always HTTPINCOMINGMESSAGE even for client
requests
* some tests have not been adapted to new resource names

With this change the async hooks init event is emitted during a call
to Initialize() as the type and resource object is available at this
time. As a result Initialize() must be called now which could be seen
as breaking change even HTTPParser is not part of documented API.

It was needed to put the ClientRequest instance into a wrapper object
instead passing it directly as async resource otherwise
test-domain-multi fails. I think this is because adding an EventEmitter
to a Domain adds a property 'domain' and the presence of this changes
the context propagation in domains.

Besides that tests still refering to resource HTTPParser have been
updated/improved.

Fixes: https://github.com/nodejs/node/issues/27467
Fixes: https://github.com/nodejs/node/issues/26961
Refs: https://github.com/nodejs/node/pull/25094

PR-URL: https://github.com/nodejs/node/pull/27477
Reviewed-By: Anna Henningsen &lt;anna@addaleax.net&gt;
Reviewed-By: Matteo Collina &lt;matteo.collina@gmail.com&gt;
Reviewed-By: Rich Trott &lt;rtrott@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix some issues introduced/not fixed via
https://github.com/nodejs/node/pull/25094:
* Init hook is not emitted for a reused HTTPParser
* HTTPParser was still used as resource in init hook
* type used in init hook was always HTTPINCOMINGMESSAGE even for client
requests
* some tests have not been adapted to new resource names

With this change the async hooks init event is emitted during a call
to Initialize() as the type and resource object is available at this
time. As a result Initialize() must be called now which could be seen
as breaking change even HTTPParser is not part of documented API.

It was needed to put the ClientRequest instance into a wrapper object
instead passing it directly as async resource otherwise
test-domain-multi fails. I think this is because adding an EventEmitter
to a Domain adds a property 'domain' and the presence of this changes
the context propagation in domains.

Besides that tests still refering to resource HTTPParser have been
updated/improved.

Fixes: https://github.com/nodejs/node/issues/27467
Fixes: https://github.com/nodejs/node/issues/26961
Refs: https://github.com/nodejs/node/pull/25094

PR-URL: https://github.com/nodejs/node/pull/27477
Reviewed-By: Anna Henningsen &lt;anna@addaleax.net&gt;
Reviewed-By: Matteo Collina &lt;matteo.collina@gmail.com&gt;
Reviewed-By: Rich Trott &lt;rtrott@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>src: do not reuse async resource in http parsers</title>
<updated>2019-04-22T18:51:46+00:00</updated>
<author>
<name>Daniel Beckert</name>
<email>drbeckert@gmail.com</email>
</author>
<published>2018-12-13T17:35:48+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=ece507394a563bd7e3555a840a3d6980ffbb01ac'/>
<id>ece507394a563bd7e3555a840a3d6980ffbb01ac</id>
<content type='text'>
Change resource being used, previously HTTParser was being reused.
We are now using IncomingMessage and ClientRequest objects.  The goal
here is to make the async resource unique for each async operatio

Refs: https://github.com/nodejs/node/pull/24330
Refs: https://github.com/nodejs/diagnostics/issues/248
Refs: https://github.com/nodejs/node/pull/21313

Co-authored-by: Matheus Marchini &lt;mat@mmarchini.me&gt;

PR-URL: https://github.com/nodejs/node/pull/25094
Reviewed-By: Matteo Collina &lt;matteo.collina@gmail.com&gt;
Reviewed-By: Benedikt Meurer &lt;benedikt.meurer@gmail.com&gt;
Reviewed-By: Anna Henningsen &lt;anna@addaleax.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Change resource being used, previously HTTParser was being reused.
We are now using IncomingMessage and ClientRequest objects.  The goal
here is to make the async resource unique for each async operatio

Refs: https://github.com/nodejs/node/pull/24330
Refs: https://github.com/nodejs/diagnostics/issues/248
Refs: https://github.com/nodejs/node/pull/21313

Co-authored-by: Matheus Marchini &lt;mat@mmarchini.me&gt;

PR-URL: https://github.com/nodejs/node/pull/25094
Reviewed-By: Matteo Collina &lt;matteo.collina@gmail.com&gt;
Reviewed-By: Benedikt Meurer &lt;benedikt.meurer@gmail.com&gt;
Reviewed-By: Anna Henningsen &lt;anna@addaleax.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>benchmark,doc,lib,test: capitalize comments</title>
<updated>2019-03-09T23:44:40+00:00</updated>
<author>
<name>Ruben Bridgewater</name>
<email>ruben@bridgewater.de</email>
</author>
<published>2019-03-07T00:03:53+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=f8763bb077db2f0be74e353c0b4f9e353c0fffa8'/>
<id>f8763bb077db2f0be74e353c0b4f9e353c0fffa8</id>
<content type='text'>
PR-URL: https://github.com/nodejs/node/pull/26483
Reviewed-By: Vse Mozhet Byt &lt;vsemozhetbyt@gmail.com&gt;
Reviewed-By: Michaël Zasso &lt;targos@protonmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
PR-URL: https://github.com/nodejs/node/pull/26483
Reviewed-By: Vse Mozhet Byt &lt;vsemozhetbyt@gmail.com&gt;
Reviewed-By: Michaël Zasso &lt;targos@protonmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>http: make parser choice a runtime flag</title>
<updated>2018-12-06T04:21:36+00:00</updated>
<author>
<name>Anna Henningsen</name>
<email>anna@addaleax.net</email>
</author>
<published>2018-11-30T06:39:02+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=aa943d098e0299ea87485a607353d152f5ea5012'/>
<id>aa943d098e0299ea87485a607353d152f5ea5012</id>
<content type='text'>
Add a `--http-parser=llhttp` vs `--http-parser=traditional`
command line switch, to make testing and comparing the new
llhttp-based implementation easier.

PR-URL: https://github.com/nodejs/node/pull/24739
Refs: https://github.com/nodejs/node/issues/24730
Reviewed-By: Joyee Cheung &lt;joyeec9h3@gmail.com&gt;
Reviewed-By: Colin Ihrig &lt;cjihrig@gmail.com&gt;
Reviewed-By: Fedor Indutny &lt;fedor.indutny@gmail.com&gt;
Reviewed-By: Gus Caplan &lt;me@gus.host&gt;
Reviewed-By: Matheus Marchini &lt;mat@mmarchini.me&gt;
Reviewed-By: Matteo Collina &lt;matteo.collina@gmail.com&gt;
Reviewed-By: Ali Ijaz Sheikh &lt;ofrobots@google.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add a `--http-parser=llhttp` vs `--http-parser=traditional`
command line switch, to make testing and comparing the new
llhttp-based implementation easier.

PR-URL: https://github.com/nodejs/node/pull/24739
Refs: https://github.com/nodejs/node/issues/24730
Reviewed-By: Joyee Cheung &lt;joyeec9h3@gmail.com&gt;
Reviewed-By: Colin Ihrig &lt;cjihrig@gmail.com&gt;
Reviewed-By: Fedor Indutny &lt;fedor.indutny@gmail.com&gt;
Reviewed-By: Gus Caplan &lt;me@gus.host&gt;
Reviewed-By: Matheus Marchini &lt;mat@mmarchini.me&gt;
Reviewed-By: Matteo Collina &lt;matteo.collina@gmail.com&gt;
Reviewed-By: Ali Ijaz Sheikh &lt;ofrobots@google.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>async_hooks: add missing async_hooks destroys in AsyncReset</title>
<updated>2018-10-10T06:45:56+00:00</updated>
<author>
<name>Bastian Krol</name>
<email>bastian.krol@instana.com</email>
</author>
<published>2018-10-01T15:11:25+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=eb9748d222061381236f19cbe162cf9eb2e034ad'/>
<id>eb9748d222061381236f19cbe162cf9eb2e034ad</id>
<content type='text'>
This adds missing async_hooks destroy calls for sockets (in
_http_agent.js) and HTTP parsers. We need to emit a destroy in
AsyncWrap#AsyncReset before assigning a new async_id when the instance
has already been in use and is being recycled, because in that case, we
have already emitted an init for the "old" async_id.

This also removes a duplicated init call for HTTP parser: Each time a
new parser was created, AsyncReset was being called via the C++ Parser
class constructor (super constructor AsyncWrap) and also via
Parser::Reinitialize.

PR-URL: https://github.com/nodejs/node/pull/23272
Fixes: https://github.com/nodejs/node/issues/19859
Reviewed-By: Matteo Collina &lt;matteo.collina@gmail.com&gt;
Reviewed-By: Anna Henningsen &lt;anna@addaleax.net&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This adds missing async_hooks destroy calls for sockets (in
_http_agent.js) and HTTP parsers. We need to emit a destroy in
AsyncWrap#AsyncReset before assigning a new async_id when the instance
has already been in use and is being recycled, because in that case, we
have already emitted an init for the "old" async_id.

This also removes a duplicated init call for HTTP parser: Each time a
new parser was created, AsyncReset was being called via the C++ Parser
class constructor (super constructor AsyncWrap) and also via
Parser::Reinitialize.

PR-URL: https://github.com/nodejs/node/pull/23272
Fixes: https://github.com/nodejs/node/issues/19859
Reviewed-By: Matteo Collina &lt;matteo.collina@gmail.com&gt;
Reviewed-By: Anna Henningsen &lt;anna@addaleax.net&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>http: move process.binding('http_parser') to internalBinding</title>
<updated>2018-08-18T20:01:21+00:00</updated>
<author>
<name>James M Snell</name>
<email>jasnell@gmail.com</email>
</author>
<published>2018-08-15T00:01:06+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=1744205ff565b490f8db72000028b074cce23d5d'/>
<id>1744205ff565b490f8db72000028b074cce23d5d</id>
<content type='text'>
Refs: https://github.com/nodejs/node/issues/22160

PR-URL: https://github.com/nodejs/node/pull/22329
Reviewed-By: Gus Caplan &lt;me@gus.host&gt;
Reviewed-By: Trivikram Kamat &lt;trivikr.dev@gmail.com&gt;
Reviewed-By: Jon Moss &lt;me@jonathanmoss.me&gt;
Reviewed-By: Ruben Bridgewater &lt;ruben@bridgewater.de&gt;
Reviewed-By: Joyee Cheung &lt;joyeec9h3@gmail.com&gt;
Reviewed-By: Anna Henningsen &lt;anna@addaleax.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Refs: https://github.com/nodejs/node/issues/22160

PR-URL: https://github.com/nodejs/node/pull/22329
Reviewed-By: Gus Caplan &lt;me@gus.host&gt;
Reviewed-By: Trivikram Kamat &lt;trivikr.dev@gmail.com&gt;
Reviewed-By: Jon Moss &lt;me@jonathanmoss.me&gt;
Reviewed-By: Ruben Bridgewater &lt;ruben@bridgewater.de&gt;
Reviewed-By: Joyee Cheung &lt;joyeec9h3@gmail.com&gt;
Reviewed-By: Anna Henningsen &lt;anna@addaleax.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>test: fix assert.throws error in test-http-parser</title>
<updated>2018-03-29T04:28:35+00:00</updated>
<author>
<name>Rich Trott</name>
<email>rtrott@gmail.com</email>
</author>
<published>2018-03-27T04:19:01+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=42d1d72a2e8a0ca1ffac98a4fe761e6c42b54c3b'/>
<id>42d1d72a2e8a0ca1ffac98a4fe761e6c42b54c3b</id>
<content type='text'>
The third argument of `assert.throws()` is a message that is used by the
AssertionError, not the message to check in the thrown error. It appears
that there is an assert.throws() in test-http-parser that expects the
latter behavior. Rewrite the call to check the error message. Even if
this wasn't a mistake, this change results in a more robust check.

PR-URL: https://github.com/nodejs/node/pull/19626
Reviewed-By: Daniel Bevenius &lt;daniel.bevenius@gmail.com&gt;
Reviewed-By: Richard Lau &lt;riclau@uk.ibm.com&gt;
Reviewed-By: Colin Ihrig &lt;cjihrig@gmail.com&gt;
Reviewed-By: Luigi Pinca &lt;luigipinca@gmail.com&gt;
Reviewed-By: Trivikram Kamat &lt;trivikr.dev@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The third argument of `assert.throws()` is a message that is used by the
AssertionError, not the message to check in the thrown error. It appears
that there is an assert.throws() in test-http-parser that expects the
latter behavior. Rewrite the call to check the error message. Even if
this wasn't a mistake, this change results in a more robust check.

PR-URL: https://github.com/nodejs/node/pull/19626
Reviewed-By: Daniel Bevenius &lt;daniel.bevenius@gmail.com&gt;
Reviewed-By: Richard Lau &lt;riclau@uk.ibm.com&gt;
Reviewed-By: Colin Ihrig &lt;cjihrig@gmail.com&gt;
Reviewed-By: Luigi Pinca &lt;luigipinca@gmail.com&gt;
Reviewed-By: Trivikram Kamat &lt;trivikr.dev@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>test: refactor test-http-parser</title>
<updated>2018-01-19T11:58:31+00:00</updated>
<author>
<name>Jon Moss</name>
<email>me@jonathanmoss.me</email>
</author>
<published>2018-01-18T01:36:25+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=5e17f54d79a345cc66a2105201f25f38d6b8d9e3'/>
<id>5e17f54d79a345cc66a2105201f25f38d6b8d9e3</id>
<content type='text'>
Use common's mustCall (for some reason was implementing its own?), and
other small fixes.

PR-URL: https://github.com/nodejs/node/pull/18219
Reviewed-By: Colin Ihrig &lt;cjihrig@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
Reviewed-By: Luigi Pinca &lt;luigipinca@gmail.com&gt;
Reviewed-By: Anna Henningsen &lt;anna@addaleax.net&gt;
Reviewed-By: Ruben Bridgewater &lt;ruben@bridgewater.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use common's mustCall (for some reason was implementing its own?), and
other small fixes.

PR-URL: https://github.com/nodejs/node/pull/18219
Reviewed-By: Colin Ihrig &lt;cjihrig@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
Reviewed-By: Luigi Pinca &lt;luigipinca@gmail.com&gt;
Reviewed-By: Anna Henningsen &lt;anna@addaleax.net&gt;
Reviewed-By: Ruben Bridgewater &lt;ruben@bridgewater.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>test: remove unused arguments from function</title>
<updated>2017-08-23T09:24:51+00:00</updated>
<author>
<name>Ankit Parashar</name>
<email>ankitabc12@gmail.com</email>
</author>
<published>2017-08-18T09:10:53+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=2a97eb61c65e23de3cee42c7b70f845b0c3a3d09'/>
<id>2a97eb61c65e23de3cee42c7b70f845b0c3a3d09</id>
<content type='text'>
Removed the unused arguments of functions defined in
file test/parallel/test-http-parser.js.

PR-URL: https://github.com/nodejs/node/pull/14931
Reviewed-By: Rich Trott &lt;rtrott@gmail.com&gt;
Reviewed-By: Yuta Hiroto &lt;hello@about-hiroppy.com&gt;
Reviewed-By: Refael Ackermann &lt;refack@gmail.com&gt;
Reviewed-By: Luigi Pinca &lt;luigipinca@gmail.com&gt;
Reviewed-By: Colin Ihrig &lt;cjihrig@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
Reviewed-By: Alexey Orlenko &lt;eaglexrlnk@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Removed the unused arguments of functions defined in
file test/parallel/test-http-parser.js.

PR-URL: https://github.com/nodejs/node/pull/14931
Reviewed-By: Rich Trott &lt;rtrott@gmail.com&gt;
Reviewed-By: Yuta Hiroto &lt;hello@about-hiroppy.com&gt;
Reviewed-By: Refael Ackermann &lt;refack@gmail.com&gt;
Reviewed-By: Luigi Pinca &lt;luigipinca@gmail.com&gt;
Reviewed-By: Colin Ihrig &lt;cjihrig@gmail.com&gt;
Reviewed-By: James M Snell &lt;jasnell@gmail.com&gt;
Reviewed-By: Alexey Orlenko &lt;eaglexrlnk@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>test: refactor test-http-parser.js</title>
<updated>2017-07-27T16:22:28+00:00</updated>
<author>
<name>Rich Trott</name>
<email>rtrott@gmail.com</email>
</author>
<published>2017-07-25T17:34:52+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node-new.git/commit/?id=4f0b10733483fbb62776b7973200e5fbb56349a9'/>
<id>4f0b10733483fbb62776b7973200e5fbb56349a9</id>
<content type='text'>
* eliminate CRLF identifier, reducing string concatenation
* adjust indentation for stricter ESLint 4.x indentation linting

PR-URL: https://github.com/nodejs/node/pull/14431
Reviewed-By: Refael Ackermann &lt;refack@gmail.com&gt;
Reviewed-By: Vse Mozhet Byt &lt;vsemozhetbyt@gmail.com&gt;
Reviewed-By: Trevor Norris &lt;trev.norris@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* eliminate CRLF identifier, reducing string concatenation
* adjust indentation for stricter ESLint 4.x indentation linting

PR-URL: https://github.com/nodejs/node/pull/14431
Reviewed-By: Refael Ackermann &lt;refack@gmail.com&gt;
Reviewed-By: Vse Mozhet Byt &lt;vsemozhetbyt@gmail.com&gt;
Reviewed-By: Trevor Norris &lt;trev.norris@gmail.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
