| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
There was a problem hiding this comment.
@indutny Why did you disable this test in your original PR?
Sorry, something went wrong.
There was a problem hiding this comment.
Does it pass now?
If I remember it right it just killed the process with uncaught exception last time (FatalException or whatever).
Sorry, something went wrong.
There was a problem hiding this comment.
Does on my machine. Running CI again to see if it does.
Sorry, something went wrong.
Sorry, something went wrong.
|
There are a lot of failures for test-http-pipeline-flood.js. Though this PR shouldn't affect this PR /cc @indutny |
Sorry, something went wrong.
|
One more time to see if the previous was a fluke |
Sorry, something went wrong.
|
All but one failure was for test-http-pipeline-flood. Most failures had the usual linux-fips: Error: write ECONNRESET freebsd: Error: write EPIPE win10-vcbt2015: FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - process out of memory win2012r2-vs2015: # TIMEOUT @rvagg Maybe you have an idea how to proceed, or maybe something is going on w/ Jenkins? |
Sorry, something went wrong.
|
@indutny confirmed that switching to MakeCallback() causes the flood protection to fail. figuring out why now. |
Sorry, something went wrong.
|
CI: https://ci.nodejs.org/job/node-test-pull-request/1788/ @indutny I've added two AsyncCallbackScopes to prevent the nextTickQueue from being processed. This was causing the state of the parser and socket to be altered, whereas they weren't before. The state change allowed the socket to continually consume new requests. The reason the pipeline flood fix worked before was because the entire packet of requests was essentially processed synchronously. But calling MakeCallback processes the nextTickQueue and changes the state of the http stream. Below are some of the notes I took while investigating: In the case of parserOnMessageComplete(), if AsyncCallbackScope is not The reason socket._paused = false is because socketOnDrain() In the end I believe this fix is the simplest, and keeps the parser operating like it did before. |
Sorry, something went wrong.
|
Ah, yeah. Nice catch! I was going to take a look at it, but you beat me 😉 |
Sorry, something went wrong.
|
LGTM if it works |
Sorry, something went wrong.
Make `HTTPParser` an instance of `AsyncWrap` and make it use `MakeCallback`. This means that async wrap hooks will be called on consumed TCP sockets as well as on non-consumed ones. Additional uses of `AsyncCallbackScope` are necessary to prevent improper state from progressing that triggers failure in the test-http-pipeline-flood.js test. Optimally this wouldn't be necessary, but for the time being it's the most sure way to allow operations to proceed as they have. Fix: nodejs#4416 PR-URL: nodejs#5419 Reviewed-By: Fedor Indutny <fedor@indutny.com>
|
Thanks much. CI is all green. Landed in a7e49c8. |
Sorry, something went wrong.
|
@trevnorris ... are you going to want to pull this back into v4 at all? If not, can you mark it don't land? |
Sorry, something went wrong.
|
I think the goal is still to backport all the asyncwrap stuff? |
Sorry, something went wrong.
Make `HTTPParser` an instance of `AsyncWrap` and make it use `MakeCallback`. This means that async wrap hooks will be called on consumed TCP sockets as well as on non-consumed ones. Additional uses of `AsyncCallbackScope` are necessary to prevent improper state from progressing that triggers failure in the test-http-pipeline-flood.js test. Optimally this wouldn't be necessary, but for the time being it's the most sure way to allow operations to proceed as they have. Fix: #4416 PR-URL: #5419 Reviewed-By: Fedor Indutny <fedor@indutny.com>
|
As @Fishrock123 said, all the AsyncWrap changes will need to be back ported if it is to maintain compatibility. |
Sorry, something went wrong.
|
Oh hey all. It looks like this commit has created a regression on v5.7.1. Specifically throwing inside of a call back to an http.get request is not throwing :sad: Here is a gist for the test I was using https://gist.github.com/TheAlphaNerd/6615a27684deb682dfe7 You will notice that the setTimeout is commented out... adding set timeout actually fixes this problem 😢 |
Sorry, something went wrong.
|
Based on the regression created by this change I'm going to assume we are not going to land it on v4. @trevnorris let me know if the plans for v4 and asyncwrap changes |
Sorry, something went wrong.
|
I think this probably needs to find its way into LTS but can do so after a longer wait, it fills in the AsyncWrap picture more and the discrepancy between LTS and Stable will be non-trivial if it doesn't land there, and we're getting close to deciding on "official" support for AsyncWrap too. @thealphanerd I'm going to switch back to lts-watch but we need good settling time for this given the regression. |
Sorry, something went wrong.
|
@rvagg SGTM. I'll remove the don't land label from the regression fix |
Sorry, something went wrong.
|
@thealphanerd The regression was fixed in 3521b05. As @rvagg said this is not absolutely necessary for backport, but it shouldn't be a problem to backport with the fix. |
Sorry, something went wrong.
Make `HTTPParser` an instance of `AsyncWrap` and make it use `MakeCallback`. This means that async wrap hooks will be called on consumed TCP sockets as well as on non-consumed ones. Additional uses of `AsyncCallbackScope` are necessary to prevent improper state from progressing that triggers failure in the test-http-pipeline-flood.js test. Optimally this wouldn't be necessary, but for the time being it's the most sure way to allow operations to proceed as they have. Ref: #7048 Fix: #4416 PR-URL: #5419 Reviewed-By: Fedor Indutny <fedor@indutny.com>
Make `HTTPParser` an instance of `AsyncWrap` and make it use `MakeCallback`. This means that async wrap hooks will be called on consumed TCP sockets as well as on non-consumed ones. Additional uses of `AsyncCallbackScope` are necessary to prevent improper state from progressing that triggers failure in the test-http-pipeline-flood.js test. Optimally this wouldn't be necessary, but for the time being it's the most sure way to allow operations to proceed as they have. Ref: #7048 Fix: #4416 PR-URL: #5419 Reviewed-By: Fedor Indutny <fedor@indutny.com>
Make `HTTPParser` an instance of `AsyncWrap` and make it use `MakeCallback`. This means that async wrap hooks will be called on consumed TCP sockets as well as on non-consumed ones. Additional uses of `AsyncCallbackScope` are necessary to prevent improper state from progressing that triggers failure in the test-http-pipeline-flood.js test. Optimally this wouldn't be necessary, but for the time being it's the most sure way to allow operations to proceed as they have. Ref: #7048 Fix: #4416 PR-URL: #5419 Reviewed-By: Fedor Indutny <fedor@indutny.com>
Make `HTTPParser` an instance of `AsyncWrap` and make it use `MakeCallback`. This means that async wrap hooks will be called on consumed TCP sockets as well as on non-consumed ones. Additional uses of `AsyncCallbackScope` are necessary to prevent improper state from progressing that triggers failure in the test-http-pipeline-flood.js test. Optimally this wouldn't be necessary, but for the time being it's the most sure way to allow operations to proceed as they have. Ref: #7048 Fix: #4416 PR-URL: #5419 Reviewed-By: Fedor Indutny <fedor@indutny.com>
| Back | FazBrowse Home | New Git URL |
Make HTTPParser an instance of AsyncWrap and make it use
MakeCallback. This means that async wrap hooks will be called on
consumed TCP sockets as well as on non-consumed ones.
Fix: #4416
This PR overrides #4509.
R= @indutny
R= @bnoordhuis