Created
November 25, 2015 13:21
-
-
Save toff63/3a4f7c362c9c802884be to your computer and use it in GitHub Desktop.
List of Running Actors
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class RunningActors extends Actor with ActorLogging { | |
def receive = { | |
case "start" => | |
log.info("Current Actors in system:") | |
self ! ActorPath.fromString("akka://Streams/user/") | |
case path: ActorPath => | |
context.actorSelection(path / "*") ! Identify(()) | |
case ActorIdentity(_, Some(ref)) => | |
log.info(ref.toString()) | |
self ! ref.path | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment