Thanks mate. That makes it clear. Have a nice weekend too. Martin On Aug 17, 2014 12:34 AM, "Konrad Malawski" <[email protected]> wrote:
> Hello Martin, > Yes, there needs to be exactly one actor which performs writes for a given > persistenceId in the system (though using *ClusterSharding* > <http://doc.akka.io/docs/akka/2.3.4/contrib/cluster-sharding.html> you > can easily migrate it between servers etc). > Other "read actors" should be PersistentViews. The reason for this > requirement is that we need to ensure ordering guarantees between between > the stored events. > > You can have as many PersistentActors "of the same type" as you want in > the system, but by that I understand the "type" (as in "class"). > The persistenceId of these must be different. > > Hope this helps, have a great weekend! > > > On Sat, Aug 16, 2014 at 6:44 PM, Martin Jöhren <[email protected]> > wrote: > >> Just to be sure: that means having something like a singleton actor which >> persists the events in the cluster? And several others as views to deliver >> read requests? >> What if I want to have multiple persistent actors of the same type based >> on resilient reasons? >> >> On Aug 15, 2014 1:14 PM, "Patrik Nordwall" <[email protected]> >> wrote: >> >>> Hi Martin, >>> >>> >>> On Fri, Aug 15, 2014 at 10:39 AM, Martin Jöhren <[email protected]> >>> wrote: >>> >>>> Hi, >>>> >>>> I have a question to a distributed EventSource system: >>>> >>>> Let's say I have a fixed number of nodes (3) because I want to balance >>>> load. Each node has a persistent actor which should write to cassandra the >>>> events which have been created and update their inner state afterwards. Now >>>> I'm asking myself what is the best approach to inform the other nodes about >>>> that change because they also need to know the state change? >>>> >>>> * use the distributed pub sub (and therefore create a cluster)? >>>> * use remote actors to directly inform the other nodes about the change? >>>> * other solution? >>>> >>> >>> It is probably easiest to replicate the events with PersistentView >>> <http://doc.akka.io/docs/akka/2.3.5/scala/persistence.html#Persistent_Views> >>> . >>> >>> The other approaches can also work, but be aware of: >>> - messages can be lost >>> - when a node is started it might need to get the initial state from the >>> other nodes >>> >>> Regards, >>> Patrik >>> >>> >>> >>>> Thanks and best regards >>>> >>>> Martin >>>> >>>> -- >>>> >>>>>>>>>> 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. >>>> >>> >>> >>> >>> -- >>> >>> Patrik Nordwall >>> Typesafe <http://typesafe.com/> - Reactive apps on the JVM >>> Twitter: @patriknw >>> >>> -- >>> >>>>>>>>>> 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 a topic in the >>> Google Groups "Akka User List" group. >>> To unsubscribe from this topic, visit >>> https://groups.google.com/d/topic/akka-user/4PF6oF_l9eY/unsubscribe. >>> To unsubscribe from this group and all its topics, 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. >> > > > > -- > Cheers, > Konrad 'ktoso' Malawski > hAkker @ Typesafe > > <http://typesafe.com> > > -- > >>>>>>>>>> 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 a topic in the > Google Groups "Akka User List" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/akka-user/4PF6oF_l9eY/unsubscribe. > To unsubscribe from this group and all its topics, 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.
