Re: [akka-user] Re: deserializing ActorRef's after jvm restart, will it point to the correct actor?

2015-11-10 Thread Guido Medina
Ah, in a way the code I sent before is for a set of Actor systems connected between them all belonging to the same cluster, I'm not sure how Akka Cluster will perform with 1000 nodes, why so many nodes? Answering your question if a node leaves the cluster under any circumstances an event is

Re: [akka-user] Re: deserializing ActorRef's after jvm restart, will it point to the correct actor?

2015-11-10 Thread Guido Medina
Each server is subscribed to cluster events and each event is received by the supervisor of that server; when I say server think a micro-service and when I say supervisor think a supervisor for the category of that micro-service like Account supervisor or Order supervisor, etc, each server

Re: [akka-user] Re: deserializing ActorRef's after jvm restart, will it point to the correct actor?

2015-11-09 Thread Guido Medina
Hi Kostas, I have few micro-services and some supervisor actors which inherited from an AbstractSupervisor template which uses local caches per microservices with an optimistic approach, example with requirements: 1) There is a uniform pattern where each micro-service is an independent

Re: [akka-user] Re: deserializing ActorRef's after jvm restart, will it point to the correct actor?

2015-11-06 Thread 'Konstantinos Kougios' via Akka User List
This will be helpful. Is there any performance penalty compared to actorRef.tell ? If I cache ActorSelection (for say 10 secs) will it be better in terms of performance and also will avoid the server-restart issue? I see it has internally an anchor actorref, so it might be better On 06/11/15

Re: [akka-user] Re: deserializing ActorRef's after jvm restart, will it point to the correct actor?

2015-11-06 Thread Kostas kougios
Well, I refactored my code to cache actorpaths but indeed during creation all actorpaths are local and when they are transmitted over the wire they remain local => pointing to the wrong path. I've manually modified the address part of the path myself so that it contains the host & port of the

Re: [akka-user] Re: deserializing ActorRef's after jvm restart, will it point to the correct actor?

2015-11-06 Thread Kostas kougios
Ok so basically I am going to change my code and serialize endpoints (as strings) and then use a resolveOne(..) cache (probably cache refs for a short time of a few seconds) unless someone can recommend a better way. -- >> Read the docs: http://akka.io/docs/ >> Check

Re: [akka-user] Re: deserializing ActorRef's after jvm restart, will it point to the correct actor?

2015-11-06 Thread 'Konstantinos Kougios' via Akka User List
Thanks Martynas, I was afraid that this was the case. I would prefer to view actor paths as i.e. endpoints of a service, same path same service. I might serialize thousands of actorrefs and I suppose actorSelection for all those will take time as it requires network communication. So it is

Re: [akka-user] Re: deserializing ActorRef's after jvm restart, will it point to the correct actor?

2015-11-06 Thread Martynas Mickevičius
You can send messages to ActorSelection without resolving them to ActorRefs. ActorSelection has ! and tell methods. On Fri, Nov 6, 2015 at 2:30 PM, Kostas kougios < kostas.koug...@googlemail.com> wrote: > Ok so basically I

Re: [akka-user] Re: deserializing ActorRef's after jvm restart, will it point to the correct actor?

2015-11-06 Thread Kostas kougios
hmm, I think actor paths will always be local during the time of the actor creation (all actors are created locally and then send over the wire). actor.path.address has a host & port of None, so there is no point sending that over the wire. The address part of the path won't automatically be

Re: [akka-user] Re: deserializing ActorRef's after jvm restart, will it point to the correct actor?

2015-11-05 Thread Martynas Mickevičius
Hi Kostas, serialized ActorRef contain UID which indicates an incarnation of particular actor. res8: akka.actor.ActorRef = Actor[akka://repl/user/$a#1452319393] When you restart your actor system newly created actors have

[akka-user] Re: deserializing ActorRef's after jvm restart, will it point to the correct actor?

2015-11-05 Thread Kostas kougios
I could ofcourse do an actorSelection but is there an easier way? -- >> Read the docs: http://akka.io/docs/ >> Check the FAQ: >> http://doc.akka.io/docs/akka/current/additional/faq.html >> Search the archives: