The diagrams do not capture the current state of the code in Receptor. They are to start a conversation that moves towards desired behavior of Receptor.
Receptor work protocol for work submitted to Bob destined for Alice.
- The first
work unit 123
never makes it to Alice. Upon restart, Bob will resubmitwork unit 123
request to Alice.
- Bob submits work that is already known to Alice. In this case, Alice ignores the work and replies to Bob informing him of this case. Bob then records this for efficiency sake. If Bob were to crash any time after
RemoteStarted 123
, he would know that work has already been submitted to Alice. Note that even if Bob lost his recording ofRemoteStarted 123
; it would be fine for him to re-submitwork unit 123
. TheRemoteStarted
is a nicety.
Note that the above 2 crash scenarios are really the same scenario; a crash of Bob or Alice occuring before RemoteStarted 123
will result in re-submitting work unit 123
to Alice. This is idempotent behavior.