implement coherent actorFor look-up
- look-up of all actor paths in the system, even “synthetic” ones like “/temp” - look-up by full URI (akka://bla/...), absolute or relative path - look-up by ActorPath - look-up by path elements - look-up relative to context where applicable, supporting ".." - proper management of AskActorRef Have a look at ActorLookupSpec to see what it can do.
This commit is contained in:
parent
a3e6fca530
commit
79e5c5d0d1
10 changed files with 406 additions and 37 deletions
|
|
@ -39,6 +39,7 @@ class RemoteActorRefProvider(
|
|||
val log = Logging(eventStream, "RemoteActorRefProvider")
|
||||
|
||||
def deathWatch = local.deathWatch
|
||||
def rootGuardian = local.rootGuardian
|
||||
def guardian = local.guardian
|
||||
def systemGuardian = local.systemGuardian
|
||||
def nodename = remoteExtension.NodeName
|
||||
|
|
@ -181,8 +182,8 @@ class RemoteActorRefProvider(
|
|||
}
|
||||
|
||||
def actorFor(path: ActorPath): InternalActorRef = local.actorFor(path)
|
||||
def actorFor(path: String): InternalActorRef = local.actorFor(path)
|
||||
def actorFor(path: Iterable[String]): InternalActorRef = local.actorFor(path)
|
||||
def actorFor(ref: InternalActorRef, path: String): InternalActorRef = local.actorFor(ref, path)
|
||||
def actorFor(ref: InternalActorRef, path: Iterable[String]): InternalActorRef = local.actorFor(ref, path)
|
||||
|
||||
// TODO remove me
|
||||
val optimizeLocal = new AtomicBoolean(true)
|
||||
|
|
@ -267,13 +268,13 @@ private[akka] case class RemoteActorRef private[akka] (
|
|||
loader: Option[ClassLoader])
|
||||
extends InternalActorRef {
|
||||
|
||||
// FIXME
|
||||
def getParent = Nobody
|
||||
def getChild(name: Iterable[String]) = Nobody
|
||||
|
||||
@volatile
|
||||
private var running: Boolean = true
|
||||
|
||||
def name = path.name
|
||||
|
||||
def address = remoteAddress + path.toString
|
||||
|
||||
def isTerminated: Boolean = !running
|
||||
|
||||
def sendSystemMessage(message: SystemMessage): Unit = throw new UnsupportedOperationException("Not supported for RemoteActorRef")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue