Akka (6) – Mailbox

An Akka Mailbox holds the messages that are destined for an Actor. Normally each Actor has its own mailbox, but with for example a BalancingPool all routes will share a single mailbox instance.

When the mailbox is not specified as the default mailbox is used. By default it is an unbounded mailbox, which is backed by a java.util.concurrent.ConcurrentLinkedQueue.

Using bounded mailbox:

  • When mailbox is full, messages go to DeadLetters.
  • mailbox-push-timeout-time: how long to wait when mailbox is full
  • Doesn’t work for distributed Akka systems.



Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s