Use named parameters to Deploy, avoid strange path param
This commit is contained in:
parent
ab8a690c65
commit
a790f5bb32
2 changed files with 4 additions and 2 deletions
|
|
@ -178,7 +178,8 @@ private[akka] class ClusterRouteeProvider(
|
||||||
context.actorFor(RootActorPath(target) / settings.routeesPathElements)
|
context.actorFor(RootActorPath(target) / settings.routeesPathElements)
|
||||||
} else {
|
} else {
|
||||||
val name = "c" + childNameCounter.incrementAndGet
|
val name = "c" + childNameCounter.incrementAndGet
|
||||||
val deploy = Deploy("", ConfigFactory.empty(), routeeProps.routerConfig, RemoteScope(target))
|
val deploy = Deploy(config = ConfigFactory.empty(), routerConfig = routeeProps.routerConfig,
|
||||||
|
scope = RemoteScope(target))
|
||||||
context.asInstanceOf[ActorCell].attachChild(routeeProps.withDeploy(deploy), name, systemService = false)
|
context.asInstanceOf[ActorCell].attachChild(routeeProps.withDeploy(deploy), name, systemService = false)
|
||||||
}
|
}
|
||||||
// must register each one, since registered routees are used in selectDeploymentTarget
|
// must register each one, since registered routees are used in selectDeploymentTarget
|
||||||
|
|
|
||||||
|
|
@ -78,7 +78,8 @@ final class RemoteRouteeProvider(nodes: Iterable[Address], _context: ActorContex
|
||||||
override def createRoutees(nrOfInstances: Int): Unit = {
|
override def createRoutees(nrOfInstances: Int): Unit = {
|
||||||
val refs = IndexedSeq.fill(nrOfInstances) {
|
val refs = IndexedSeq.fill(nrOfInstances) {
|
||||||
val name = "c" + childNameCounter.incrementAndGet
|
val name = "c" + childNameCounter.incrementAndGet
|
||||||
val deploy = Deploy("", ConfigFactory.empty(), routeeProps.routerConfig, RemoteScope(nodeAddressIter.next))
|
val deploy = Deploy(config = ConfigFactory.empty(), routerConfig = routeeProps.routerConfig,
|
||||||
|
scope = RemoteScope(nodeAddressIter.next))
|
||||||
|
|
||||||
// attachChild means that the provider will treat this call as if possibly done out of the wrong
|
// attachChild means that the provider will treat this call as if possibly done out of the wrong
|
||||||
// context and use RepointableActorRef instead of LocalActorRef. Seems like a slightly sub-optimal
|
// context and use RepointableActorRef instead of LocalActorRef. Seems like a slightly sub-optimal
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue