When dispatching from an asynchronous operation using C++, the function 
node::MakeCallback is
supposed to automatically set 
<https://github.com/trevnorris/node/commit/6d91bd37075a53f42bab01915fa89ba4a4f0a075>
 
the domain of the callback. So if method throws, then an event will
be sent to the domain.  At least that's the expectation.  From the node 
source, it appears that recv
is used to obtain the domain to which these events will posted

NODE_EXTERN v8::Handle<v8::Value> MakeCallback(

    v8::Isolate* isolate,

    v8::Handle<v8::Object> recv,

    const char* method,

    int argc,

    v8::Handle<v8::Value>* argv);



Local<Context> context = recv->CreationContext();
Environment* env = Environment::GetCurrent(context);

and then later

if (env->using_domains())

etc.

What recv is and how's it's derived  is a mystery.  I can't find it 
documented.  I've tried 
various values for recv:  args.This(), Context()->Global(), the callback 
itself, etc. saved directly
as a Persistent or saved as a object contained in a Persistent Array... all 
approaches fail. So
here I am.  If anyone knows what this object is or can suggest a next step, 
thanks in advance.



-- 
Job board: http://jobs.nodejs.org/
New group rules: 
https://gist.github.com/othiym23/9886289#file-moderation-policy-md
Old group rules: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
--- 
You received this message because you are subscribed to the Google Groups 
"nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/nodejs/6ce55d82-e75c-4c2a-9e6b-15f6fbd6d0b7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to