|
Dashboard Builder Commons 6.2.0.Beta2 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jboss.dashboard.cluster.ClusterNodesManager
@ApplicationScoped public class ClusterNodesManager
A platform component that manages the nodes connected to the cluster, if any. NOTE: BZ-1014612
| Field Summary | |
|---|---|
static org.slf4j.Logger |
log
|
| Constructor Summary | |
|---|---|
ClusterNodesManager()
|
|
| Method Summary | |
|---|---|
void |
deregister(Long nodeId)
Deregister the node from the table. |
Long |
getCurrentNodeId()
|
String |
getCurrentNodeIpAddress()
|
protected String |
getIPAddress()
Return the IP address for the default interface. |
ClusterNode |
getNodeById(Long id)
Returns a cluster node instance for a given identifier. |
ClusterNode |
getNodeByIpAddress(String ip)
Returns a cluster node instance for a given IP address. |
List<ClusterNode> |
getNodeByStatus(ClusterNode.ClusterNodeStatus status)
Returns a cluster node/s instance for a given status. |
Priority |
getPriority()
Use highest priority to register the nodes and their statuses as quick as possible on startup. |
void |
setCurrentNodeStatus(ClusterNode.ClusterNodeStatus newStatus)
Sets a status for current node. |
void |
setNodeStatus(Long nodeId,
ClusterNode.ClusterNodeStatus newStatus)
Sets a status for a node. |
boolean |
shouldInstallModules()
Check if another node is currently installing initial modules. |
void |
start()
Register the node into the table. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static transient org.slf4j.Logger log
| Constructor Detail |
|---|
public ClusterNodesManager()
| Method Detail |
|---|
public Priority getPriority()
HibernateInitializer in order to have a valid Hibernate session.
getPriority in interface Startable
public void start()
throws Exception
start in interface StartableException - Error registering node.
public void deregister(Long nodeId)
throws Exception
Exception - Error deregistering node.
public List<ClusterNode> getNodeByStatus(ClusterNode.ClusterNodeStatus status)
throws Exception
status - The status for the node.
null if there is no match.
Exception - Error searching for a cluster node by status.
public ClusterNode getNodeById(Long id)
throws Exception
id - The identifier for the node.
null if there is no match.
Exception - Error searching for a cluster node by identifier.
public ClusterNode getNodeByIpAddress(String ip)
throws Exception
ip - The ip address for the node.
null if there is no match.
Exception - Error searching for a cluster node by ip address.
protected String getIPAddress()
throws SocketException
SocketException - Error reading socket.
public void setNodeStatus(Long nodeId,
ClusterNode.ClusterNodeStatus newStatus)
throws Exception
nodeId - The node identifier.newStatus - The new status to set.
Exception
public boolean shouldInstallModules()
throws Exception
Exception
public void setCurrentNodeStatus(ClusterNode.ClusterNodeStatus newStatus)
throws Exception
newStatus - The new status to set.
Exceptionpublic Long getCurrentNodeId()
public String getCurrentNodeIpAddress()
|
Dashboard Builder Commons 6.2.0.Beta2 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||