socket.io failed connections when testing with Artillery #4341
-
I'm setting up a node.js socket.io server and need to support around 10k users. This guide says it should be possible to get up to 55k concurrent connections. I'm hosting on an Ubuntu 20.04 EC2 with 4 vcpus and 16b RAM. Socket.io JavaScript (reduced for clarity) for node.js is:
I've followed the steps in the guide above doing:
And
I've also read through and tried the settings from this article. I am testing with Artillery with the following YAML config:
I am getting really varied results. With exactly those settings I am getting 0 If I increase either the duration or the arrival rate to give a higher overall number of users I start to get significant numbers of I'm not quite sure exactly what I'm using What does Why am I getting What do I need to change? Do I need the sticky sessions and is that what's required to use all 4 processor cores on the server? Thanks very much! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 6 replies
-
Hi!
I was able to happily go to 25k clients without any problem on my machine with one single Socket.IO server (
Result:
Please note that sticky sessions are not needed if you are only using WebSockets. In that case, using If you also need HTTP long-polling, please check the |
Beta Was this translation helpful? Give feedback.
Hi!
which version of artillery are you using? It seems there was a lot of updates recently. Does it run in multi-threaded mode?
did you try with manual client creation?
which
arrivalRate
are you using? Sometimes a higharrivalRate
can lead to issues from artillery.I was able to happily go to 25k clients without any problem on my machine with one single Socket.IO server (
[email protected]
):Result: