Interface ResourceManagementMBean
-
- All Superinterfaces:
ResourceManagementMBean
public interface ResourceManagementMBean extends ResourceManagementMBean
The ResourceManagementMBean interface defines resource adaptor-related management operations. This interface provides extensions to
ResourceManagementMBean
for additional Rhino-specific functionality.
-
-
Field Summary
-
Fields inherited from interface javax.slee.management.ResourceManagementMBean
OBJECT_NAME, RESOURCE_ADAPTOR_ENTITY_STATE_CHANGE_NOTIFICATION_TYPE
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
activateResourceAdaptorEntity(String entityName)
Activate a resource adaptor entity on all nodes.void
activateResourceAdaptorEntity(String entityName, int[] nodeIDs)
Activate a resource adaptor entity on the specified nodes.void
deactivateResourceAdaptorEntity(String entityName)
Deactivate a resource adaptor entity on all nodes.void
deactivateResourceAdaptorEntity(String entityName, int[] nodeIDs)
Deactivate a resource adaptor entity on the specified nodes.void
deactivateResourceAdaptorEntity(String entityName, int[] nodeIDs, int[] reassignActivitiesToNodeIDs)
Deactivate a resource adaptor entity on the specified nodes and reassign replicated activities owned by the resource adaptor entity on the deactivating nodes to other cluster nodes.ResourceAdaptorEntityActualState[]
getActualState(String entityName, int[] nodeIDs)
Get the current actual state of a resource adaptor entity for each of the specified nodes.SbbPartID[]
getBoundSbbParts(String linkName)
Get the set of SBB part component identifiers that identify the SBB parts that are bound to the specified link name by way of aresource-adaptor-entity-link
element in their deployment descriptor.SbbID[]
getBoundSbbs(String linkName)
ConfigProperties
getConfigurationProperties(String entityName)
ConfigProperties
getConfigurationProperties(ResourceAdaptorID id)
ResourceAdaptorEntityDesiredState
getDefaultDesiredState(String entityName)
Get the current default desired state of a resource adaptor entity.String[]
getLinkNames(String entityName)
int[]
getNodes(String entityName, ResourceAdaptorEntityState state)
Get the set of event-router nodes in the primary component where the resource adaptor entity is in the specified state.int[]
getNodesWithDesiredState(String entityName)
Returns an array of node IDs representing the nodes which currently have per-node desired entity state for the specified resource adaptor entity.ResourceAdaptorEntityDesiredState
getPerNodeDesiredState(String entityName, int nodeID)
Get the current desired state of a resource adaptor entity on the specified node.ResourceAdaptorEntityDesiredState[]
getPerNodeDesiredState(String entityName, int[] nodeIDs)
Get the current desired state of a resource adaptor entity for each of the specified nodes.ResourceAdaptorID
getResourceAdaptor(String entityName)
String[]
getResourceAdaptorEntities(String[] linkNames)
String[]
getResourceAdaptorEntities(ResourceAdaptorEntityState state)
Get the set of resource adaptor entities that are in a particular state.String[]
getResourceAdaptorEntities(ResourceAdaptorEntityState state, int nodeID)
Get the set of resource adaptor entities that are in a particular state on the specified node.String[]
getResourceAdaptorEntities(ResourceAdaptorID id)
String
getResourceAdaptorEntity(String linkName)
ObjectName
getResourceUsageMBean(String entityName)
Byte[]
getStartingPriorities(String[] entityNames)
Get an array of starting priorities corresponding to an array of resource adaptor entity names.byte
getStartingPriority(String entityName)
Get the starting priority for a resource adaptor entity.ResourceAdaptorEntityState
getState(String entityName)
Get the current state of a resource adaptor entity.ResourceAdaptorEntityState[]
getState(String entityName, int[] nodeIDs)
Get the current state of a resource adaptor entity on each of the specified nodes.Byte[]
getStoppingPriorities(String[] entityNames)
Get an array of stopping priorities corresponding to an array of resource adaptor entity names.byte
getStoppingPriority(String entityName)
Get the stopping priority for a resource adaptor entity.void
reassignActivities(String entityName, int[] fromNodeIDs, int[] toNodeIDs)
Reassign replicated activities owned by a resource adaptor entity on the specified nodes to other cluster nodes.void
removePerNodeDesiredState(String entityName, int[] nodeIDs)
Remove the per-node desired state of a resource adaptor entity on each of the specified nodes.void
setDefaultDesiredState(String entityName, ResourceAdaptorEntityDesiredState state)
Set the default desired state of a resource adaptor entity.void
setPerNodeDesiredState(String entityName, int[] nodeIDs, ResourceAdaptorEntityDesiredState state)
Set the current desired state of a resource adaptor entity on each of the specified nodes.void
setStartingPriority(String entityName, byte priority)
Set the starting priority for a resource adaptor entity.void
setStoppingPriority(String entityName, byte priority)
Set the stopping priority for a resource adaptor entity.-
Methods inherited from interface javax.slee.management.ResourceManagementMBean
bindLinkName, createResourceAdaptorEntity, getLinkNames, getResourceAdaptorEntities, removeResourceAdaptorEntity, unbindLinkName, updateConfigurationProperties
-
-
-
-
Method Detail
-
activateResourceAdaptorEntity
void activateResourceAdaptorEntity(String entityName) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, InvalidStateException, ManagementException
Activate a resource adaptor entity on all nodes.
The resource adaptor entity must currently have an effective desired state of
ResourceAdaptorEntityDesiredState.inactive
on at least one live event routing node, as determined byRhinoHousekeepingMBean.getEventRouterNodes()
. All per-node desired state for the resource adaptor entity is removed by this method and the default desired state of the resource adaptor entity is set toResourceAdaptorEntityDesiredState.active
(if it is not already). Before this method returns, an attempt is then made to transition the resource adaptor entity to an actual state ofResourceAdaptorEntityActualState.active
on all event router nodes where the actual state is currentlyResourceAdaptorEntityActualState.inactive
. Any node where the resource adaptor entity actual state isResourceAdaptorEntityActualState.stopping
will wait (asynchronously) until the resource adaptor entity reaches theResourceAdaptorEntityActualState.inactive
state and then attempt to transition the resource adaptor entity back toResourceAdaptorEntityActualState.active
.As a result of this method setting the default desired state to
ResourceAdaptorEntityDesiredState.active
, any new event router nodes that boot into the cluster will assume an activated state for the resource adaptor entity unless per-node desired state is subsequently created to state otherwise.- Specified by:
activateResourceAdaptorEntity
in interfaceResourceManagementMBean
- Parameters:
entityName
- the name of the resource adaptor entity.- Throws:
NullPointerException
- ifentityName
isnull
.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.InvalidStateException
- if the effective desired state of the resource adaptor entity is notResourceAdaptorEntityDesiredState.inactive
on any current event router node.ManagementException
- if the resource adaptor entity could not be activated due to a system-level failure.
-
activateResourceAdaptorEntity
void activateResourceAdaptorEntity(String entityName, int[] nodeIDs) throws NullPointerException, InvalidArgumentException, UnrecognizedResourceAdaptorEntityException, InvalidStateException, ManagementException
Activate a resource adaptor entity on the specified nodes.
The resource adaptor entity must currently have an effective desired state of
ResourceAdaptorEntityDesiredState.inactive
on all the specified nodes. Per-node desired state for the resource adaptor entity is created for each specified node if it does not already exist and set toResourceAdaptorEntityDesiredState.active
. Before this method returns, an attempt is then made to transition the resource adaptor entity to an actual state ofResourceAdaptorEntityActualState.active
on all specified nodes that are current live event router nodes where the actual state isResourceAdaptorEntityActualState.inactive
. Any node where the resource adaptor entity actual state isResourceAdaptorEntityActualState.stopping
will wait (asynchronously) until the resource adaptor entity reaches theResourceAdaptorEntityActualState.inactive
state and then attempt to transition the resource adaptor entity back toResourceAdaptorEntityActualState.active
.The specified nodes do not have to be current cluster members. For example, this method can be used to set the resource adaptor entity desired state on nodes yet to be started.
This method does not affect the default desired state of the resource adaptor entity.
- Parameters:
entityName
- the name of the resource adaptor entity.nodeIDs
- the node IDs of the nodes to activate the resource adaptor entity on.- Throws:
NullPointerException
- if either argument isnull
.InvalidArgumentException
- ifnodeIDs
is zero-length or contains invalid node IDs.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.InvalidStateException
- if the effective desired state of the resource adaptor entity is notResourceAdaptorEntityDesiredState.inactive
on all specified nodes.ManagementException
- if the resource adaptor entity could not be activated due to a system-level failure.
-
deactivateResourceAdaptorEntity
void deactivateResourceAdaptorEntity(String entityName) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, InvalidStateException, ManagementException
Deactivate a resource adaptor entity on all nodes.
The resource adaptor entity must currently have an effective desired state of
ResourceAdaptorEntityDesiredState.active
on at least one live event routing node, as determined byRhinoHousekeepingMBean.getEventRouterNodes()
. All per-node desired state for the resource adaptor entity is removed by this method and the default desired state of the resource adaptor entity is set toResourceAdaptorEntityDesiredState.inactive
(if it is not already). The resource adaptor entity then transitions to an actual state ofResourceAdaptorEntityActualState.stopping
on all event router nodes where the actual state is currentlyResourceAdaptorEntityActualState.active
before this method returns.As a result of this method setting the default desired state to
ResourceAdaptorEntityDesiredState.inactive
, any new event router nodes that boot into the cluster will assume an inactive state for the resource adaptor entity unless per-node desired state is subsequently created to state otherwise.- Specified by:
deactivateResourceAdaptorEntity
in interfaceResourceManagementMBean
- Parameters:
entityName
- the name of the resource adaptor entity.- Throws:
NullPointerException
- ifentityName
isnull
.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.InvalidStateException
- if the effective desired state of the resource adaptor entity is notResourceAdaptorEntityDesiredState.active
on any current event router node.ManagementException
- if the resource adaptor entity could not be deactivated due to a system-level failure.
-
deactivateResourceAdaptorEntity
void deactivateResourceAdaptorEntity(String entityName, int[] nodeIDs) throws NullPointerException, InvalidArgumentException, UnrecognizedResourceAdaptorEntityException, InvalidStateException, ManagementException
Deactivate a resource adaptor entity on the specified nodes.
The resource adaptor entity must currently have an effective desired state of
ResourceAdaptorEntityDesiredState.active
on all the specified nodes. Per-node desired state for the resource adaptor entity is created for each specified node if it does not already exist and set toResourceAdaptorEntityDesiredState.inactive
. The resource adaptor entity then transitions to an actual state ofResourceAdaptorEntityActualState.stopping
on all specified nodes that are current live event router nodes where the actual state isResourceAdaptorEntityActualState.active
before this method returns.The specified nodes do not have to be current cluster members. For example, this method can be used to set the resource adaptor entity desired state on nodes yet to be started.
This method does not affect the default desired state of the resource adaptor entity.
If the resource adaptor entity owns replicated activities on nodes that transition to
ResourceAdaptorEntityActualState.stopping
then those activities are left to drain normally by this method. If ownership of these activities should be reassigned to allow the resource adaptor entity to return to theResourceAdaptorEntityActualState.inactive
state quicker thendeactivateResourceAdaptorEntity(String, int[], int[])
should be used instead. AlternativelyreassignActivities(String, int[], int[])
may be used after deactivation to perform this reassignment.- Parameters:
entityName
- the name of the resource adaptor entity.nodeIDs
- the node IDs of the nodes to deactivate the resource adaptor entity on.- Throws:
NullPointerException
- if either argument isnull
.InvalidArgumentException
- ifnodeIDs
is zero-length or contains invalid node IDs.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.InvalidStateException
- if the effective desired state of the resource adaptor entity is notResourceAdaptorEntityDesiredState.active
on all specified nodes.ManagementException
- if the resource adaptor entity could not be deactivated due to a system-level failure.
-
deactivateResourceAdaptorEntity
void deactivateResourceAdaptorEntity(String entityName, int[] nodeIDs, int[] reassignActivitiesToNodeIDs) throws NullPointerException, InvalidArgumentException, UnrecognizedResourceAdaptorEntityException, InvalidStateException, ManagementException
Deactivate a resource adaptor entity on the specified nodes and reassign replicated activities owned by the resource adaptor entity on the deactivating nodes to other cluster nodes.
The resource adaptor entity must currently have an effective desired state of
ResourceAdaptorEntityDesiredState.active
on all the specified nodes. Per-node desired state for the resource adaptor entity is created for each specified node if it does not already exist and set toResourceAdaptorEntityDesiredState.inactive
. The resource adaptor entity then transitions to an actual state ofResourceAdaptorEntityActualState.stopping
on all specified nodes that are current live event router nodes where the actual state isResourceAdaptorEntityActualState.active
before this method returns.The specified nodes do not have to be current cluster members. For example, this method can be used to set the resource adaptor entity desired state on nodes yet to be started.
This method does not affect the default desired state of the resource adaptor entity.
This method has several modes of operation, depending on the value of the
reassignActivitiesToNodeIDs
parameter:-
if
reassignActivitiesToNodeIDs
isnull
, this method behaves in the same way as thedeactivateResourceAdaptorEntity(String, int[])
method, ie. no replicated activity reassignment takes place -
if
reassignActivitiesToNodeIDs
is a zero-length array, replicated activities will be reassigned to any other cluster nodes that are capable of taking ownership of the activities; if no nodes satisfy this criteria no activity reassignment takes place -
if
reassignActivitiesToNodeIDs
is an array with at least one element, replicated activities will be reassigned to the specified node(s).
Replicated activities for a resource adaptor entity will only be reassigned from a node if the node meets the following conditions:
-
the node is a live cluster member providing event routing functions, ie. not a quorum node
-
the resource adaptor entity has an actual state of
ResourceAdaptorEntityActualState.active
on the node prior to this method being invoked -
the SLEE has an actual state of
SleeActualState.running
orSleeActualState.stopping
on the node.
Replicated activities for a resource adaptor entity may only be reassigned to a node if the node meets the following conditions:
-
the node is a live cluster member providing event routing functions, ie. not a quorum node
-
the resource adaptor entity has both a desired state of
ResourceAdaptorEntityDesiredState.active
and an actual state ofResourceAdaptorEntityActualState.active
on the node -
the SLEE has an actual state of
SleeActualState.running
state on the node.
- Parameters:
entityName
- the name of the resource adaptor entity.nodeIDs
- the node IDs of the nodes to deactivate the resource adaptor entity on.reassignActivitiesToNodeIDs
- the set of nodes to reassign replicated activities to.- Throws:
NullPointerException
- ifentityName
ornodeIDs
isnull
.InvalidArgumentException
- ifnodeIDs
is zero-length or contains invalid node IDs, or ifreassignActivitiesToNodeIDs
is non-null but the resource adaptor entity is not replicating or if the target nodes are invalid.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.InvalidStateException
- if the effective desired state of the resource adaptor entity is notResourceAdaptorEntityDesiredState.active
on all specified nodes.ManagementException
- if the resource adaptor entity could not be deactivated due to a system-level failure.
-
-
reassignActivities
void reassignActivities(String entityName, int[] fromNodeIDs, int[] toNodeIDs) throws NullPointerException, InvalidArgumentException, UnrecognizedResourceAdaptorEntityException, InvalidStateException, ManagementException
Reassign replicated activities owned by a resource adaptor entity on the specified nodes to other cluster nodes. The resource adaptor entity must be a replicating resource adaptor entity.
This method has two modes of operation, depending on the value of the
toNodeIDs
parameter:-
if
toNodeIDs
is a zero-length array, replicated activities will be reassigned to any other cluster nodes that are capable of taking ownership of the activities -
if
toNodeIDs
is an array with at least one element, replicated activities will be reassigned to the specified node(s).
Replicated activities for a resource adaptor entity may only be reassigned from a node if the node meets the following conditions:
-
the node is a live cluster member providing event routing functions, ie. not a quorum node
-
the resource adaptor entity has an actual state of
ResourceAdaptorEntityActualState.active
orResourceAdaptorEntityActualState.stopping
state on the node -
the SLEE has an actual state of
SleeActualState.running
orSleeActualState.stopping
state on the node.
Replicated activities for a resource adaptor entity may only be reassigned to a node if the node meets the following conditions:
-
the node is a live cluster member providing event routing functions, ie. not a quorum node
-
the resource adaptor entity has both a desired state of
ResourceAdaptorEntityDesiredState.active
and an actual state ofResourceAdaptorEntityActualState.active
on the node -
the SLEE has an actual state of
SleeActualState.running
state on the node.
- Parameters:
entityName
- the name of the resource adaptor entity.fromNodeIDs
- the node IDs of the nodes to reassign activities from.toNodeIDs
- the node IDs of the nodes to reassign the activities to.- Throws:
NullPointerException
- if any argument isnull
.InvalidArgumentException
- ifentityName
does not correspond with a replicating resource adaptor, or iffromNodeIDs
is zero-length or contains invalid node IDs, or iftoNodeIDs
is contains invalid node IDs.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.InvalidStateException
- if the resource adaptor entity or SLEE is not in the appropriate state on any relevant node as required above, or iftoNodeIDs
is zero-length and there are no remaining nodes that the activities may be reassigned to.ManagementException
- if the activities could not be reassigned due to a system-level failure.
-
-
getState
ResourceAdaptorEntityState getState(String entityName) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, ManagementException
Get the current state of a resource adaptor entity. This method returns the state of the resource adaptor entity on the node the management client directs the method call at, as determined by
RhinoHousekeepingMBean.getNodeID()
.This method translates the actual state of the resource adaptor entity on the node to an equivalent JAIN SLEE-defined state.
- Specified by:
getState
in interfaceResourceManagementMBean
- Parameters:
entityName
- the name of the resource adaptor entity.- Returns:
- the current state of the resource adaptor entity on the invoked node.
- Throws:
NullPointerException
- ifentityName
isnull
.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.ManagementException
- if the state of the resource adaptor entity could not be obtained due to a system-level failure.
-
getState
ResourceAdaptorEntityState[] getState(String entityName, int[] nodeIDs) throws NullPointerException, InvalidArgumentException, UnrecognizedResourceAdaptorEntityException, ManagementException
Get the current state of a resource adaptor entity on each of the specified nodes.
This method translates the desired or actual state of the resource adaptor entity on each specified node to an equivalent JAIN SLEE-defined state depending on the presence of the node. For nodes that are current live event router nodes, actual state is used. For nodes that are not cluster members or are not event router nodes, desired state is used.
- Parameters:
entityName
- the name of the resource adaptor entity.nodeIDs
- the node IDs of the nodes to return the resource adaptor entity’s state for.- Returns:
- an array of resource adaptor entity state objects.
This array will be the same length as the supplied
nodeIDs
array, and ifstates = getState(entityName, nodeIDs)
thenstates[i]
equals the state of the resource adaptor entity on nodenodeIDs[i]
. If there is no state information for the resource adaptor entity on a particular node,ResourceAdaptorEntityState.INACTIVE
is returned as the resulting state for the resource adaptor entity on that node. - Throws:
NullPointerException
- if either argument isnull
.InvalidArgumentException
- ifnodeIDs
contains invalid node IDs.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.ManagementException
- if the state of the resource adaptor entity could not be obtained due to a system-level failure.
-
getResourceAdaptorEntities
String[] getResourceAdaptorEntities(ResourceAdaptorEntityState state) throws NullPointerException, ManagementException
Get the set of resource adaptor entities that are in a particular state.
This method returns the set of resource adaptor entities in the specified state on the node the management client directs this method call at, as determined by
RhinoHousekeepingMBean.getNodeID()
. This method translates the actual state of each resource adaptor entities on the node to an equivalent JAIN SLEE-defined state for comparison purposes.- Specified by:
getResourceAdaptorEntities
in interfaceResourceManagementMBean
- Parameters:
state
- the required state.- Returns:
- an array of strings identifying the resource adaptor entities that are in the specified state on the invoked node.
- Throws:
NullPointerException
- ifstate
isnull
.ManagementException
- if the identifiers could not be obtained due to a system-level failure.
-
getResourceAdaptorEntities
String[] getResourceAdaptorEntities(ResourceAdaptorEntityState state, int nodeID) throws NullPointerException, InvalidArgumentException, ManagementException
Get the set of resource adaptor entities that are in a particular state on the specified node.
The specified node does not have to be a current cluster member. For example this method can be used to query the activation state for resource adaptor entities on a node yet to be started.
This method translates the desired or actual state of each resource adaptor entity to an equivalent JAIN SLEE-defined state for comparison purposes depending on the presence of the specified node. If the specified node is a current live event router node, then actual state is used. Otherwise, desired state is used.
- Parameters:
state
- the required state.- Returns:
- an array of strings identifying the resource adaptor entities that are in the specified state on the specified node.
- Throws:
NullPointerException
- ifstate
isnull
.InvalidArgumentException
- ifnodeID
is an invalid node ID.ManagementException
- if the identifiers could not be obtained due to a system-level failure.
-
getNodes
int[] getNodes(String entityName, ResourceAdaptorEntityState state) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, ManagementException
Get the set of event-router nodes in the primary component where the resource adaptor entity is in the specified state.
This method translates the actual state of the resource adaptor entity on each node to an equivalent JAIN SLEE-defined state for comparison purposes.
- Parameters:
entityName
- the name of the resource adaptor entity.state
- the required state.- Returns:
- an array of node IDs identifying the event-router nodes where the resource adaptor entity is in the specified state.
- Throws:
NullPointerException
- if either argument isnull
.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.ManagementException
- if the set of nodes where the resource adaptor entity is in the required state could not be determined due to a system-level failure.
-
setStartingPriority
void setStartingPriority(String entityName, byte priority) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, ManagementException
Set the starting priority for a resource adaptor entity. The starting priority determines the order in which services and resource adaptor entities together are started when the SLEE transitions from the STOPPED state to the RUNNING state.
Priorities are values between -128 and 127. If a component (service or resource adaptor entity), X, has a numerically higher priority value than another component, Y, then X will be started before Y. Components with the same priority may be started in an arbitrary order, or may be started concurrently.
- Parameters:
entityName
- the name of the resource adaptor entity.priority
- the starting priority for the resource adaptor entity.- Throws:
NullPointerException
- ifentityName
isnull
.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.ManagementException
- if the starting priority of the resource adaptor entity could not be updated due to a system-level failure.- Since:
- Rhino 2.4.0
- See Also:
setStoppingPriority(String, byte)
-
getStartingPriority
byte getStartingPriority(String entityName) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, ManagementException
Get the starting priority for a resource adaptor entity.
- Parameters:
entityName
- the name of the resource adaptor entity.- Returns:
- the starting priority of the resource adaptor entity.
- Throws:
NullPointerException
- ifid
isnull
.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.ManagementException
- if the starting priority of the resource adaptor entity could not be obtained due to a system-level failure.- Since:
- Rhino 2.4.0
- See Also:
setStartingPriority(String, byte)
-
getStartingPriorities
Byte[] getStartingPriorities(String[] entityNames) throws NullPointerException, ManagementException
Get an array of starting priorities corresponding to an array of resource adaptor entity names.
- Parameters:
entityNames
- the array of resource adaptor entity names.- Returns:
- an array of starting priorities.
This array will be the same length as the supplied array, and if
priorities = getStartingPriorities(entityNames)
thenpriorities[i] == getStartingPriority(entityNames[i])
. Any unrecognised resource adaptor entity name present inentityNames
results in anull
value at the corresponding array index in this array. - Throws:
NullPointerException
- ifentityNames
isnull
.ManagementException
- if the starting priorities could not be obtained due to a system-level failure.- Since:
- Rhino 2.4.0
-
setStoppingPriority
void setStoppingPriority(String entityName, byte priority) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, ManagementException
Set the stopping priority for a resource adaptor entity. The stopping priority determines the order in which services and resource adaptor entities together are stopped when the SLEE transitions from the RUNNING state to the STOPPING state.
Priorities are values between -128 and 127. If a component (service or resource adaptor entity), X, has a numerically higher priority value than another component, Y, then X will be stopped before Y. Components with the same priority may be stopped in an arbitrary order, or may be stopped concurrently.
- Parameters:
entityName
- the name of the resource adaptor entity.priority
- the stopping priority for the resource adaptor entity.- Throws:
NullPointerException
- ifentityName
isnull
.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.ManagementException
- if the stopping priority of the resource adaptor entity could not be updated due to a system-level failure.- Since:
- Rhino 2.4.0
- See Also:
setStartingPriority(String, byte)
-
getStoppingPriority
byte getStoppingPriority(String entityName) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, ManagementException
Get the stopping priority for a resource adaptor entity.
- Parameters:
entityName
- the name of the resource adaptor entity.- Returns:
- the stopping priority of the resource adaptor entity.
- Throws:
NullPointerException
- ifid
isnull
.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.ManagementException
- if the stopping priority of the resource adaptor entity could not be obtained due to a system-level failure.- Since:
- Rhino 2.4.0
- See Also:
setStartingPriority(String, byte)
-
getStoppingPriorities
Byte[] getStoppingPriorities(String[] entityNames) throws NullPointerException, ManagementException
Get an array of stopping priorities corresponding to an array of resource adaptor entity names.
- Parameters:
entityNames
- the array of resource adaptor entity names.- Returns:
- an array of stopping priorities.
This array will be the same length as the supplied array, and if
priorities = getStoppingPriorities(entityNames)
thenpriorities[i] == getStoppingPriority(entityNames[i])
. Any unrecognised resource adaptor entity name present inentityNames
results in anull
value at the corresponding array index in this array. - Throws:
NullPointerException
- ifentityNames
isnull
.ManagementException
- if the stopping priorities could not be obtained due to a system-level failure.- Since:
- Rhino 2.4.0
-
getResourceAdaptorEntities
String[] getResourceAdaptorEntities(ResourceAdaptorID id) throws NullPointerException, UnrecognizedResourceAdaptorException, ManagementException
- Specified by:
getResourceAdaptorEntities
in interfaceResourceManagementMBean
- Throws:
NullPointerException
UnrecognizedResourceAdaptorException
ManagementException
-
getResourceAdaptorEntities
String[] getResourceAdaptorEntities(String[] linkNames) throws NullPointerException, ManagementException
- Specified by:
getResourceAdaptorEntities
in interfaceResourceManagementMBean
- Throws:
NullPointerException
ManagementException
-
getConfigurationProperties
ConfigProperties getConfigurationProperties(ResourceAdaptorID id) throws NullPointerException, UnrecognizedResourceAdaptorException, ManagementException
- Specified by:
getConfigurationProperties
in interfaceResourceManagementMBean
- Throws:
NullPointerException
UnrecognizedResourceAdaptorException
ManagementException
-
getConfigurationProperties
ConfigProperties getConfigurationProperties(String entityName) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, ManagementException
- Specified by:
getConfigurationProperties
in interfaceResourceManagementMBean
- Throws:
NullPointerException
UnrecognizedResourceAdaptorEntityException
ManagementException
-
getResourceAdaptor
ResourceAdaptorID getResourceAdaptor(String entityName) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, ManagementException
- Specified by:
getResourceAdaptor
in interfaceResourceManagementMBean
- Throws:
NullPointerException
UnrecognizedResourceAdaptorEntityException
ManagementException
-
getLinkNames
String[] getLinkNames(String entityName) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, ManagementException
- Specified by:
getLinkNames
in interfaceResourceManagementMBean
- Throws:
NullPointerException
UnrecognizedResourceAdaptorEntityException
ManagementException
-
getBoundSbbs
SbbID[] getBoundSbbs(String linkName) throws NullPointerException, UnrecognizedLinkNameException, ManagementException
- Specified by:
getBoundSbbs
in interfaceResourceManagementMBean
- Throws:
NullPointerException
UnrecognizedLinkNameException
ManagementException
-
getBoundSbbParts
SbbPartID[] getBoundSbbParts(String linkName) throws UnrecognizedLinkNameException, ManagementException
Get the set of SBB part component identifiers that identify the SBB parts that are bound to the specified link name by way of a
resource-adaptor-entity-link
element in their deployment descriptor.- Parameters:
linkName
- the link name.- Returns:
- an array of SBB part component identifiers identifying the SBBs that are bound to the link name.
- Throws:
NullPointerException
- iflinkName
isnull
.UnrecognizedLinkNameException
- iflinkName
has not been bound to a resource adaptor entity.ManagementException
- if the SBB part component identifiers could not be obtained due to a system-level failure.- Since:
- Rhino 2.4.0
-
getResourceAdaptorEntity
String getResourceAdaptorEntity(String linkName) throws NullPointerException, UnrecognizedLinkNameException, ManagementException
- Specified by:
getResourceAdaptorEntity
in interfaceResourceManagementMBean
- Throws:
NullPointerException
UnrecognizedLinkNameException
ManagementException
-
getResourceUsageMBean
ObjectName getResourceUsageMBean(String entityName) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, InvalidArgumentException, ManagementException
- Specified by:
getResourceUsageMBean
in interfaceResourceManagementMBean
- Throws:
NullPointerException
UnrecognizedResourceAdaptorEntityException
InvalidArgumentException
ManagementException
-
getDefaultDesiredState
ResourceAdaptorEntityDesiredState getDefaultDesiredState(String entityName) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, ManagementException
Get the current default desired state of a resource adaptor entity. The default desired state is used when no per-node resource adaptor entity state exists on a given node.
- Parameters:
entityName
- the name of the resource adaptor entity.- Returns:
- the current default desired state of the resource adaptor entity.
- Throws:
NullPointerException
- ifentityName
isnull
.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.ManagementException
- if the state of the resource adaptor entity could not be obtained due to a system-level failure.- Since:
- Rhino 3.0.0
-
getNodesWithDesiredState
int[] getNodesWithDesiredState(String entityName) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, ManagementException
Returns an array of node IDs representing the nodes which currently have per-node desired entity state for the specified resource adaptor entity. This set may include nodes which are not currently part of the cluster.
- Parameters:
entityName
- a resource adaptor entity name.- Returns:
- an array of node IDs.
- Throws:
NullPointerException
- ifentityName
isnull
.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.ManagementException
- if the set of node IDs could could not be determined due to a system-level failure.- Since:
- Rhino 3.0.0
-
setDefaultDesiredState
void setDefaultDesiredState(String entityName, ResourceAdaptorEntityDesiredState state) throws NullPointerException, UnrecognizedResourceAdaptorEntityException, ManagementException
Set the default desired state of a resource adaptor entity. The default desired state is used when no per-node resource adaptor entity state exists on a given node.
- Parameters:
entityName
- the name of the resource adaptor entity.state
- the new default desired state for the resource adaptor entity.- Throws:
NullPointerException
- if either argument isnull
.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.ManagementException
- if the state of the resource adaptor entity could not be set due to a system-level failure.- Since:
- Rhino 3.0.0
-
getPerNodeDesiredState
ResourceAdaptorEntityDesiredState getPerNodeDesiredState(String entityName, int nodeID) throws NullPointerException, InvalidArgumentException, UnrecognizedResourceAdaptorEntityException, ManagementException
Get the current desired state of a resource adaptor entity on the specified node.
If per-node state exists for the resource adaptor entity on the target node then the state contained therein is returned, otherwise
null
is returned instead.- Parameters:
entityName
- the name of the resource adaptor entity.nodeID
- the node ID of the node to return the resource adaptor entity’s desired state for.- Returns:
- the current per-node desired state of the resource adaptor entity on the specified node, or
null
if no per-node desired state exists. - Throws:
NullPointerException
- ifentityName
isnull
.InvalidArgumentException
- ifnodeID
is an invalid node ID.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.ManagementException
- if the state of the resource adaptor entity could not be obtained due to a system-level failure.- Since:
- Rhino 3.0.0
-
getPerNodeDesiredState
ResourceAdaptorEntityDesiredState[] getPerNodeDesiredState(String entityName, int[] nodeIDs) throws NullPointerException, InvalidArgumentException, UnrecognizedResourceAdaptorEntityException, ManagementException
Get the current desired state of a resource adaptor entity for each of the specified nodes.
Where per-node state exists for the resource adaptor entity on a target node then the state contained therein is returned, otherwise a
null
array entry is returned instead for that node.- Parameters:
entityName
- the name of the resource adaptor entity.nodeIDs
- the node IDs of the nodes to return the resource adaptor entity’s desired state for.- Returns:
- an array of resource adaptor entity desired state objects.
This array will be the same length as the supplied
nodeIDs
array, and ifstates = getPerNodeDesiredState(entityName, nodeIDs)
thenstates[i]
equals the desired state of the resource adaptor entity on nodenodeIDs[i]
. If there is no state information for the resource adaptor entity on a particular node, thennull
is returned as the resulting state for the resource adaptor entity on that node. - Throws:
NullPointerException
- if either argument isnull
.InvalidArgumentException
- ifnodeIDs
contains invalid node IDs.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.ManagementException
- if the state of the resource adaptor entity could not be obtained due to a system-level failure.- Since:
- Rhino 3.0.0
-
setPerNodeDesiredState
void setPerNodeDesiredState(String entityName, int[] nodeIDs, ResourceAdaptorEntityDesiredState state) throws NullPointerException, InvalidArgumentException, UnrecognizedResourceAdaptorEntityException, InvalidStateException, ManagementException
Set the current desired state of a resource adaptor entity on each of the specified nodes.
A resource adaptor entity with a default desired state of
ResourceAdaptorEntityDesiredState.non_existent
, ie. one that has been scheduled for removal, must have it’s default desired state changed to a different value before pre-node desired state can be set.- Parameters:
entityName
- the name of the resource adaptor entity.nodeIDs
- the node IDs of the nodes to set the resource adaptor entity’s desired state for.state
- the new desired state for the resource adaptor entity.- Throws:
NullPointerException
- if any argument isnull
.InvalidArgumentException
- ifnodeIDs
contains invalid node IDs.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.InvalidStateException
- if the resource adaptor entity currently has a default desired state ofResourceAdaptorEntityDesiredState.non_existent
.ManagementException
- if the state of the resource adaptor entity could not be set due to a system-level failure.- Since:
- Rhino 3.0.0
-
removePerNodeDesiredState
void removePerNodeDesiredState(String entityName, int[] nodeIDs) throws NullPointerException, InvalidArgumentException, UnrecognizedResourceAdaptorEntityException, ManagementException
Remove the per-node desired state of a resource adaptor entity on each of the specified nodes. This will revert the desired state of the resource adaptor entity on each specified node to the current default desired state.
This method does nothing for any specified node that does not contain any per-node desired state for the resource adaptor entity.
- Parameters:
entityName
- the name of the resource adaptor entity.nodeIDs
- the node IDs of the nodes to set the resource adaptor entity’s desired state for.- Throws:
NullPointerException
- if either argument isnull
.InvalidArgumentException
- ifnodeIDs
contains invalid node IDs.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.ManagementException
- if the per-node desired state of the resource adaptor entity could not be removed due to a system-level failure.- Since:
- Rhino 3.0.0
-
getActualState
ResourceAdaptorEntityActualState[] getActualState(String entityName, int[] nodeIDs) throws NullPointerException, InvalidArgumentException, UnrecognizedResourceAdaptorEntityException, ManagementException
Get the current actual state of a resource adaptor entity for each of the specified nodes.
Where per-node state exists for the resource adaptor entity on a target node then the state contained therein is returned, otherwise a
null
array entry is returned instead for that node.- Parameters:
entityName
- the name of the resource adaptor entity.nodeIDs
- the node IDs of the nodes to return the resource adaptor entity’s actual state for.- Returns:
- an array of resource adaptor entity actual state objects.
This array will be the same length as the supplied
nodeIDs
array, and ifstates = getActualState(entityName, nodeIDs)
thenstates[i]
equals the actual state of the resource adaptor entity on nodenodeIDs[i]
. If there is no state information for the resource adaptor entity on a particular node, thennull
is returned as the resulting state for the resource adaptor entity on that node. - Throws:
NullPointerException
- if either argument isnull
.InvalidArgumentException
- ifnodeIDs
contains invalid node IDs.UnrecognizedResourceAdaptorEntityException
- ifentityName
does not correspond with a resource adaptor entity existing in the SLEE.ManagementException
- if the state of the resource adaptor entity could not be obtained due to a system-level failure.- Since:
- Rhino 3.0.0
-
-