[erlang-questions] How does Erlang TCP determine the end of a TCP stream?
Tue Oct 31 17:20:36 CET 2017
On Oct 31, 2017, at 10:10 AM, code wiget <codewiget95@REDACTED> wrote:
> I would like to clarify quickly that this is not a coincidence, and that I am processing ~500 messages/min over 1 socket connected to 1 client server and all of the messages are “framed” properly. There is something in the OTP that is framing the packets.
It is a coincidence and there is nothing framing the *MESSAGES*.
> It does not define how long “one data message” is, but from reading on, it seems like the small size of my packets is the reason it is working. All of the packets I am expecting are < 500 bytes.
That does make it extremely likely that each message will be delivered in a single packet, but there is still no guarantee. There is also no guarantee 2 or more messages won't be delivered in a single packet.
More information about the erlang-questions