Uh oh!
There was an error while loading. Please reload this page.
test: add tests for clearBuffer state machine - #9922
Conversation
bnoordhuis
left a comment
There was a problem hiding this comment.
Someone from @nodejs/streams should do the final sign-off but LGTM insofar I'm able to judge that.
121b512 to
6c33afeComparecaptainsafia
commented
Dec 1, 2016
@bnoordhuis: Good catch on the blank line! Updated the code! |
There was a problem hiding this comment.
can you please trigger the corked and bufferedRequestCount things using the normal API?
captainsafia
commented
Dec 2, 2016
@mcollina: Thanks for the comment! I've tried to address your review. I set I'm trying to trace what's going on but before I invest too much time I figured I might ask you and see if I am missing an obvious way to do this. |
mcollina
commented
Dec 2, 2016
@captainsafia you need to have an async |
captainsafia
commented
Dec 3, 2016
@mcollina: Thanks for the guidance! I'll try pursuing it on my own for a bit next week and get in touch with you on IRC if I'm not getting anywhere. |
Trott
commented
Dec 11, 2016
Bump! @captainsafia Are you still working on this? |
captainsafia
commented
Dec 11, 2016
Yep! I did some tinkering with it yesterday but I don't think I have anything commit worthy. I'll see if I can get something tomorrow or Monday. Sorry for leaving this hanging! |
captainsafia
commented
Dec 13, 2016
@mcollina: Couldn't catch you on IRC so here goes.
I've got a barebones
I'm using |
There was a problem hiding this comment.
We should consider using a regular function here, as we make no guarentees that apply() or call() may not be called on this internally in the future.
(Assigning arrow functions as prototype functions is generally bad practice because those do not work.)
Lines 310 to 318 in f3cf8e9 You should issue multiple writes synchronously after Note that Line 409 in f3cf8e9 _write, and one with a stream with _writev. |
Trott
commented
Dec 21, 2016
Ping @captainsafia! Still working on this? (No rush; I'm just making sure it's not stalled.) |
captainsafia
commented
Dec 23, 2016
Sorry for staying delayed on this. I'd love to see this own through but I think it is a tad bit above my pay grade at the moment so I'll close it and give someone else the opportunity to tackle it with some of the insights provided above. |
mcollina
commented
Dec 23, 2016
@captainsafia may I build upon your commit? |
captainsafia
commented
Dec 23, 2016
@mcollina: Sure! I've added you as a collaborator on my fork. |
59f370f to
9d1d739Comparemcollina
commented
Jan 2, 2017
@captainsafia I force pushed this. Let me know if you are ok with the content. |
9d1d739 to
53cf711Compare53cf711 to
d1709c3CompareThis checks to see that clearBuffer appropriately decrements the correct values in _writableState when clearBuffer is invoked in end. Fixes: nodejs#8687 PR-URL: nodejs#9922 Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
d1709c3 to
b0be2acComparemcollina
commented
Jan 2, 2017
@italoacasas should be addressed. |
Trott
commented
Jan 2, 2017
CI failures on AIX and FreeBSD seem unrelated. I just terminated some stalled tests on those machines--probably a previous test run had a bug that caused cluster tests to hang and not free ports, causing subsequent runs like this one to also fail. Re-running CI: https://ci.nodejs.org/job/node-test-pull-request/5665/ |
italoacasas
commented
Jan 3, 2017
Landed 275362a |
captainsafia
commented
Jan 3, 2017
Thanks for getting this through the finish line, everyone! ❤️ |
This checks to see that clearBuffer appropriately decrements the correct values in _writableState when clearBuffer is invoked in end. Fixes: #8687 PR-URL: #9922 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com>
This checks to see that clearBuffer appropriately decrements the correct values in _writableState when clearBuffer is invoked in end. Fixes: #8687 PR-URL: #9922 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com>
This checks to see that clearBuffer appropriately decrements the correct values in _writableState when clearBuffer is invoked in end. Fixes: #8687 PR-URL: #9922 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com>
This checks to see that clearBuffer appropriately decrements the correct values in _writableState when clearBuffer is invoked in end. Fixes: #8687 PR-URL: #9922 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com>
This checks to see that clearBuffer appropriately decrements the correct values in _writableState when clearBuffer is invoked in end. Fixes: #8687 PR-URL: #9922 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com>
This checks to see that clearBuffer appropriately decrements the correct values in _writableState when clearBuffer is invoked in end. Fixes: #8687 PR-URL: #9922 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com>
This checks to see that clearBuffer appropriately decrements the correct values in _writableState when clearBuffer is invoked in end. Fixes: #8687 PR-URL: #9922 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com>
This checks to see that clearBuffer appropriately decrements the correct values in _writableState when clearBuffer is invoked in end. Fixes: #8687 PR-URL: #9922 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Italo A. Casas <me@italoacasas.com>
Checklist
make -j8 test(UNIX), orvcbuild test nosign(Windows) passesAffected core subsystem(s)
stream, test
Description of change
This checks to see that clearBuffer appropriately decrements the
correct values in _writableState when clearBuffer is invoked in
end.
Closes#8687.