Load Cluster extension from ClusterActorRefProvider, see #2704

This commit is contained in:
Patrik Nordwall 2012-12-04 17:54:17 +01:00
parent 86a85f8605
commit 1673ccd51c
5 changed files with 12 additions and 21 deletions

View file

@ -37,6 +37,10 @@ import akka.cluster.routing.MetricsSelector
/**
* INTERNAL API
*
* The `ClusterActorRefProvider` will load the [[akka.cluster.Cluster]]
* extension, i.e. the cluster will automatically be started when
* the `ClusterActorRefProvider` is used.
*/
class ClusterActorRefProvider(
_systemName: String,
@ -51,6 +55,9 @@ class ClusterActorRefProvider(
override def init(system: ActorSystemImpl): Unit = {
super.init(system)
// initialize/load the Cluster extension
Cluster(system)
remoteDeploymentWatcher = system.systemActorOf(Props[RemoteDeploymentWatcher], "RemoteDeploymentWatcher")
}