O'Reilly logo

Actors in Scala by Frank Sommers, Philipp Haller

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

6.2 Monitoring actors

There are several scenarios in which you need to monitor the life cycle of a group of actors. In particular, you can significantly simplify error handling and fault tolerance in a concurrent system through monitoring. Here are some examples:

  • Scenario A. We want to be notified when an actor terminates normally or abnormally. For instance, we might want to replace an actor that terminated because of an unhandled exception. Or we might want to rethrow the exception in a different actor that can handle it.
  • Scenario B. We want to express that an actor depends on some other actor in the sense that the former cannot function without the latter. For instance, in a typical master-slave architecture the work that a slave does is ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required