... and there is s SingletonProxy that you can use from the the Play frontend 
nodes.

/Patrik

> 8 maj 2015 kl. 17:29 skrev Akka Team <[email protected]>:
> 
> Hi Ugo,
> 
> Have you looked at the Cluster Singleton module? 
> http://doc.akka.io/docs/akka/2.3.10/contrib/cluster-singleton.html
> 
> It solves this issue and also migration of the singleton on failures. I think 
> you are better of using that module than trying to roll your own.
> 
> -Endre
> 
>> On Fri, May 8, 2015 at 4:14 PM, Ugo Matrangolo <[email protected]> 
>> wrote:
>> Hi,
>> 
>> started to play with Akka remoting and I hit a problem with singleton actors.
>> 
>> I have a 3 nodes Akka cluster with a singleton actor running somewhere under 
>> the /user/root/singleton path. 
>> 
>> I would like to send a message to this actor from any node in the cluster 
>> triggered by someone hitting a Play Controller endpoint.
>> 
>> AFAIK, what I need to do is to get the ActorRef using:
>> 
>>   
>> actorSystem.actorSelection("akka.tcp://mySystem@node1:2551/user/root/singleton")
>> 
>> What I don't like is that I need to know *where* the singleton actor is 
>> running (e.g. node1:2551). 
>> 
>> Is there a way to broadcast a query like "Are you there?" to all nodes 
>> having the singleton actor respond with an Identify ??
>> 
>> What I'm trying to achieve is something like:
>> 
>>    
>> actorSystem.actorSelection("akka.tcp://mySystem/user/root/singleton").mapTo[ActorRef]
>>  ! Hello
>> 
>> with Akka figuring out where the singleton is.
>> 
>> Not sure if is possible but worth asking :)
>> 
>> Best,
>> Ugo
>>  
>> -- 
>> >>>>>>>>>> Read the docs: http://akka.io/docs/
>> >>>>>>>>>> Check the FAQ: 
>> >>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>> >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "Akka User List" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected].
>> To post to this group, send email to [email protected].
>> Visit this group at http://groups.google.com/group/akka-user.
>> For more options, visit https://groups.google.com/d/optout.
> 
> 
> 
> -- 
> Akka Team
> Typesafe - Reactive apps on the JVM
> Blog: letitcrash.com
> Twitter: @akkateam
> -- 
> >>>>>>>>>> Read the docs: http://akka.io/docs/
> >>>>>>>>>> Check the FAQ: 
> >>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
> >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user
> --- 
> You received this message because you are subscribed to the Google Groups 
> "Akka User List" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at http://groups.google.com/group/akka-user.
> For more options, visit https://groups.google.com/d/optout.

-- 
>>>>>>>>>>      Read the docs: http://akka.io/docs/
>>>>>>>>>>      Check the FAQ: 
>>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>>>>>>>>>      Search the archives: https://groups.google.com/group/akka-user
--- 
You received this message because you are subscribed to the Google Groups "Akka 
User List" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to