Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Why would a DB driver need to integrate with libuv in the first place?


In the case where the driver (for instance the official libmysql) doesn't expose its network interface (e.g. its sockets can't be used with an external event loop). In that case, it would block on IO operation, and there is no other choice but to push it to another thread.

That said, using a driver in another thread leads to various complexities that can be avoided when running in the same application (javascript/v8) thread/event loop.


To be evented and get the respective performance gains in a Node setting?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: