* Termination hook mechanism in system guardian to be able to
notify RemoteSystemDaemon and wait for it to terminate children
* Stopping the children will trigger ordinary death watch mechanism,
in for example routers
* Note bug in RemoteSystemDaemon, watch of children was not done
properly, which might have been a memory leak for remote deployed
actors.
* When Watch is sent to deadLetters it will generate Terminated
* Test: receive Terminated when watched node is unknown host
* Test: receive Terminated when watched path doesn't exist
* Introduced RouterContext which is a subset of
ActorContext that makes sense for RouteeProvider
to use.
* It's not possible (without major rethinking) to
create routees by sending message to the Router
actor because we rely on immediate return of ActorRef
* Config max-nr-of-instances-per-node
* selectDeploymentTarget that takes max-nr-of-instances-per-node
and nr-of-instances into account
* Deploy when new member added or removed
* Moved routeeProps to RouteeProvider constructor, needed for
this feature, but also simplifies createRoute, createRoutee,
and resize, since routeeProps doesn't have to be passed around.
* createRoutees only for new nrOfInstances
* createRoutees also registers
* New registerRouteesFor for path lookup
* removeRoutees to gracefully unregister and stop routee
* Use withFallback to use Resizer specified in code if not configured
* Use withFallback in RemoteRouterConfig also
* Fix bug of child name in RemoteRouteeProvider
- it was always intended that tell() (and sendSystemMessage()) shall not
throw any exceptions
- this is implemented by swallowing in ActorCell
(suspend/resume/restart/stop/!/sendSystemMessage) and in
RemoteActorRef (!/sendSystemMessage)
- current implementation uses a normal method, which adds overhead but
keeps the code in one place (ActorCell.catchingSend); this is a great
opportunity for making use of macros
This has brought to light some interesting effects (aka bugs) both in
the general implementation as well as in previous fixes.
SupervisorHierarchySpec is without TODOs now and GREEN.
- always suspend/resume for Suspend/Resume/Recreate, no matter which
state the actor is in, to keep the counter balanced
- preRestart failures are logged but otherwise ignored; there’s nothing
else (apart from terminating the actor) which we could do at that
point
- preRestart/postRestart exceptions have their own distinguishable
subtype of ActorKilledException now
- fix some race conditions in tests to make them produce fewer false
failures
- remove cruft from SupervisorStrategy and add methods which can
actually be used to implement your own (with proper warning signs)