Hook function for handling a custom message from classes that extends ClusterListener
Hook function for handling a custom message from classes that extends ClusterListener
the message received of type ClusterListenerMessage
Hook function to perform a custom action when a member is removed from cluster
Hook function to perform a custom action when a member is removed from cluster
address of the node
Hook function to perform a custom action when a new member is up in cluster
Hook function to perform a custom action when a new member is up in cluster
address of the node
Hook function to perform a custom action when a member in the cluster becomes unreachable
Hook function to perform a custom action when a member in the cluster becomes unreachable
address of the node
Overriding of the postStop method of Actor.
Overriding of the postStop method of Actor. When he is stopped he unsubscribes itself from cluster.
Overriding of the preStart method of Actor.
Overriding of the preStart method of Actor. When created this actor subscribes itself to cluster. It also adds the address of his node to his list.
Receive method of the actor.
Receive method of the actor. This method receives gossip from cluster and the string "next". A "next" message is a request for an address given by nextAddress method. The messages from the cluster is used to keep updated the list of node addresses and the number of nodes.
Trait actor responsible of keeping the addresses of the nodes marked as UP in the cluster. There should be at least one ClusterListener actor on every node of the cluster. This actor is designed to be extended by actors who needs to know about what is happening in the cluster