On Thu, Apr 4, 2013 at 11:26 PM, Nikhil Marathe <[email protected]> wrote: > > On Thu, Apr 4, 2013 at 2:11 PM, Fredrik O <[email protected]> wrote: >> >> When node.js was created, why was it essential to create a new library to >> run background (asynchronous) jobs? What was to example wrong with >> boost.asio or libevent? If some functionality was needed should it well be >> more easy to extend those libraries than to create a new library, from >> scratch? > > > libev was not created by node.js folks. libev already existed as an > alternative to libevent. To quote libev's README > " Libev is modelled (very losely) after libevent and the Event perl module, > but is faster, scales better and is more correct, and also more featureful. > And also smaller. Yay." > > Boost.Asio is AFAIK a part of Boost and so has dependencies on other parts > of Boost. It is also C++. The aim for node has always been to have a really > small C kernel, and hoist as much stuff into JS as possible. This keeps it > simple and makes development faster and easier to do cross platform. > > libuv started as a small wrapper around libev by node developers. libev is > Unix only, and does not support Windows async IO. libuv wrapped libev on > Unix, while working with IOCP on Windows, but preserving the same API. > > So those are the two reasons - no Boost.Asio to keep things small and no > 'libev only' for Windows support. > > Eventually libev was removed from the underlying code and libuv took over > most of its responsibilities. Why this was done I'll let more knowledgeable > people answer. > > Nikhil
I guess that's my cue. :-) Libev was removed for the reasons outlined here: https://github.com/joyent/libuv/issues/485 I would have dropped it sooner but there were still a lot of node.js add-ons that used libev in some way. You have to give people time to upgrade. Boost.Asio was never really an option. It's very C++-y while node.js is more "C with classes" but what's more is that it didn't (and doesn't) do everything we need. Someone on SO wrote a great post that details the differences so I'll just link to that: http://stackoverflow.com/questions/11423426/how-does-libuv-compare-to-boost-asio -- -- 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.
