Typically, you want to use what we call the "Commander" template for this. In fact, you have one subject with state ( Commander ), which is responsible for launching and monitoring the task. Then you process the actual work through the pool of actors and return them to Commander as they are completed. The commander can then track the progress of the task, calculating # completions / size of worker pool .
Thus, employees can be monitored and restarted independently, as they perform this work, but all the valuable states and information at the task level live in the Commander (this is called the "Error kernel model" )
You can see an example of this in the demo of Akka.NET's scalable web browser .
AndrewS
source share