Interface RhinoHousekeepingMBean
-
public interface RhinoHousekeepingMBeanAdministration MBean for operator driven Rhino housekeeping.
-
-
Field Summary
Fields Modifier and Type Field Description static StringOBJECT_NAME
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidflushConfiguration()Request that all configuration state waiting for persistence be persisted to the management database as soon as possible.voidflushKeyValueStores()Request that all application state waiting for persistence in all key/value stores in all event router nodes in the cluster be persisted to the backing database as soon as possible.voidflushKeyValueStores(int[] nodeIDs)Request that all application state waiting for persistence in all key/value stores in the specified event router nodes be persisted to the backing database as soon as possible.int[]getAllClusterNodes()Get the node IDs of all cluster members, including quorum nodes.ObjectNamegetClusterHousekeeping()Get aNodeHousekeepingMBeanfor the cluster.TabularDatagetClusterState()Queries current cluster state returning a summary of the state of each cluster member.TabularDatagetDomainConfig()Returns the current domain configuration.int[]getEventRouterNodes()Get the node IDs of all event processing nodes in the cluster.TabularDatagetKeyValueStoreStatus(int[] nodeIDs)Get the current operational status of the key/value stores on the specified nodes.ObjectNamegetNodeHousekeeping(int nodeID)Get aNodeHousekeepingMBeanfor a single cluster node.intgetNodeID()Get the node ID of this node.String[]getPersistenceResources()Get the names of the persistence resources that have been defined for the node.int[]getQuorumNodes()Get the node IDs of all quorum nodes in the cluster.TabularDatagetReplicatedMemDBStripingConfig()Returns the current MemDB striping configuration for replicated MemDB instances.TabularDatagetSessionOwnershipStoreStatus(int[] nodeIDs)Get the current operational status of the session ownership store on the specified nodes.intgetSnapshotPort()Returns the port the currently connected node uses for streaming snapshot data.CompositeDatagetVersion()Returns Rhino version information as CompositeData.booleanisReady(int nodeID)Test whether a node is ready to receive management commands.voidmarkAllActivitiesForRemoval(String entityName, int[] nodeIDs)Mark all activities belonging to a resource adaptor entity on the specified nodes for removal.voidremoveAllSbbs(ServiceID serviceID, int[] nodeIDs)Remove all SBB entities from a service on the specified nodes.
-
-
-
Field Detail
-
OBJECT_NAME
static final String OBJECT_NAME
- See Also:
- Constant Field Values
-
-
Method Detail
-
getNodeID
int getNodeID()
Get the node ID of this node. This method may be used by a management client to determine which Rhino node it is communicating with.
-
getEventRouterNodes
int[] getEventRouterNodes()
Get the node IDs of all event processing nodes in the cluster.
- Returns:
- an array of the node IDs of all event processing nodes in the cluster.
-
getQuorumNodes
int[] getQuorumNodes()
Get the node IDs of all quorum nodes in the cluster.
- Returns:
- an array of thee node IDs of all quorum nodes in the cluster.
-
getAllClusterNodes
int[] getAllClusterNodes()
Get the node IDs of all cluster members, including quorum nodes.
- Returns:
- an array of the node IDs of all nodes in the cluster.
-
getClusterHousekeeping
ObjectName getClusterHousekeeping() throws ManagementException
Get a
NodeHousekeepingMBeanfor the cluster.This method returns a special instance of
NodeHousekeepingMBeanthat operates on the entire cluster rather than a single node.- Returns:
- the JMX ObjectName of a NodeHousekeepingMBean.
- Throws:
ManagementException- if an internal error occurs.
-
getNodeHousekeeping
ObjectName getNodeHousekeeping(int nodeID) throws InvalidArgumentException, ManagementException
Get a
NodeHousekeepingMBeanfor a single cluster node.This method returns the Object Name of a
NodeHousekeepingMBeanthat operates on a single node. The specified node does not have to be a current member of the cluster, it may represent a failed or yet to join node. Invocations made against the returned MBean will fail however if the specified node is not a member of the cluster when the invocation occurs.- Parameters:
nodeID- node ID of the node.- Returns:
- the JMX ObjectName of a NodeHousekeepingMBean.
- Throws:
InvalidArgumentException- ifnodeIDis invalid.ManagementException- if an internal error occurs.
-
markAllActivitiesForRemoval
void markAllActivitiesForRemoval(String entityName, int[] nodeIDs) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, InvalidStateException, ManagementException
Mark all activities belonging to a resource adaptor entity on the specified nodes for removal.
Caution: This method irrevocably removes application state.
Used for force-ending activities from a deactivating resource adaptor.
All activities belonging to the specified resource adaptor entity on the specified nodes will be marked as requiring removal and then ended during the next iteration of Rhino’s periodic query-liveness scan.
The resource adaptor entity must be in the deactivating state on the given nodes.
- Parameters:
entityName- Resource Adaptor entity name of the RA entitynodeIDs- the node IDs of the nodes to remove activities from. May be zero-length, in which case all current event-router cluster nodes are targeted.- Throws:
NullPointerException- if either argument isnull.UnrecognizedResourceAdaptorEntityException- if the resource adaptor entity is unknown.InvalidStateException- if the resource adaptor entity is not in the Stopping or Inactive state, or the SLEE is not in the Stopping or Stopped state, on the specified nodes.ManagementException- if an internal error occurs.
-
removeAllSbbs
void removeAllSbbs(ServiceID serviceID, int[] nodeIDs) throws NullPointerException, UnrecognizedServiceException, InvalidStateException, ManagementException
Remove all SBB entities from a service on the specified nodes.
Caution: This method irrevocably removes application state.
Used for forcibly removing remaining SBBs from a deactivating service.
- Parameters:
serviceID- component ID of the service from which all SBBs should be removed.nodeIDs- the node IDs of the nodes to remove SBB entities from. May be zero-length, in which case all current event-router cluster nodes are targeted.- Throws:
NullPointerException- if either argument isnull.UnrecognizedServiceException- if the service is unknown.InvalidStateException- if the service is not in the Stopping or Inactive state, or the SLEE is not in the Stopping or Stopped state, on the specified nodes.ManagementException- if an internal error occurs.
-
isReady
boolean isReady(int nodeID) throws ManagementExceptionTest whether a node is ready to receive management commands.
- Parameters:
nodeID- node ID of the node.- Throws:
ManagementException- if an internal error occurs.
-
getPersistenceResources
String[] getPersistenceResources() throws ManagementException
Get the names of the persistence resources that have been defined for the node.
- Returns:
- the persistence resource names.
- Throws:
ManagementException- if an internal error occurs.- Since:
- Rhino 2.6.1
-
getClusterState
TabularData getClusterState() throws ManagementException
Queries current cluster state returning a summary of the state of each cluster member.
The cluster state is returned in
TabularDataformat - one row is returned per cluster member. Each row contains the following information:Field Open Type Description node-id
Integer
Rhino cluster node id
host
String
Name of the host on which the node is running
node-type
String
Type of node, either "event-router" or "quorum"
start-time
Date
Start time of the cluster node
up-time
Long
Time the cluster node has been running in milliseconds
slee-state
String
SLEE state
active-alarms
Integer
Number of active alarms on the cluster node
- Returns:
TabularDatacontaining node status information.- Throws:
ManagementException- if an internal error occurs.
-
getDomainConfig
TabularData getDomainConfig() throws ManagementException
Returns the current domain configuration.
The domain config is returned in
TabularDataformat - one row is returned per domain. Each row contains the following information:Field Open Type Description domain
String
Domain name
memdb-resources
String[]
Array of memdb resource names
ah-resources
String[]
Array of AH resource names
nodes
Integer[]
Nodes associated with this domain
- Returns:
TabularDatacontaining node status information.- Throws:
ManagementException- if an internal error occurs.
-
getReplicatedMemDBStripingConfig
TabularData getReplicatedMemDBStripingConfig() throws ManagementException
Returns the current MemDB striping configuration for replicated MemDB instances.
The striping config is returned in
TabularDataformat - one row is returned per replicated MemDB instance. Each row contains the following information:Field Open Type Description memdb-resource
String
Memdb resource name
stripe-count
Integer
The stripe count
stripe-offset
Integer
The stripe offset
- Returns:
TabularDatacontaining node striping configuration information.- Throws:
ManagementException- if an internal error occurs.
-
getVersion
CompositeData getVersion() throws AttributeNotFoundException, ManagementException
Returns Rhino version information as CompositeData.
The CompositeData has the following fields, which are all of type
String:-
Product
-
Version
-
Release
-
Build
-
Revision
- Returns:
CompositeDatacontaining detailed Rhino version information- Throws:
AttributeNotFoundException- if the MBean implementation does not support this method (Rhino versions prior to 2.2 don’t)ManagementException- if an internal error occurs
-
-
getSnapshotPort
int getSnapshotPort() throws ManagementExceptionReturns the port the currently connected node uses for streaming snapshot data.
- Throws:
ManagementException
-
flushKeyValueStores
void flushKeyValueStores() throws ManagementExceptionRequest that all application state waiting for persistence in all key/value stores in all event router nodes in the cluster be persisted to the backing database as soon as possible.
Any unwritten application state buffered in the key/value stores at the time this operation is invoked will be flushed. Any further application state committed after the flush operation is initiated will be persisted at some future time in accordance with normal key/value store behaviour.
This method blocks until the flush operation has completed.
- Throws:
ManagementException- if an internal error occurs.
-
flushKeyValueStores
void flushKeyValueStores(int[] nodeIDs) throws NullPointerException, InvalidArgumentException, ManagementExceptionRequest that all application state waiting for persistence in all key/value stores in the specified event router nodes be persisted to the backing database as soon as possible.
Any unwritten application state buffered in the key/value stores at the time this operation is invoked will be flushed. Any further application state committed after the flush operation is initiated will be persisted at some future time in accordance with normal key/value store behaviour.
This method blocks until the flush operation has completed.
- Parameters:
nodeIDs- the node IDs of the nodes to flush. These must be event router nodes.- Throws:
NullPointerException- ifnodeIDsisnull.InvalidArgumentException- if any of the node IDs are invalid or not currently live event router nodes.ManagementException- if an internal error occurs.
-
flushConfiguration
void flushConfiguration() throws ManagementExceptionRequest that all configuration state waiting for persistence be persisted to the management database as soon as possible.
This method is unnecessary during normal operation as configuration changes are usually persisted to the database within seconds (assuming availability). This method is primarily intended for automated systems which require certainty that configuration changes have been persisted.
This method blocks until the flush operation has completed.
- Throws:
ManagementException- if an internal error occurs.
-
getKeyValueStoreStatus
TabularData getKeyValueStoreStatus(int[] nodeIDs) throws NullPointerException, InvalidArgumentException, ManagementException
Get the current operational status of the key/value stores on the specified nodes.
The status is returned in
TabularDataformat - one row is returned per (node, name) tuple. Each row contains the following information:Field Open Type Description node
integer
Node ID
name
String
Name of the key/value store
status
String
Operational status
The following status values are universally defined:
-
booting- denotes that the indicated node is still booting up and initialising. For nodes in this state, thenamecolumn has anullvalue. -
n/a- denotes that the indicated node has no namespace using a key/value store or the node is a quorum node. For nodes in this state, thenamecolumn has anullvalue.
The Cassandra Key/Value Store also defines the follow status values:
-
connection failure- if a database connection for any Rhino persistence instance used by the key/value store cannot be established. -
rebuilding tables- if all required database connections are up but some connections still require database keyspaces and/or tables to be set up. -
in sync- if all database connections are up and all database keyspaces and tables have been set up.
- Parameters:
nodeIDs- the node IDs of the nodes to get status information for.- Returns:
TabularDatacontaining key/value store status information.- Throws:
NullPointerException- ifnodeIDsisnull.InvalidArgumentException- if any of the node IDs are invalid or not current cluster members.ManagementException- if an internal error occurs.- Since:
- Rhino 3.0.0
-
-
getSessionOwnershipStoreStatus
TabularData getSessionOwnershipStoreStatus(int[] nodeIDs) throws NullPointerException, InvalidArgumentException, ManagementException
Get the current operational status of the session ownership store on the specified nodes.
The status is returned in
TabularDataformat - one row is returned per node ID. Each row contains the following information:Field Open Type Description node
integer
Node ID
status
String
Operational status
The following status values are universally defined:
-
booting- denotes that the indicated node is still booting up and initialising. -
n/a- denotes that the indicated node has no session ownership store configured or is a quorum node.
The Cassandra Session Ownership Store also defines the follow status values:
-
connection failure- if a database connection for any Rhino persistence instance used by the session ownership store cannot be established. -
rebuilding tables- if all required database connections are up but some connections still require database keyspaces and/or tables to be set up. -
in sync- if all database connections are up and all database keyspaces and tables have been set up.
- Parameters:
nodeIDs- the node IDs of the nodes to get status information for.- Returns:
TabularDatacontaining session ownership store status information.- Throws:
NullPointerException- ifnodeIDsisnull.InvalidArgumentException- if any of the node IDs are invalid or not current cluster members.ManagementException- if an internal error occurs.- Since:
- Rhino 3.0.0
-
-
-