A fault-tolerant workload continues acceptable operation when components fail. Actor-based designs keep domain logic on the happy path and move recovery decisions into supervision. section 5.1.2
Actor supervision handles a failed message-processing actor through predefined strategies:
- Restart recreates the actor while preserving its ActorRef and mailbox for subsequent messages. section 5.1.2
- Resume keeps the same actor instance processing messages and logs the exception. section 5.1.2
- Stop terminates the actor so it no longer processes messages. section 5.1.2
- While supervision decides, the failing actor’s mailbox is suspended; incoming messages are stashed. section 5.1.2
Figure 5.6 Supervisor wrapping an actor’s behavior and deciding on a recovery action after an exception
Use the supervisor-wrapping-actor diagram to distinguish business processing from exception recovery and strategy selection. section 5.1.2
