[erlang-questions] Do messages casted by Process A always get received before messages called by Process A?
Kris Rasmussen
kris@REDACTED
Thu Oct 20 00:09:37 CEST 2011
Geoff, thanks for the response. I think I may have been ambiguous in my
wording. To be more specific, can you tell me if the following is true:
Imagine process A does the following:
call(B, 1)
cast(B, 2)
call(B, 3)
Will B always receive the messages in the order A sent them (1, 2, 3) as
opposed to something like (1, 3, 2) occasionally?
On Wed, Oct 19, 2011 at 3:00 PM, Geoff Cant <nem@REDACTED> wrote:
> No, messages are handled in the order they arrive to a gen_* process. So if
> you (1) call A, then (2) cast A, (1) will be handled before (2).
>
> Cheers,
> -Geoff
>
> On 2011-10-19, at 14:46 , Kris Rasmussen wrote:
>
> > Can I assume that casts will be processed before calls in erlang if sent
> > from the same process? I would expect this to be the case given that I
> > assume the only difference between a cast and a call is that a call waits
> > for a response but I certainly could be wrong.
> >
> > Thanks,
> > Kris
> > _______________________________________________
> > erlang-questions mailing list
> > erlang-questions@REDACTED
> > http://erlang.org/mailman/listinfo/erlang-questions
>
>
>
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20111019/3d52417d/attachment.htm>
More information about the erlang-questions
mailing list