Last active
August 29, 2015 13:56
-
-
Save adohe-zz/9105755 to your computer and use it in GitHub Desktop.
concurrent connections vs connections per second
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| concurrent connections and connection per second are two different beasts. | |
| To handle 1m concurrent connections a traditional synchronous server would | |
| create 1m threads (or worst, processes) with all the stacks and memory needed. | |
| Node handles that in a sngle thread, but the more connections there are, the | |
| bigger latency per request is need to handle them. because it's single-threaded, | |
| you can however utilize the cluster module to use more than one cpu core on your | |
| machine. | |
| But to handle 1m connections per second, this is about latency, and this you | |
| can only get for the price of higher resource usage. cluster module, horizontal | |
| scaling over several physical machines. etc. node is not different here form | |
| other tools. In fact typicaly it has same latency pattern as rails or php-based | |
| solutions, if you use them the same way. Node's strenghth is the ability to handle | |
| concurrent connections with much lower footprint of memory. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment