[erlang-questions] Problems with sending UDP datagrams without buffering

Per Hedeland <>
Thu Nov 6 21:19:02 CET 2008


"Matt Williamson" <> wrote:
>
>It's apparent from the subject, that Mark is talking about UDP datagrams.

Yes but...

>I agree with Trevor's suggestion. Check out
>http://www.erlang.org/doc/man/inet.html#setopts-2
><http://www.erlang.org/doc/man/inet.html#setopts-2>
>
>{sndbuf, Integer}Gives the size of the send buffer to use for the socket.
>So: gen_udp:open( Port, [binary, {sndbuf, 700}] ).

...as has already been pointed out by Matthias, there's no way Erlang or
anything else could be "merging" multiple UDP datagrams into one without
completely wreaking havoc with UDP semantics - no matter what
"buffering" is specified where, it simply won't happen.

If Mark wants to see some progress here, he should follow Matthias'
advice and provide a small program + instructions that would allow
someone else to reproduce what he's seeing - and then we would likely
find that he isn't doing what he thinks he is doing, or isn't seeing
what he thinks he is seeing.:-)

--Per Hedeland



More information about the erlang-questions mailing list