On 15/02/2013, at 15:15, Matt wrote:

> I had a number of questions at work this week about how node works on a low 
> level, so decided to create a blog post about the basics of how event loops 
> work.
> 
> I'm hoping this might help other people get more of an understanding of how 
> Node works internally. It's not an entirely accurate reflection of the node 
> internals, more of a general overview of how event loops work from a basic 
> implementation standpoint.
> 
> http://baudehlo.wordpress.com/2013/02/14/how-an-event-loop-works/
> 
> Would love to get feedback on the post.

The process.nextTick(ƒ) queue, more or less... :-)

while (someThingToDo) {

    var n= nextTickQueue.length;
    while (n--) nextTickQueue.shift()();

    var next_timeout = _run_timers();

    if (nextTickQueue.length) continue;
    ms_sleep(next_timeout);
}

-- 
Jorge.

-- 
-- 
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

--- 
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].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to