[erlang-questions] Sending binaries between nodes.

Bjorn Gustavsson bjorn@REDACTED
Mon Nov 26 13:35:47 CET 2007


"Luke Hubbard" <luke@REDACTED> writes:

> Hi All,
> 
> This is my first post to the list, so a big hello from Thailand to kick
> things off.

Welcome!

> My question is about passing large binaries between nodes. I have read that
> if you pass a binary around the same node then there is only one copy which
> is ref counted and stored on a separate stack. This is great, but what
> happens when you send the same binary to another node in separate messages.
> Does Erlang know its sent the binary before and after the first time send
> some form of reference or will it send the same binary data multiple times.
> The use case for this is broadcasting a binary message to multiple processes
> on each node.

It will copy the binary each time.

/Bjorn
-- 
Björn Gustavsson, Erlang/OTP, Ericsson AB



More information about the erlang-questions mailing list