4

Here is the link for a simple chat application with room concept which I'm referring to learn how to create socket.io applications - https://github.com/mcantelon/chatrooms .

I need to test how much load this application takes for socket.io.

How can I test how many connections it serves successfully? Is there any tool or method to achieve this?

  • Have you looked at Jmeter or Gatling? Both free load testing tools with getting started documentation. – Sam Woods Jan 6 '15 at 18:16
2

Socket.IO uses WebSocket protocol so you need to look for a load testing tool capable of WebSocket testing.

As far as I'm aware there is a WebSocket Plugin for Apache JMeter which can be used to stress your chat application.

See WebSocket Testing With Apache JMeter guide for more details.

1

Artillery is a load-testing tool with native Socket.io support out of the box (and is written in Node.js too).

Why is native Socket.io support important? WebSocket is only one of the underlying transport protocols that Socket.io can use and Socket.io layers its own protocol on top, so while it's possible to test a Socket.io server with something like the WebSocket Plugin for JMeter, it certainly won't be as easy to write your tests as when using something that speaks Socket.io "natively", and your tests won't be as realistic (for example, you will skip protocol negotiation and will be connecting straight to the WebSocket endpoint exposed by Socket.io).

(Disclosure: I am the lead developer of Artillery.)

  • 1
    You need to disclose your affiliation with Artillery.io in your answer, or it will be deleted as spam. Please edit your answer to note your association with the tool. – Kate Paulk Sep 2 '16 at 11:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.