L
L
lgick2014-06-02 23:40:01
Socket.io
lgick, 2014-06-02 23:40:01

Does the number of messages in websockets matter?

Will there be a significant difference when sending/receiving messages if they are divided, for example, into 5 parts?

That is, instead of one big message, send 5 small ones.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
N
Nikita Markelov, 2014-06-14
@lgick

Yes, the difference is huge. The TCP header weighs from 84 to 120 bytes, which is a lot. In addition, extra messages are an extra load on the server. Therefore, it is much more profitable to send everything through one message than to produce many small ones.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question