ClusterSingletonManagerSpec must not use 'node' from other thread, see #3382

* Thank you @rkuhn for finding the reason for the problem
* Sprinkled some warnings
This commit is contained in:
Patrik Nordwall 2013-05-24 14:43:01 +02:00
parent beed693c1b
commit 716893263a
3 changed files with 22 additions and 2 deletions

View file

@ -195,8 +195,11 @@ class ClusterSingletonManagerSpec extends MultiNodeSpec(ClusterSingletonManagerS
val identifyProbe = TestProbe()
val controllerRootActorPath = node(controller)
def queue: ActorRef = {
system.actorSelection(node(controller) / "user" / "queue").tell(Identify("queue"), identifyProbe.ref)
// this is used from inside actor construction, i.e. other thread, and must therefore not call `node(controller`
system.actorSelection(controllerRootActorPath / "user" / "queue").tell(Identify("queue"), identifyProbe.ref)
identifyProbe.expectMsgType[ActorIdentity].ref.get
}