Actor lifecycle monitoring

Akka provides a mechanism to monitor the lifecycle of an actor. An actor is automatically the supervisor for all its children and manages their error conditions. Monitoring provides the ability to monitor the health of any actor other than its own children so that you can manage the impact on your own processing logic. Monitoring is observation of error, while supervision is management of error.

For example, if the Monitor actor wants to be notified of another actor's (worker) termination, the Monitor actor will watch for the reception of the terminated message dispatched by the worker actor upon termination. When the message is received, the Monitor actor can take appropriate action (including trying to instantiate and ...

Get Akka Essentials now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.