What's the best way to get members of an Akka cluster? -


if have akka cluster, best way access list of members of cluster?

i can listen events , manage own registry on each node in cluster. can use cluster(system).state according docs isn't in-sync published events. 1 of these preferred/better?

my use case this:

i have cluster of various services (different roles). when need service of particular role i'd filter on list of nodes in cluster nodes having role need, randomly select 1 of these communicate with. that's why want list of nodes in cluster.

is best way achieve use case?

members of cluster available through jmx if activated. guess can write small piece of code access mbean server , retrieve information there.

also, there additional information in jmx object useful such unreachable nodes.


Comments

Popular posts from this blog

javascript - gulp-nodemon - nodejs restart after file change - Error: listen EADDRINUSE events.js:85 -

Fatal Python error: Py_Initialize: unable to load the file system codec. ImportError: No module named 'encodings' -

javascript - oscilloscope of speaker input stops rendering after a few seconds -