|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface DsoClusterListener
A listener interface that can be implemented to be notified about DSO cluster events.
Listeners can be registered through the addClusterListener
method and removed through the removeClusterListener
method of a DsoCluster
instance.
The ordering and the timing of the events isn't guaranteed across the cluster. It is however guaranteed that the events can only appear in the following succession on each individual node:
The node joined
and node left
events are sent to all the nodes in the cluster and happen once for the
lifetime of a node.
The operations enabled
and operations disabled
events are repeatable and indicate temporary
situations that may resolve themselves automatically over time. Only the current node will receive events concerning
its own cluster operations. Nodes in the cluster don't get cluster operation events about other nodes.
Method Summary | |
---|---|
void |
nodeJoined(DsoClusterEvent event)
Sent when a node joined the cluster, including the current node. |
void |
nodeLeft(DsoClusterEvent event)
Sent when a node left the cluster, including the current node. |
void |
operationsDisabled(DsoClusterEvent event)
Sent when cluster operations are disabled on a node, no cluster operations can go through. |
void |
operationsEnabled(DsoClusterEvent event)
Sent when cluster operations are enabled on a node, any operations will go through and propagate through the cluster. |
Method Detail |
---|
void nodeJoined(DsoClusterEvent event)
This event happens once for the lifetime of a node.
event
- provides more information about the eventDsoCluster.isNodeJoined()
void nodeLeft(DsoClusterEvent event)
This event happens once for the lifetime of a node.
Note that this event might never be triggered for the node in question, other nodes in the cluster will however always receive this event about nodes that have permanently left the cluster.
event
- provides more information about the eventDsoCluster.isNodeJoined()
void operationsEnabled(DsoClusterEvent event)
This event can be repeated as many times as appropriate, but you're guaranteed to have always received a node left
or operations disabled
event before.
Only the current node will receive events concerning its own cluster operations.
event
- provides more information about the eventDsoCluster.areOperationsEnabled()
void operationsDisabled(DsoClusterEvent event)
They might propagate through the cluster if the operations are enabled again afterwards, however it's also possible that the nodes is forced to leave the cluster instead.
This event can be repeated as many times as appropriate, but you're guaranteed to have always received an operations enabled
event before.
Only the current node will receive events concerning its own cluster operations.
event
- provides more information about the eventDsoCluster.areOperationsEnabled()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |