C
C
ClaraOswald2017-02-23 18:23:37
Computer networks
ClaraOswald, 2017-02-23 18:23:37

What is the best way to make requests, via web-socket or via http?

There is a web-socket, it is necessary to send data to the server (for example, a user message), how is it more rational to implement it? via web socket or http request?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vitaly Stolyarov, 2017-02-23
@ClaraOswald

It all depends on the frequency of their sending. It’s impossible to say for sure, but, let’s say, if on average you need to send more than one message per second, then it’s better to use WebSocket, but at the same time, in applications like Trello, messages are exchanged much less often and the web socket connection is constantly kept.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question