If you mean that it bottlenecks communication with it, yes, the mailbox can 
kind of be treated like a 'mutex'.  Depending on how you are operating on 
the data and how it can be referenced then a pool of these managed by a 
supervisor (or library like poolboy) or operating on multiple messages at 
once inside the process or even raising it into ETS with a library for 
operating on the data within ETS can be significantly faster.  However a 
good bottleneck can help in many cases as well (most I dare say) so it 
depends on the use-case as to whether you want it or not.

TL;DR: A process generally operates on one message at a time, but there are 
alternative methods.

On Monday, August 1, 2016 at 3:33:30 AM UTC-6, Kaveh Shahbazian wrote:
>
> (Noob Here) -
>
> Is a statefull process a bottleneck? (Not exactly; because of the Mailbox) 
> Like a `mutex` in more traditional languages?
>

-- 
You received this message because you are subscribed to the Google Groups 
"elixir-lang-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to elixir-lang-talk+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elixir-lang-talk/b404dc0f-c451-4d7a-8c75-1af3203e59a2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to