Added name of the listener actor in pi sample
This commit is contained in:
parent
43ec4c5895
commit
7201a7e24b
2 changed files with 2 additions and 2 deletions
|
|
@ -180,7 +180,7 @@ public class Pi {
|
||||||
ActorSystem system = ActorSystem.create("PiSystem");
|
ActorSystem system = ActorSystem.create("PiSystem");
|
||||||
|
|
||||||
// create the result listener, which will print the result and shutdown the system
|
// create the result listener, which will print the result and shutdown the system
|
||||||
final ActorRef listener = system.actorOf(new Props(Listener.class));
|
final ActorRef listener = system.actorOf(new Props(Listener.class), "listener");
|
||||||
|
|
||||||
// create the master
|
// create the master
|
||||||
ActorRef master = system.actorOf(new Props(new UntypedActorFactory() {
|
ActorRef master = system.actorOf(new Props(new UntypedActorFactory() {
|
||||||
|
|
|
||||||
|
|
@ -95,7 +95,7 @@ object Pi extends App {
|
||||||
val system = ActorSystem("PiSystem")
|
val system = ActorSystem("PiSystem")
|
||||||
|
|
||||||
// create the result listener, which will print the result and shutdown the system
|
// create the result listener, which will print the result and shutdown the system
|
||||||
val listener = system.actorOf(Props[Listener])
|
val listener = system.actorOf(Props[Listener], name = "listener")
|
||||||
|
|
||||||
// create the master
|
// create the master
|
||||||
val master = system.actorOf(Props(new Master(
|
val master = system.actorOf(Props(new Master(
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue