public class ClusterNode extends Object implements Serializable
Constructor and Description |
---|
ClusterNode()
Instantiates a new Cluster node.
|
Modifier and Type | Method and Description |
---|---|
double |
getCpuLoad()
Retrieves the cpu load.
|
String |
getInternalHostAddress()
Retrieves the internal host address which uses the HTTP/HTTPS protocol for communications between clients and the context server.
|
double[] |
getLoadAverage()
Retrieves the load average for the last minute, five minutes and fifteen minutes.
|
String |
getPublicHostAddress()
Retrieves the public host address.
|
long |
getUptime()
Retrieves the uptime.
|
boolean |
isData()
Determines whether this ClusterNode locally stores data.
|
boolean |
isMaster()
Determines whether this ClusterNode is a master node, i.e.
|
void |
setCpuLoad(double cpuLoad)
Sets the cpu load.
|
void |
setData(boolean data)
Specifies whether this ClusterNode locally stores data.
|
void |
setInternalHostAddress(String internalHostAddress)
Sets the internal host address which uses the HTTP/HTTPS protocol for communications between clients and the context server.
|
void |
setLoadAverage(double[] loadAverage)
Sets the load average for the last minute, five minutes and fifteen minutes.
|
void |
setMaster(boolean master)
Specifies whether this ClusterNode is a master node, i.e.
|
void |
setPublicHostAddress(String publicHostAddress)
Sets the public host address.
|
void |
setUptime(long uptime)
Sets the uptime.
|
public double getCpuLoad()
public void setCpuLoad(double cpuLoad)
cpuLoad
- the cpu loadpublic String getPublicHostAddress()
public void setPublicHostAddress(String publicHostAddress)
publicHostAddress
- the public host addresspublic String getInternalHostAddress()
public void setInternalHostAddress(String internalHostAddress)
internalHostAddress
- the internal host addresspublic double[] getLoadAverage()
double
containing, in order and starting from index 0
, the load average for the last minute, last five minutes and last fifteen minutespublic void setLoadAverage(double[] loadAverage)
loadAverage
- an array of double
containing, in order and starting from index 0
, the load average for the last minute, last five minutes and last fifteen minutespublic long getUptime()
public void setUptime(long uptime)
uptime
- the uptimepublic boolean isMaster()
true
if this node is a master node, false
otherwisepublic void setMaster(boolean master)
master
- true
if this node is a master node, false
otherwisepublic boolean isData()
true
if this node locally stores data, false
otherwisepublic void setData(boolean data)
data
- true
if this node locally stores data, false
otherwiseCopyright © 2014–2023 Apache Software Foundation. All rights reserved.