2. I got tired of fussing with kernel network config tuning, and I'm more confident with writing servers in node than C/C++.
3. A reduction in TCP sockets needed to handle a few thousand concurrent connections from several tens of thousand to just the few thousand. The request/response model of doing it in something like PHP meant there were connection from the users to nginx, nginx to php-fpm, php-fpm to the database for each user -- and it increased at more than just 3x the number of users since TCP connection stick around a while after they're finished waiting for any out-of-order packets and such.
A reduction in time-per-request from ~70ms to ~1ms. No initialization/db-connect/teardown per-request means node can do its thing and dispose of the request much faster than PHP, which was the original language this was written in some years ago.
That's nice!
I guess the response time will be on the same network, right?If not, What is your server provider? How far you are from the server? What is your ISP?
The 70ms and 1ms are time spent in the application handle each request, not response times at the client. That's going to be determined by latency between the client and the servers, which are hosted in Softlayer's Washington DC data center. 19ms from Philadelphia if you're curious.
http://www.w3counter.com/stats/pulse/1
2. I got tired of fussing with kernel network config tuning, and I'm more confident with writing servers in node than C/C++.
3. A reduction in TCP sockets needed to handle a few thousand concurrent connections from several tens of thousand to just the few thousand. The request/response model of doing it in something like PHP meant there were connection from the users to nginx, nginx to php-fpm, php-fpm to the database for each user -- and it increased at more than just 3x the number of users since TCP connection stick around a while after they're finished waiting for any out-of-order packets and such.
A reduction in time-per-request from ~70ms to ~1ms. No initialization/db-connect/teardown per-request means node can do its thing and dispose of the request much faster than PHP, which was the original language this was written in some years ago.
http://i.imgur.com/ipQXcjJ.png