The node role from the akka cluster perspective, imagine you have nodes of type, "order-processor" or "price-processor" or whatever. So each time a node of a role comes up you can do something in the nodes that have such role.
In cases of split brain you will have a master node for a role on each side, but one cluster needs to die which is a different problem. *Note:* I was thinking all this time I was commenting in the other thread (the one you commented before creating this one), what I'm saying here is not related to the thread, sorry. Guido. On Thursday, April 14, 2016 at 2:11:50 PM UTC+1, Paul Cleary wrote: > > I am not sure I follow the "role-X" takes over. > > For my purposes (and probably in many cases) it is a bad thing to have a > split brain because I am using cluster sharding. I really want the > less-than-quorum split brain to actually leave the cluster. > > I haven't thought much about what it means to "leave the cluster". > Probably should have it go into some kind of passive state where we can > manually / programmatically join the "correct" (aka good side of the split > brain). > > Honestly, no idea how that side should be done. > > Step one would be just to shut down the node. > > Step two would be more graceful, of removing itself from the current > cluster, and figuring out how to join to the good cluster. > > On Thursday, April 14, 2016 at 6:07:41 AM UTC-4, Guido Medina wrote: >> >> It might be also possible to use some sort of promotion algorithm, say, >> last in of a "role-X" takes over, the old know will see it and demote >> itself. >> All you need to do that is have one actor per node subscribed to cluster >> events, that;s how I do my promotion of active-passive nodes and it works >> like a charm. >> Also you need to agree in some sort of decentralized sorting criteria, >> for that I use current time in millis + node address to make sorting of >> nodes consistent among all other nodes. >> >> That way they don't need to query anyone to know who is the current >> active node for an specific task. >> >> Hope that helps, >> >> Guido. >> >> On Tuesday, April 12, 2016 at 3:52:14 PM UTC+1, Paul Cleary wrote: >>> >>> Thanks, yea, guess it makes sense to have each member auto-down >>> themselves... >>> >>> "If my cluster doesn't reach quorum size, then stop me" >>>> >>>> -- >>>>>>>>>> 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 https://groups.google.com/group/akka-user. For more options, visit https://groups.google.com/d/optout.
