Closed
Conversation
72d62fb to
d7e0c53
Compare
Some calls to ReqWrap would get through the initial check and allow the init callback to run, even though the callback had not been used on the parent. Fix by explicitly checking if the parent has a queue. Also change the name of the check, and internal field of AsyncHooks. Other names were confusing.
d7e0c53 to
13e52fe
Compare
Member
|
LGTM with a suggestion. |
Allow the init callback to see the PROVIDER type easily by being able to compare the flag with the list of providers on the exported async_wrap object.
Setting flags using cryptic numeric object fields is confusing. Instead use much simpler .enable()/.disable() calls on the async_wrap object.
It doesn't make sense to call before/after callbacks in init to the parent because they'll be made anyway from MakeCallback. If information does need to be propagated then it should be done automatically. Will deal with this if the issue arrises in the future.
13e52fe to
eed38b3
Compare
Contributor
Author
|
@bnoordhuis thanks. addressed both comments. |
Member
There was a problem hiding this comment.
I would do the same for SetupHooks for consistency. That can wait for another PR though.
Contributor
Author
There was a problem hiding this comment.
might as well. had to run before I had a chance to land this.
Member
|
LGTM |
trevnorris
added a commit
that referenced
this pull request
May 5, 2015
Some calls to ReqWrap would get through the initial check and allow the init callback to run, even though the callback had not been used on the parent. Fix by explicitly checking if the parent has a queue. Also change the name of the check, and internal field of AsyncHooks. Other names were confusing. PR-URL: #1614 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
trevnorris
added a commit
that referenced
this pull request
May 5, 2015
Allow the init callback to see the PROVIDER type easily by being able to compare the flag with the list of providers on the exported async_wrap object. PR-URL: #1614 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
trevnorris
added a commit
that referenced
this pull request
May 5, 2015
Setting flags using cryptic numeric object fields is confusing. Instead use much simpler .enable()/.disable() calls on the async_wrap object. PR-URL: #1614 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
trevnorris
added a commit
that referenced
this pull request
May 5, 2015
It doesn't make sense to call before/after callbacks in init to the parent because they'll be made anyway from MakeCallback. If information does need to be propagated then it should be done automatically. Will deal with this if the issue arrises in the future. PR-URL: #1614 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Contributor
Author
Fishrock123
pushed a commit
to Fishrock123/node
that referenced
this pull request
May 19, 2015
Some calls to ReqWrap would get through the initial check and allow the init callback to run, even though the callback had not been used on the parent. Fix by explicitly checking if the parent has a queue. Also change the name of the check, and internal field of AsyncHooks. Other names were confusing. PR-URL: nodejs#1614 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Fishrock123
pushed a commit
to Fishrock123/node
that referenced
this pull request
May 19, 2015
Allow the init callback to see the PROVIDER type easily by being able to compare the flag with the list of providers on the exported async_wrap object. PR-URL: nodejs#1614 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Fishrock123
pushed a commit
to Fishrock123/node
that referenced
this pull request
May 19, 2015
Setting flags using cryptic numeric object fields is confusing. Instead use much simpler .enable()/.disable() calls on the async_wrap object. PR-URL: nodejs#1614 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Fishrock123
pushed a commit
to Fishrock123/node
that referenced
this pull request
May 19, 2015
It doesn't make sense to call before/after callbacks in init to the parent because they'll be made anyway from MakeCallback. If information does need to be propagated then it should be done automatically. Will deal with this if the issue arrises in the future. PR-URL: nodejs#1614 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Finally getting around to finishing the
AsyncWrapimplementation. Here are some mostly minor changes. One specifically is breaking. Instead of needing to set the object field to enable/disable callbacks there are now methods on theasync_wrapimport. e.g.R=@bnoordhuis