[erlang-questions] Sending message to process already listening on a socket

David Hopwood david.hopwood@REDACTED
Wed Aug 1 02:49:26 CEST 2007

Ben Hood wrote:
> Thanks for you help.
> On 7/31/07, Matthias Lang <matthias@REDACTED> wrote:
>> 1. Yes, messages are queued up until consumed.
> I've been wondering about the formal semantics of erlang message
> passing.

It is 1-1 FIFO; that is, messages are queued in FIFO order between
any given pair of processes, but there are no other constraints on
ordering. For a formal definition of 1-1 FIFO, see Definition 3.3

  Bernadette Charron–Bost, Friedemann Mattern, Gerard Tel
  "Synchronous, asynchronous, and causally ordered communication"
  Distributed Computing (1996) 2:173--191, Springer-Verlag.
  <http://www.vs.inf.ethz.ch/publ/papers/mattern-dc-1996.pdf> or

(that paper just calls it "FIFO").

A brief explanation, so you don't necessarily have to read the
whole paper: a pair (s, r) represents a message transmission where
s is the send event, and r is the receive event. So Definition 3.3
says that if two messages are sent by the same process (s ~ s') and
received by the same process (r ~ r'), then they are received in
the same order they were sent (s < s' => r' < r').

Note that messages will be dropped if the target process dies, or
if there is a network error when a message is being sent between

David Hopwood <david.hopwood@REDACTED>

More information about the erlang-questions mailing list