Hung Lin
Hung Lin

Reputation: 96

akka non-blocking BoundedMailbox

I'm trying to find a non-blocking way to use akka actors with BoundedMailbox. It should drop messages when actor's mailbox is full. Can I achieve it by just setting pushTimeOut to 0? Is there any drawback or things to notice with this approach?

Upvotes: 3

Views: 708

Answers (1)

Björn Antonsson
Björn Antonsson

Reputation: 1019

Yes, if you set the pushTimeOut to 0 new messages will be dropped if the mailbox is full. The dropped messages will be sent to the special dead letters actor.

Upvotes: 4

Related Questions