3

It seems that the standard practice is to immediately alias MailboxProcessor<'T> to Agent<'T>. So why the name in the first place anyways? Why don't they just call it Agent<'T>, if there's no name conflict to begin with? It sounds like something to do with receiving emails to be honest. I couldn't find any information after some Googling.

3
  • 1
    I think it's a historical coincidence, and now they can't rename it, lest they break all existing code. Sep 2, 2016 at 17:42
  • @FyodorSoikin Sure, but the question is more about why they did it in the first place.
    – xji
    Sep 2, 2016 at 17:46
  • Note: Now that I've had much more experience with the actor model (programming with Elixir/Erlang) 4 years later, this name does make sense to me.
    – xji
    Dec 5, 2020 at 11:11

1 Answer 1

6

"Mailbox" is a standard term in message passing concurrency. A mailbox is where the messages are delivered to. It's basically an older and more widely-used synonym for "message queue". It is also somewhat more general than "message queue" and can be applied in situations where messages are not ordered (e.g. in the Actor Model).

So, a "mailbox processor" is something that processes messages from a mailbox. In the Actor Model, the Actors are the mailbox processors, in an Agent Model, the Agents are the mailbox processors, and so on.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.