3 ms·
Generally nginx is written in C which simply performs better than garbage collected, dynamically typed javascript. But regarding sending static files, nginx us
by emilsedgh 8y ago
Generally nginx is written in C which simply performs better than garbage collected, dynamically typed javascript.
But regarding sending static files, nginx uses Linux' sendFile[0] which outperforms anything in user-space.
Up until a few years ago this wasn't something Node could use. I'm not sure if still that's the case though. My information could be badly outdated.
[0] http://man7.org/linux/man-pages/man2/sendfile.2.html http://man7.org/linux/man-pages/man2/sendfile.2.html