Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could not establish any connection #30

Open
memoryonrepeat opened this issue Apr 25, 2016 · 2 comments
Open

Could not establish any connection #30

memoryonrepeat opened this issue Apr 25, 2016 · 2 comments

Comments

@memoryonrepeat
Copy link

Hi, I tried to use thor for stress testing my socket.io 1.3.5 server but it doesn't seem to be able to establish the connection even with the least amount possible. This is the log:

➜  ~ thor --amount 1 ws://localhost:6001/

Thor:                                                  version: 1.0.0

God of Thunder, son of Odin and smasher of WebSockets!

Thou shall:
- Spawn 4 workers.
- Create all the concurrent/parallel connections.
- Smash 1 connections with the mighty Mjölnir.

The answers you seek shall be yours, once I claim what is mine.

Connecting to ws://localhost:6001/



Online               188 milliseconds
Time taken           188 milliseconds
Connected            0
Disconnected         0
Failed               1
Total transferred    0B
Total received       0B

Durations (ms):

                     min     mean     stddev  median max
Handshaking          NaN     NaN         NaN     NaN NaN
Latency              NaN     NaN         NaN     NaN NaN

Percentile (ms):

                      50%     66%     75%     80%     90%     95%     98%     98%    100%
Handshaking          NaN     NaN     NaN     NaN     NaN     NaN     NaN     NaN     NaN
Latency              NaN     NaN     NaN     NaN     NaN     NaN     NaN     NaN     NaN

Received errors:

1x                   read ECONNRESET

I also tried with a more detailed websocket url, result is the same:

➜  ~ thor --amount 1 ws://localhost:6001/socket.io/?EIO=3&transport=websocket
[1] 99052
➜  ~
Thor:                                                  version: 1.0.0

God of Thunder, son of Odin and smasher of WebSockets!

Thou shall:
- Spawn 4 workers.
- Create all the concurrent/parallel connections.
- Smash 1 connections with the mighty Mjölnir.

The answers you seek shall be yours, once I claim what is mine.

Connecting to ws://localhost:6001/socket.io/?EIO=3



Online               184 milliseconds
Time taken           184 milliseconds
Connected            0
Disconnected         0
Failed               1
Total transferred    0B
Total received       0B

Durations (ms):

                     min     mean     stddev  median max
Handshaking          NaN     NaN         NaN     NaN NaN
Latency              NaN     NaN         NaN     NaN NaN

Percentile (ms):

                      50%     66%     75%     80%     90%     95%     98%     98%    100%
Handshaking          NaN     NaN     NaN     NaN     NaN     NaN     NaN     NaN     NaN
Latency              NaN     NaN     NaN     NaN     NaN     NaN     NaN     NaN     NaN

Received errors:

1x                   read ECONNRESET

[1]  + 99052 done       thor --amount 1 ws://localhost:6001/socket.io/?EIO=3

Any idea what could have gone wrong and what should I look into ? Thanks

@3rd-Eden
Copy link
Member

Thats probably because Socket.IO requires a HTTP handshake in order to get a session id which is used to establish the real-time connection afterwards.

@sesm
Copy link

sesm commented May 11, 2016

@tienthanh8490 To test Socket.IO server you could use a different websocket benchmark tool, for example this: https://github.com/M6Web/websocket-bench

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants