Elaborating on the message send semantics as per the ticket
This commit is contained in:
parent
4803ba517c
commit
d7771dc596
2 changed files with 35 additions and 8 deletions
|
|
@ -5,9 +5,9 @@ General
|
||||||
:maxdepth: 2
|
:maxdepth: 2
|
||||||
|
|
||||||
jmm
|
jmm
|
||||||
|
message-send-semantics
|
||||||
configuration
|
configuration
|
||||||
event-handler
|
event-handler
|
||||||
slf4j
|
slf4j
|
||||||
addressing
|
addressing
|
||||||
supervision
|
supervision
|
||||||
guaranteed-delivery
|
|
||||||
|
|
|
||||||
|
|
@ -1,13 +1,14 @@
|
||||||
|
|
||||||
.. _guaranteed-delivery:
|
.. _message-send-semantics:
|
||||||
|
|
||||||
#####################
|
#######################
|
||||||
Guaranteed Delivery
|
Message send semantics
|
||||||
#####################
|
#######################
|
||||||
|
|
||||||
|
|
||||||
Guaranteed Delivery
|
|
||||||
===================
|
Guaranteed Delivery?
|
||||||
|
====================
|
||||||
|
|
||||||
Akka does *not* support guaranteed delivery.
|
Akka does *not* support guaranteed delivery.
|
||||||
|
|
||||||
|
|
@ -39,4 +40,30 @@ application and can solve it fastest and most reliable by explicit ``ACK`` and
|
||||||
``RETRY`` (if you really need it, most often you don't). Using Akka's Durable
|
``RETRY`` (if you really need it, most often you don't). Using Akka's Durable
|
||||||
Mailboxes could help with this.
|
Mailboxes could help with this.
|
||||||
|
|
||||||
.. _Erlang documentation: http://www.erlang.org/faq/academic.html
|
Delivery semantics
|
||||||
|
==================
|
||||||
|
|
||||||
|
At-most-once
|
||||||
|
------------
|
||||||
|
|
||||||
|
Actual transports may provide stronger semantics,
|
||||||
|
but at-most-once is the semantics you should expect.
|
||||||
|
The alternatives would be once-and-only-once, which is extremely costly,
|
||||||
|
or atleast-once which essentially requires idempotency of message processing,
|
||||||
|
which is a user-level concern.
|
||||||
|
|
||||||
|
Ordering is preserved on a per-sender basis
|
||||||
|
-------------------------------------------
|
||||||
|
|
||||||
|
Actor ``A1` sends messages ``M1``, ``M2``, ``M3`` to ``A2``
|
||||||
|
Actor ``A3`` sends messages ``M4``, ``M5``, ``M6`` to ``A2``
|
||||||
|
|
||||||
|
This means that:
|
||||||
|
1) If ``M1`` is delivered it must be delivered before ``M2`` and ``M3``
|
||||||
|
2) If ``M2`` is delivered it must be delivered before ``M3``
|
||||||
|
3) If ``M4`` is delivered it must be delivered before ``M5`` and ``M6``
|
||||||
|
4) If ``M5`` is delivered it must be delivered before ``M6``
|
||||||
|
5) ``A2`` can see messages from ``A1`` interleaved with messages from ``A3``
|
||||||
|
6) Since there is no guaranteed delivery, none, some or all of the messages may arrive to ``A2``
|
||||||
|
|
||||||
|
.. _Erlang documentation: http://www.erlang.org/faq/academic.html
|
||||||
Loading…
Add table
Add a link
Reference in a new issue