Send command to DOWN the node specified by 'address'.
Returns true if this cluster instance has be shutdown.
Try to join this cluster node with the node specified by 'address'.
Try to join this cluster node with the node specified by 'address'. A 'Join(thisNodeAddress)' command is sent to the node to join.
Send command to issue state transition to LEAVING for the node specified by 'address'.
Publish current (full) state of the cluster to subscribers, that are subscribing to akka.cluster.ClusterEvent.ClusterDomainEvent or akka.cluster.ClusterEvent.CurrentClusterState.
Publish current (full) state of the cluster to subscribers, that are subscribing to akka.cluster.ClusterEvent.ClusterDomainEvent or akka.cluster.ClusterEvent.CurrentClusterState. If you want this to happen periodically you need to schedule a call to this method yourself.
Java API: The supplied callback will be run, once, when current cluster member is Up
.
Java API: The supplied callback will be run, once, when current cluster member is Up
.
Typically used together with configuration option akka.cluster.min-nr-of-members'
to defer some action, such as starting actors, until the cluster has reached
a certain size.
The supplied thunk will be run, once, when current cluster member is Up
.
The supplied thunk will be run, once, when current cluster member is Up
.
Typically used together with configuration option akka.cluster.min-nr-of-members'
to defer some action, such as starting actors, until the cluster has reached
a certain size.
Publish current (full) state of the cluster to the specified receiver.
Publish current (full) state of the cluster to the specified receiver. If you want this to happen periodically you need to schedule a call to this method yourself.
Subscribe to cluster domain events.
Subscribe to cluster domain events.
The to
Class can be akka.cluster.ClusterEvent.ClusterDomainEvent
or subclass.
A snapshot of akka.cluster.ClusterEvent.CurrentClusterState
will be sent to the subscriber as the first event. When
to
Class is a akka.cluster.ClusterEvent.InstantMemberEvent
(or subclass) the snapshot event will instead be a
akka.cluster.ClusterEvent.InstantClusterState.
Unsubscribe to a specific type of cluster domain events,
matching previous subscribe
registration.
Unsubscribe to all cluster domain events.
This module is responsible for Gossiping cluster information. The abstraction maintains the list of live and dead members. Periodically i.e. every 1 second this module chooses a random member and initiates a round of Gossip with it.
During each round of gossip exchange it sends Gossip to random node with newer or older state information, if any, based on the current gossip overview, with some probability. Otherwise Gossip to any random live node.
Example:
if (Cluster(system).isLeader) { ... }