Added lookup method in Dispatchers to provide a registry of configured dispatchers to be shared between actors. See #1458
This commit is contained in:
parent
03e731e098
commit
eede488fd3
6 changed files with 57 additions and 20 deletions
|
|
@ -73,7 +73,7 @@ public class UntypedActorTestBase {
|
|||
public void propsActorOf() {
|
||||
ActorSystem system = ActorSystem.create("MySystem");
|
||||
//#creating-props
|
||||
MessageDispatcher dispatcher = system.dispatcherFactory().newFromConfig("my-dispatcher");
|
||||
MessageDispatcher dispatcher = system.dispatcherFactory().lookup("my-dispatcher");
|
||||
ActorRef myActor = system.actorOf(new Props().withCreator(MyUntypedActor.class).withDispatcher(dispatcher),
|
||||
"myactor");
|
||||
//#creating-props
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue