Well, I think Jake was talking about queuing the callbacks and waiting for
the event to return back and fire those callbacks. This is a pattern that I
try to avoid inside Node.js because of the potential memory leaking
probability.

What if something went wrong and the event never "ping back"? Your callback
will stay there ocuping memory.

--
Att,
Alan Hoffmeister


2013/1/16 Katsumoto <[email protected]>

> What abuse or problem could be here if this is normal async flow, event
> handler could return error as first argument.
>
> среда, 16 января 2013 г., 8:54:31 UTC+2 пользователь Raynos написал:
>>
>> You guys realize that using events to effectively call a series of
>> functions in parallel or series is abuse of the event emitter right.
>>
>> What your doing there is RPC over events. RPC is best done with something
>> like functions or methods
>>
>> If an event handler can error you need to put down your EventEmitter and
>> think about your code and how to structure it.
>>
>>
>> On Tue, Jan 15, 2013 at 2:48 PM, Brian Link <[email protected]> wrote:
>>
>>> Very cool.  I've been loving this pattern. Bright minds ...
>>>
>>>
>>> On Tuesday, January 15, 2013 2:35:31 PM UTC-8, Katsumoto wrote:
>>>>
>>>> I'm using the same flow for almost a year in my framework.
>>>> Here is my lightweight implementation: https://github.com/Shogun147/**K
>>>> **atana/blob/master/lib/**bootstra**p.js#L1-L40<https://github.com/Shogun147/Katana/blob/master/lib/bootstrap.js#L1-L40>
>>>>
>>>  --
>>> Job Board: http://jobs.nodejs.org/
>>> Posting guidelines: https://github.com/joyent/**node/wiki/Mailing-List-*
>>> *Posting-Guidelines<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 post to this group, send email to [email protected]
>>>
>>> To unsubscribe from this group, send email to
>>> nodejs+un...@**googlegroups.com
>>>
>>> For more options, visit this group at
>>> http://groups.google.com/**group/nodejs?hl=en?hl=en<http://groups.google.com/group/nodejs?hl=en?hl=en>
>>>
>>
>>  --
> Job Board: http://jobs.nodejs.org/
> Posting guidelines:
> 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 post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://groups.google.com/group/nodejs?hl=en?hl=en
>

-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
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 post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

Reply via email to