Forces the Actor to process all queued messages.
Sends a message to this actor with delay
We cannot invoke terminate from within the Actor itself via block because busy is already set to true within receive.
We cannot invoke terminate from within the Actor itself via block because busy is already set to true within receive. AtomicThreadLocalBoolean can be used instead to allow calling terminating from within the Actor itself but this is currently not required anywhere.
Currently there is no use to terminate from within the Actor itself.
Terminates the Actor and applies recover function to all queued messages.
Release function will get executed when the thread was able to set busy to true but busy.set(false) should be invoked by the input releaseFunction similar to *) function under try & finally.
Release function will get executed when the thread was able to set busy to true but busy.set(false) should be invoked by the input releaseFunction similar to *) function under try & finally.
will continue executing the function while the queue is non-empty.