You could change the behavior via `context.become` to a new one which ignores the respective message(s).
Heiko -- Heiko Seeberger Home: heikoseeberger.de <http://heikoseeberger.de/> Twitter: @hseeberger <https://twitter.com/hseeberger> Public key: keybase.io/hseeberger <https://keybase.io/hseeberger> > On 24 Sep 2015, at 17:37, Christian Schmitt <[email protected]> wrote: > > Hello, currently I send Messages to an Actor which all does the same thing. > > So my Actor will do the same action in a few ms which is bad, is there a way > to just drop the mailbox before I run my command inside the Akka Actor? > something like: > > > def recieve = { > case Message => cleanupMailbox(); doSomething(); > } > > -- > >>>>>>>>>> Read the docs: http://akka.io/docs/ <http://akka.io/docs/> > >>>>>>>>>> Check the FAQ: > >>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html > >>>>>>>>>> <http://doc.akka.io/docs/akka/current/additional/faq.html> > >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user > >>>>>>>>>> <https://groups.google.com/group/akka-user> > --- > You received this message because you are subscribed to the Google Groups > "Akka User List" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected] > <mailto:[email protected]>. > To post to this group, send email to [email protected] > <mailto:[email protected]>. > Visit this group at http://groups.google.com/group/akka-user > <http://groups.google.com/group/akka-user>. > For more options, visit https://groups.google.com/d/optout > <https://groups.google.com/d/optout>. -- >>>>>>>>>> Read the docs: http://akka.io/docs/ >>>>>>>>>> Check the FAQ: >>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user --- You received this message because you are subscribed to the Google Groups "Akka User List" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/akka-user. For more options, visit https://groups.google.com/d/optout.
