Reputation: 4621
I would like to learn whether it is possible to get or listen running applications "number" which are running on the pool IP that hazelcast is configured (distributed) for.
I am aware of the application logs that shows which ip is get in the pool right that moment or leave the pool (when that server is down). However, I could not find how to get this running instance numbers at runtime with hazelcast.
Thanks in advance.
Upvotes: 0
Views: 505
Reputation: 2345
Hazelcast.getCluster().getMembers()
will give you the list of members. You can also addListener to listen the membership events via
Hazelcast.getCluster().addMembershipListener()
Upvotes: 5