An actor is a computational entity that, in response to a message it receives, can concurrently:
There is no assumed sequence to the above actions and they could be carried out in parallel.
Popularized by Ericsson in the 80s and 90s for building highly reliable telephony applications written in Erlang
def supervisorStrategy: SupervisorStrategy = {
OneForOneStrategy(){
case _: ActorInitializationException ⇒ Stop
case _: ActorKilledException ⇒ Stop
case _: DeathPactException ⇒ Stop
case _: Exception ⇒ Restart
}
}Comes in two flavors: