Package org.jppf.management
Class JPPFManagementInfo
java.lang.Object
org.jppf.management.JPPFManagementInfo
- All Implemented Interfaces:
Serializable,Comparable<JPPFManagementInfo>
public class JPPFManagementInfo
extends Object
implements Serializable, Comparable<JPPFManagementInfo>
Instances of this class encapsulate the information required to access the JMX server of a node or a driver.
- Author:
- Laurent Cohen
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intDeprecated.the Android node feature is no longer part of JPPFstatic final intDeprecated.the .Net bridge feature is no longer part of JPPFstatic final intDRIVER information type.static final intInformation that node is local on DRIVER or CLIENT.static final intInformation that the node is a master node for the provisioning feature.static final intNode information type.static final intPeer driver information type.static final intInformation that the node is a slave node for the provisioning feature.protected static final intMask for elimination extended type attributes (bits 16-31). -
Constructor Summary
ConstructorsConstructorDescriptionJPPFManagementInfo(String host, String ip, int port, String uuid, int type, boolean secure) Initialize this information with the specified parameters.JPPFManagementInfo(String host, String ip, int port, String uuid, int type, boolean secure, String masterUuid) Initialize this information with the specified parameters. -
Method Summary
Modifier and TypeMethodDescriptionintbooleangetHost()Get the host on which the node is running.Get the ip address of the host on which the node or driver is running.Get the uuid of the master node that providioned this node.intgetPort()Get the port on which the node's JMX server is listening.Get the system information associated with the node at the time of the initial connection.getUuid()Get the unique id for the node's mbean server.inthashCode()booleanisActive()Determine whether the node is active or inactive.booleanDeprecated.the Android node feature is no longer part of JPPFbooleanDeprecated.the .Net bridge feature is no longer part of JPPFbooleanisDriver()Determine whether this information represents a driver, connected as a peer to the driver from which this information is obtained.booleanisLocal()Determine whether this information represents a local node on client or driver.booleanDetermine whether this information represents a master node for provisioning.booleanisNode()Determine whether this information represents a real node.booleanisPeer()Determine whether this information represents a connection to peer driver.booleanisSecure()Determine whether communication with the node or driver is be secure, i.e. via SSL/TLS.booleanDetermine whether this information represents a slave node for provisioning.voidsetIsActive(boolean active) Specify whether the node is active or inactive.voidsetSystemInfo(JPPFSystemInformation systemInfo) Set the system information associated with the node at the time of the initial connection.Get a string displayed in the console.toString()
-
Field Details
-
DRIVER
public static final int DRIVERDRIVER information type.- See Also:
-
NODE
public static final int NODENode information type.- See Also:
-
PEER
public static final int PEERPeer driver information type.- See Also:
-
MASTER
public static final int MASTERInformation that the node is a master node for the provisioning feature.- See Also:
-
SLAVE
public static final int SLAVEInformation that the node is a slave node for the provisioning feature.- See Also:
-
LOCAL
public static final int LOCALInformation that node is local on DRIVER or CLIENT. Value of this constant can be changed in future!- See Also:
-
DOTNET
public static final int DOTNETDeprecated.the .Net bridge feature is no longer part of JPPFInformation that the node is initialized with a .Net bridge and can execute .Net tasks. Value of this constant can be changed in future!- Since:
- 5.0
- See Also:
-
ANDROID
Deprecated.the Android node feature is no longer part of JPPFInformation that the node is an Android node.- Since:
- 5.1
- See Also:
-
TYPE_MASK
protected static final int TYPE_MASKMask for elimination extended type attributes (bits 16-31).- See Also:
-
-
Constructor Details
-
JPPFManagementInfo
Initialize this information with the specified parameters.- Parameters:
host- the name of the host on which the node or driver is running.ip- the ip address of the host on which the node is running.port- the port on which the node's or driver's JMX server is listening.uuid- unique id of the node or driver.type- the type of component this info is for, must be one ofNODEorDRIVER.secure- specifies whether communication with the node or driver should be secure, i.e. via SSL/TLS.- Since:
- 5.0
-
JPPFManagementInfo
public JPPFManagementInfo(String host, String ip, int port, String uuid, int type, boolean secure, String masterUuid) Initialize this information with the specified parameters.- Parameters:
host- the name of the host on which the node or driver is running.ip- the ip address of the host on which the node is running.port- the port on which the node's or driver's JMX server is listening.uuid- unique id of the node or driver.type- the type of component this info is for, must be one ofNODEorDRIVER.secure- specifies whether communication with the node or driver should be secure, i.e. via SSL/TLS.masterUuid- uuid of the node of which this node is a slave, if any.- Since:
- 5.0
-
-
Method Details
-
getHost
Get the host on which the node is running.- Returns:
- the host as a string.
-
getPort
public int getPort()Get the port on which the node's JMX server is listening.- Returns:
- the port as an int.
-
hashCode
public int hashCode() -
equals
-
compareTo
- Specified by:
compareToin interfaceComparable<JPPFManagementInfo>
-
toString
-
toDisplayString
Get a string displayed in the console.- Returns:
- .
-
getSystemInfo
Get the system information associated with the node at the time of the initial connection. Please note that this atrribute is transient and will always be null immediately after theJPPFManagementInfoobject is retrieved from a remote server.- Returns:
- a
JPPFSystemInformationinstance.
-
setSystemInfo
Set the system information associated with the node at the time of the initial connection.- Parameters:
systemInfo- aJPPFSystemInformationinstance.
-
getUuid
Get the unique id for the node's mbean server.- Returns:
- the id as a string.
-
isPeer
public boolean isPeer()Determine whether this information represents a connection to peer driver.- Returns:
trueif this information represents a peer driver,falseotherwise.
-
isNode
public boolean isNode()Determine whether this information represents a real node.- Returns:
trueif this information represents a node,falseotherwise.
-
isDriver
public boolean isDriver()Determine whether this information represents a driver, connected as a peer to the driver from which this information is obtained.- Returns:
trueif this information represents a driver,falseotherwise.
-
isSecure
public boolean isSecure()Determine whether communication with the node or driver is be secure, i.e. via SSL/TLS.- Returns:
trueif the connection is secure,falseotherwise.
-
isMasterNode
public boolean isMasterNode()Determine whether this information represents a master node for provisioning.- Returns:
trueif the node is a master node,falseotherwise.
-
isSlaveNode
public boolean isSlaveNode()Determine whether this information represents a slave node for provisioning.- Returns:
trueif the node is a master node,falseotherwise.
-
isLocal
public boolean isLocal()Determine whether this information represents a local node on client or driver.- Returns:
trueif the node is local to a driver,falseotherwise
-
isDotnetCapable
public boolean isDotnetCapable()Deprecated.the .Net bridge feature is no longer part of JPPFDetermine whether this information represents a node than can execute .Net tasks.- Returns:
trueif the node is .Net-capable,falseotherwise.- Since:
- 5.0
-
isAndroidNode
public boolean isAndroidNode()Deprecated.the Android node feature is no longer part of JPPFDetermine whether this information represents an Android node.- Returns:
trueif the node an Android node,falseotherwise.- Since:
- 5.1
-
isActive
public boolean isActive()Determine whether the node is active or inactive.- Returns:
trueif the node is active,falseif it is inactve.
-
setIsActive
public void setIsActive(boolean active) Specify whether the node is active or inactive.- Parameters:
active-trueif the node is active,falseif it is inactve.
-
getIpAddress
Get the ip address of the host on which the node or driver is running.- Returns:
- the ip address as a string.
- Since:
- 5.0
-
getMasterUuid
Get the uuid of the master node that providioned this node.- Returns:
- the uuid of the node of which this node is a slave, if any, or
nullif this object doesn't represent a node, or if it represents a node that is not a slave.
-