* because it is not referentially transparent; normally we reserved parens for
side-effecting code but given how people thoughtlessly close over it we revised
that that decision for sender
* caller can still omit parens
* Separate routing logic, to be usable stand alone, e.g. in actors
* Simplify RouterConfig, only a factory
* Move reading of config from Deployer to the RouterConfig
* Distiction between Pool and Group router types
* Remove usage of actorFor, use ActorSelection
* Management messages to add and remove routees
* Simplify the internals of RoutedActorCell & co
* Move resize specific code to separate RoutedActorCell subclass
* Change resizer api to only return capacity change
* Resizer only allowed together with Pool
* Re-implement all routers, and keep old api during deprecation phase
* Replace ClusterRouterConfig, deprecation
* Rewrite documentation
* Migration guide
* Also includes related ticket:
+act #3087 Create nicer Props factories for RouterConfig
- introducing RepointableActorRef, which starts out with an
UnstartedActorCell which can cheaply be created; the Supervise()
message will trigger child.activate() in the supervisor, which means
that the actual creation (now with normal ActorCell) happens exactly
in the right place and with the right semantics. Messages which were
enqueued to the dummy cell are transferred atomically into the
ActorCell (using normal .tell()), so message sends keep working
exactly as they used to
- this enables getting rid of the brittle synchronization around
RoutedActorRef by replacing that one with a RepointableActorRef
subclass which creates RoutedActorCells upon activate(), with the nice
benefit that there is no hurry then to get it right because the new
cell is constructed “on the side”
misc fixes:
- InvalidMessageException is now actually enforced when trying to send
“null”
- Mailboxes may be created without having an ActorCell, which can come
in handy later, because the cell is only needed when this mailbox is
going to be scheduled on some executor
- remove occurrences of Props(), which is equivalent to Props[Nothing],
which is equivalent to «bug»
- add test case which verifies that context.actorOf is still synchronous
- plus all the stuff I have forgotten.
- add Deploy to Props, which is used as the basis (overridden by
configuration)
- utilize general mechanism .withFallback (introduced on Deploy,
RouterConfig and Scope)
- actually pass Props over the wire when deploying remotely in order to
retain settings (this was an oversight before)
- write tests for the new functionality
- replace ActorRef.stop() by ActorRefFactory.stop(child) everywhere
- ActorCell “optimizes” this to remove the child from its childrenRefs
in order to allow immediate recycling of the name
- the lost soul must have a place, for which the Locker has been
created, where Davy Jones will happily rebind the soul to his ship
(i.e. set “parent” to the locker to avoid mem leak) and periodically
revisit it (.stop(), in case of that being lost in comm failure,
similar .watch() to re-check liveness)
- pull some more generic stuff out of the individual routers, add
factories which take only target lists
- add router parsing to Deployer, removing everything which is not
strictly related to local scope, which left only few things, so move
them to Deployer.scala and delete DeploymentConfig
- fix ConfiguredLocalRoutingSpec to use the new configuration mechanism
and verify that configuration overrides code
- fix DeployerSpec by using (mostly) correct lookup paths and removing
everything which was not local
- change config file layout, removing everything which is not local from
akka-actor/.../reference.conf, putting the remote stuff into the
akka-remote/.../reference.conf (unused as of yet); adapt comments
according to changed functionality
* Added JavaActorContext, UntypedActor.getContext
* implicit val context in Actor needs to be implicit to support forward,
it would be nice if it wasn't implicit because now I can't override context
in UntypedActor
* Removed implicit def system in Actor
* Removed implicit def defaultTimeout in Actor
* Removed receiveTimeout, children, dispatcher, become, unbecome, watch,
unwatch in Actor
* Removed corresponding as above from UntypedActor
* Removed implicit from dispatcher in ActorSystem
* Removed implicit def timeout in TypedActor
* Changed receiveTimeout to use Duration (in api)
* Changed many tests and samples to match new api
- create ActorSystemImpl trait to make ActorSystem fully abstract
- add Java API for constructing (ActorSystem.create(...))
- only go through factory methods because .start() has become necessary
- rename all user-facing occurrences of “app” to “system” (Actor trait
and TestKit/AkkaSpec)
- pass ActorSystemImpl to ActorRefs upon creation, which means that
actorOf() and friends need such an argument, which must be provided to
the ActorRefProvider by the ActorRefFactory implementation