Class ClusterInteractionRequest
java.lang.Object
de.aristaflow.adept2.core.registry.cluster.ClusterInteractionRequest
Requests to the cluster heartbeat, that is, signals to the cluster database.
If this is a request to force the server on a different node to be lost, the
cluster name, node name and the running since time from the corresponding
server will be provided within the request.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumThe operations which can be requested to be performed by the cluster heartbeat. -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final StringThe name of the cluster if this is a force lost request for the server within this cluster,nullotherwise.protected final StringThe name of the server node if this is a force lost request,nullotherwise.protected final ClusterInteractionRequest.OperationThe operation which to perform by the cluster heartbeat.protected final longThe time since when the server node to be forcibly lost has been running since,Long.MIN_VALUEotherwise. -
Constructor Summary
ConstructorsConstructorDescriptionCreates a new request with the designated operation.ClusterInteractionRequest(String clusterName, String nodeName, long runningSince) Creates a new force lost request for the designated (different) server node. -
Method Summary
Modifier and TypeMethodDescriptionGets the name of the cluster if this is a force lost request for the server within this cluster,nullotherwise.Gets the name of the server node if this is a force lost request,nullotherwise.Gets the operation which to perform by the cluster heartbeat.longGets the time since when the server node to be forcibly lost has been running since,Long.MIN_VALUEotherwise.
-
Field Details
-
operation
The operation which to perform by the cluster heartbeat. -
clusterName
The name of the cluster if this is a force lost request for the server within this cluster,nullotherwise. -
nodeName
The name of the server node if this is a force lost request,nullotherwise. -
runningSince
protected final long runningSinceThe time since when the server node to be forcibly lost has been running since,Long.MIN_VALUEotherwise.
-
-
Constructor Details
-
ClusterInteractionRequest
Creates a new request with the designated operation.- Parameters:
operation- The operation which to perform by the cluster heartbeat.
-
ClusterInteractionRequest
Creates a new force lost request for the designated (different) server node.- Parameters:
clusterName- The name of the cluster of the server node to request a force lost of.nodeName- The name of the server node to request a force lost of.runningSince- The time since when the server node has been running.
-
-
Method Details
-
getOperation
Gets the operation which to perform by the cluster heartbeat.- Returns:
- The operation which to perform by the cluster heartbeat.
-
getClusterName
Gets the name of the cluster if this is a force lost request for the server within this cluster,nullotherwise.- Returns:
- The name of the cluster if this is a force lost request for the
server within this cluster,
nullotherwise.
-
getNodeName
Gets the name of the server node if this is a force lost request,nullotherwise.- Returns:
- The name of the server node if this is a force lost request,
nullotherwise.
-
getRunningSince
public long getRunningSince()Gets the time since when the server node to be forcibly lost has been running since,Long.MIN_VALUEotherwise.- Returns:
- The time since when the server node to be forcibly lost has been
running since,
Long.MIN_VALUEotherwise.
-