public class ResourceGroupLifeCycleRuntime extends DomainRuntimeMBeanDelegate implements ResourceGroupLifeCycleRuntimeMBean
Provides methods that transition resource groups from one state to another.
Modifier and Type | Class and Description |
---|---|
private class |
ResourceGroupLifeCycleRuntime.PersistResourceGroupDesiredState |
private class |
ResourceGroupLifeCycleRuntime.ResourceGroupLifecycleRequest |
Modifier and Type | Field and Description |
---|---|
private static boolean |
DEBUG |
private static java.util.Properties |
DO_NOT_START_PROPS |
private static weblogic.invocation.ComponentInvocationContext |
DOMAIN_CIC |
private DomainRuntimeServiceMBean |
domainRuntimeServiceMBean |
private static weblogic.security.acl.internal.AuthenticatedSubject |
kernelId |
private weblogic.invocation.ComponentInvocationContext |
PARTITION_CIC |
private java.lang.String |
partitionName |
private PartitionRuntimeStateManagerContract |
partitionRuntimeStateManager |
private static java.lang.String |
PTN_DELIMITER |
private ResourceGroupMBean |
resourceGroupMBean |
private ResourceGroupLifecycleOperations.RGState |
state |
static java.lang.String |
STATE_PROPERTY_NAME |
private static int |
TASK_AFTERLIFE_TIME_MILLIS |
private java.util.Set<ResourceGroupLifeCycleTaskRuntimeMBean> |
tasks |
private static boolean |
USE_OLD_STATE_NAMES |
descriptor, name, parent, registered, type
Constructor and Description |
---|
ResourceGroupLifeCycleRuntime(ResourceGroupMBean resourceGroupMBean,
DomainRuntimeMBeanDelegate parentRuntime,
java.beans.PropertyChangeListener listener) |
Modifier and Type | Method and Description |
---|---|
private ResourceGroupLifeCycleTaskRuntime |
alreadyCompletedTask(ResourceGroupLifecycleOperations.RGOperation operation) |
void |
clearOldResourceGroupLifeCycleTaskRuntimes() |
private ResourceGroupLifecycleOperations.RGState |
computeState() |
private ResourceGroupLifeCycleTaskRuntime |
createTaskMbean(ResourceGroupLifecycleOperations.RGOperation operation,
java.lang.String operationMsg,
java.lang.String serverName) |
private static void |
debug(java.lang.String debugMessage) |
ResourceGroupLifeCycleTaskRuntimeMBean |
forceShutdown()
Begins to force the shutdown of this resource group on all targeted servers, changing its state to
SHUTDOWN . |
ResourceGroupLifeCycleTaskRuntimeMBean |
forceShutdown(java.lang.String[] targetNames)
Begins to force the shutdown of this resource group on the specified targets, changing its state to
SHUTDOWN . |
ResourceGroupLifeCycleTaskRuntimeMBean |
forceShutdown(TargetMBean[] targets)
Begins to force the shutdown of this resource group on the specified targets, changing its state to
SHUTDOWN . |
ResourceGroupLifeCycleTaskRuntimeMBean |
forceSuspend()
Begins the forceful transition of this resource group from the
RUNNING state to the ADMIN state on all targeted servers. |
ResourceGroupLifeCycleTaskRuntimeMBean |
forceSuspend(java.lang.String[] targetNames)
Begins the forceful transition of this resource group from the
RUNNING state to the ADMIN state on the specified targets. |
ResourceGroupLifeCycleTaskRuntimeMBean |
forceSuspend(TargetMBean[] targets)
Begins the forceful transition of this resource group from the
RUNNING state to the ADMIN state on the specified targets. |
private static weblogic.invocation.ComponentInvocationContext |
getDomainCIC() |
ResourceGroupLifecycleOperations.RGState |
getInternalState()
The internal state enum value.
|
private weblogic.invocation.ComponentInvocationContext |
getPartitionCIC() |
java.lang.String |
getState()
The current overall state of the resource group.
|
java.lang.String |
getState(ServerMBean serverMBean)
The state of resource group on a specific server.
|
java.lang.String |
getState(java.lang.String serverName)
The current state of the resource group on a specific server.
|
private java.lang.String[] |
getSvrsForSettingDesiredState(java.util.Set<java.lang.String> targets,
boolean targetsSpecified) |
ResourceGroupLifeCycleTaskRuntimeMBean[] |
getTasks()
The preexisting resource group lifecycle tasks
|
private ResourceGroupLifeCycleTaskRuntime |
initiateRGLifecycleRequest(TargetMBean[] targets,
ResourceGroupLifecycleOperations.RGOperation operation,
java.lang.String msg,
boolean targetsSpecified) |
private ResourceGroupLifeCycleTaskRuntime |
initiateRGLifecycleRequest(TargetMBean[] targets,
ResourceGroupLifecycleOperations.RGOperation operation,
java.lang.String msg,
int timeout,
boolean ignoreSessions,
boolean targetsSpecified) |
private ResourceGroupLifeCycleTaskRuntime |
initiateRGLifecycleRequest(TargetMBean[] targets,
ResourceGroupLifecycleOperations.RGOperation operation,
java.lang.String msg,
int timeout,
boolean ignoreSessions,
boolean waitForAllSessions,
boolean targetsSpecified) |
private boolean |
isDomainRGSameState(java.lang.String resourceGroupName,
ServerRuntimeMBean svrRuntime,
java.lang.String state) |
private boolean |
isServerActionNeeded(java.lang.String server,
java.lang.String resourceGroupName,
ResourceGroupLifecycleOperations.RGState state) |
private void |
logRGAlreadyExpectedState(java.lang.String operationName) |
ResourceGroupLifeCycleTaskRuntimeMBean |
lookupTask(java.lang.String taskName)
The preexisting partition lifecycle task.
|
void |
markStarted() |
private static java.util.Properties |
prepDoNotStartProps() |
void |
purgeTasks()
Clears the retained task collection.
|
ResourceGroupLifeCycleTaskRuntimeMBean |
resume()
Begins the transition of this resource group from the
ADMIN state to the RUNNING
state on all targeted servers. |
ResourceGroupLifeCycleTaskRuntimeMBean |
resume(java.lang.String[] targetNames)
Begins the transition of this resource group from the
ADMIN state to the RUNNING
state on the specified targets. |
ResourceGroupLifeCycleTaskRuntimeMBean |
resume(TargetMBean[] targets)
Begins the transition of this resource group from the
ADMIN state to the RUNNING
state on the specified targets. |
void |
setState(ResourceGroupLifecycleOperations.RGState newState) |
ResourceGroupLifeCycleTaskRuntimeMBean |
shutdown()
Begins to shut down the resource group gracefully on all targeted servers, changing its state to
SHUTDOWN . |
ResourceGroupLifeCycleTaskRuntimeMBean |
shutdown(int timeout,
boolean ignoreSessions)
Begins to shut down this resource group gracefully on all targeted servers, changing its state to
SHUTDOWN . |
ResourceGroupLifeCycleTaskRuntimeMBean |
shutdown(int timeout,
boolean ignoreSessions,
boolean waitForAllSessions)
Begins to shut down this resource group gracefully on all targeted servers, changing its state to
SHUTDOWN . |
ResourceGroupLifeCycleTaskRuntimeMBean |
shutdown(int timeout,
boolean ignoreSessions,
boolean waitForAllSessions,
java.lang.String[] targetNames)
Begins to shut down this resource group gracefully on the specified targets, changing its state to
SHUTDOWN . |
ResourceGroupLifeCycleTaskRuntimeMBean |
shutdown(int timeout,
boolean ignoreSessions,
boolean waitForAllSessions,
TargetMBean[] targets)
Begins to shut down this resource group gracefully on the specified targets, changing its state to
SHUTDOWN . |
ResourceGroupLifeCycleTaskRuntimeMBean |
shutdown(int timeout,
boolean ignoreSessions,
java.lang.String[] targetNames)
Begins to shut down this resource group gracefully on the specified targets, changing its state to
SHUTDOWN . |
ResourceGroupLifeCycleTaskRuntimeMBean |
shutdown(int timeout,
boolean ignoreSessions,
TargetMBean[] targets)
Begins to shut down this resource group gracefully on the specified targets, changing its state to
SHUTDOWN . |
ResourceGroupLifeCycleTaskRuntimeMBean |
shutdown(java.lang.String[] targetNames)
Begins to shut down this resource group gracefully on the specified targets, changing its state to
SHUTDOWN . |
ResourceGroupLifeCycleTaskRuntimeMBean |
shutdown(TargetMBean[] targets)
Begins to shut down this resource group gracefully on the specified targets, changing its state to
SHUTDOWN . |
ResourceGroupLifeCycleTaskRuntimeMBean |
start()
Begins to start this resource group on all targeted servers, changing its state to
RUNNING . |
ResourceGroupLifeCycleTaskRuntimeMBean |
start(java.lang.String[] targetNames)
Begins to start this resource group on the specified targets, changing its state to
RUNNING . |
ResourceGroupLifeCycleTaskRuntimeMBean |
start(TargetMBean[] targets)
Begins to start this resource group on the specified targets, changing its state to
RUNNING . |
ResourceGroupLifeCycleTaskRuntimeMBean |
startInAdmin()
Begins to start this resource group in the admin state on all targeted servers, changing its state to
ADMIN . |
ResourceGroupLifeCycleTaskRuntimeMBean |
startInAdmin(java.lang.String[] targetNames)
Begins to start this resource group in the admin state on the specified targets, changing its state to
ADMIN . |
ResourceGroupLifeCycleTaskRuntimeMBean |
startInAdmin(TargetMBean[] targets)
Begins to start this resource group in the admin state on the specified targets, changing its state to
ADMIN . |
ResourceGroupLifecycleOperations.RGState |
state() |
private ResourceGroupLifecycleOperations.RGState |
stateForServer(java.lang.String server) |
ResourceGroupLifeCycleTaskRuntimeMBean |
suspend()
Begins the graceful transition of this resource group from the
RUNNING state to the ADMIN state on all targeted servers. |
ResourceGroupLifeCycleTaskRuntimeMBean |
suspend(int timeout,
boolean ignoreSessions)
Begins to transition the resource group from
RUNNING to
ADMIN state gracefully on all targeted servers. |
ResourceGroupLifeCycleTaskRuntimeMBean |
suspend(int timeout,
boolean ignoreSessions,
java.lang.String[] targetNames)
Begins to transition this resource group from
RUNNING to
ADMIN state gracefully on the specified targets. |
ResourceGroupLifeCycleTaskRuntimeMBean |
suspend(int timeout,
boolean ignoreSessions,
TargetMBean[] targets)
Begins to transition this resource group from
RUNNING to
ADMIN state gracefully on the specified targets. |
ResourceGroupLifeCycleTaskRuntimeMBean |
suspend(java.lang.String[] targetNames)
Begins the graceful transition of this resource group from the
RUNNING state to the ADMIN state on the specified targets. |
ResourceGroupLifeCycleTaskRuntimeMBean |
suspend(TargetMBean[] targets)
Begins the graceful transition of this resource group from the
RUNNING state to the ADMIN state on the specified targets. |
private void |
updateStoreForDesiredState(ResourceGroupLifecycleOperations.RGState state,
java.lang.String... servers) |
private static void |
updateTaskMBeanOnCompletion(ResourceGroupLifeCycleTaskRuntime rlcTaskRuntime) |
getRegistrationManager
_createHelper, _postSet, _postSet, _postSet, _postSet, _postSet, addChild, addNotificationListener, addPropertyChangeListener, createChildCopy, getAttribute, getAttributes, getMBeanInfo, getMetaData, getName, getNotificationInfo, getObjectName, getParent, getParentAttribute, getPropertyChangeListeners, getRestParent, getType, invoke, isCachingDisabled, isEditable, isRegistered, pluralize, postDeregister, postRegister, preDeregister, preRegister, register, removeChild, removeNotificationListener, removePropertyChangeListener, setAttribute, setAttributes, setMetaData, setName, setParent, setRestParent, setRuntimeMBeanHelper, setType, unregister
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addPropertyChangeListener, preDeregister, removePropertyChangeListener
getMBeanInfo, getName, getObjectName, getParent, getType, isCachingDisabled, isRegistered, setName, setParent
getAttribute, getAttributes, invoke, setAttribute, setAttributes
private static final weblogic.security.acl.internal.AuthenticatedSubject kernelId
private static final java.util.Properties DO_NOT_START_PROPS
private static final int TASK_AFTERLIFE_TIME_MILLIS
private static final boolean USE_OLD_STATE_NAMES
private static weblogic.invocation.ComponentInvocationContext DOMAIN_CIC
private final java.util.Set<ResourceGroupLifeCycleTaskRuntimeMBean> tasks
private final ResourceGroupMBean resourceGroupMBean
private final java.lang.String partitionName
private weblogic.invocation.ComponentInvocationContext PARTITION_CIC
private static final java.lang.String PTN_DELIMITER
public static final java.lang.String STATE_PROPERTY_NAME
private final DomainRuntimeServiceMBean domainRuntimeServiceMBean
private final PartitionRuntimeStateManagerContract partitionRuntimeStateManager
private ResourceGroupLifecycleOperations.RGState state
private static final boolean DEBUG
public ResourceGroupLifeCycleRuntime(ResourceGroupMBean resourceGroupMBean, DomainRuntimeMBeanDelegate parentRuntime, java.beans.PropertyChangeListener listener) throws ManagementException
ManagementException
private static java.util.Properties prepDoNotStartProps()
private static weblogic.invocation.ComponentInvocationContext getDomainCIC()
private weblogic.invocation.ComponentInvocationContext getPartitionCIC()
public ResourceGroupLifeCycleTaskRuntimeMBean start() throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to start this resource group on all targeted servers, changing its state to RUNNING
.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
start
in interface ResourceGroupLifeCycleRuntimeMBean
ResourceGroupLifecycleException
- if start operation failspublic java.lang.String getState()
ResourceGroupLifeCycleRuntimeMBean
The current overall state of the resource group.
The value returned is the highest state for the resource group on all servers where it is targeted.
As a result, the overall resource group state can change (for example, to RUNNING
)
as soon as the operation (such as start) has finished on one server, even while the operation is still in progress elsewhere.
If the resource group is not currently targeted to any running server then its reported state is the desired state indicated by the most recent resource group life cycle operation on the resource group.
getState
in interface ResourceGroupLifeCycleRuntimeMBean
public java.lang.String getState(ServerMBean serverMBean) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Please use ResourceGroupLifeCycleTaskRuntimeMBean.getState(String serverName)
getState
in interface ResourceGroupLifeCycleRuntimeMBean
ResourceGroupLifecycleException
public java.lang.String getState(java.lang.String serverName) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
getState
in interface ResourceGroupLifeCycleRuntimeMBean
serverName
- name of the server to checkResourceGroupLifecycleException
public ResourceGroupLifecycleOperations.RGState getInternalState()
ResourceGroupLifeCycleRuntimeMBean
getInternalState
in interface ResourceGroupLifeCycleRuntimeMBean
private ResourceGroupLifecycleOperations.RGState computeState()
private ResourceGroupLifecycleOperations.RGState stateForServer(java.lang.String server)
public ResourceGroupLifeCycleTaskRuntimeMBean[] getTasks()
ResourceGroupLifeCycleRuntimeMBean
getTasks
in interface ResourceGroupLifeCycleRuntimeMBean
public ResourceGroupLifeCycleTaskRuntimeMBean lookupTask(java.lang.String taskName)
ResourceGroupLifeCycleRuntimeMBean
The preexisting partition lifecycle task.
lookupTask
in interface ResourceGroupLifeCycleRuntimeMBean
public ResourceGroupLifeCycleTaskRuntimeMBean start(TargetMBean[] targets) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to start this resource group on the specified targets, changing its state to RUNNING
.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
Please use ResourceGroupLifeCycleTaskRuntimeMBean.start(String[] targetNames)
start
in interface ResourceGroupLifeCycleRuntimeMBean
targets
- the specific targets on which to start this resource groupResourceGroupLifecycleException
- if the start failspublic ResourceGroupLifeCycleTaskRuntimeMBean start(java.lang.String[] targetNames) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to start this resource group on the specified targets, changing its state to RUNNING
.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
start
in interface ResourceGroupLifeCycleRuntimeMBean
targetNames
- the specific servers on which to start this resource groupResourceGroupLifecycleException
- if the start failspublic ResourceGroupLifeCycleTaskRuntimeMBean startInAdmin(TargetMBean[] targets) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to start this resource group in the admin state on the specified targets, changing its state to ADMIN
.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
Please use ResourceGroupLifeCycleTaskRuntimeMBean.startInAdmin(String[] targetNames)
startInAdmin
in interface ResourceGroupLifeCycleRuntimeMBean
targets
- the specific targets on which to start this resource group in "admin" stateResourceGroupLifecycleException
- if the start failspublic ResourceGroupLifeCycleTaskRuntimeMBean startInAdmin(java.lang.String[] targetNames) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to start this resource group in the admin state on the specified targets, changing its state to ADMIN
.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
startInAdmin
in interface ResourceGroupLifeCycleRuntimeMBean
targetNames
- the specific servers on which to start this resource group in "admin" stateResourceGroupLifecycleException
- if the start failspublic ResourceGroupLifeCycleTaskRuntimeMBean startInAdmin() throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to start this resource group in the admin state on all targeted servers, changing its state to ADMIN
.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
startInAdmin
in interface ResourceGroupLifeCycleRuntimeMBean
ResourceGroupLifecycleException
- if the start failspublic ResourceGroupLifeCycleTaskRuntimeMBean shutdown(int timeout, boolean ignoreSessions, boolean waitForAllSessions) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
SHUTDOWN
.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
shutdown
in interface ResourceGroupLifeCycleRuntimeMBean
timeout
- Number of seconds to wait before aborting inflight work
and force shutting down the server.ignoreSessions
- Set to true
to ignore pending HTTP
sessions during inflight work handling.waitForAllSessions
- Set to true
to wait for all HTTP sessions
duirng inflight work handling; false
to wait for non-persisted
HTTP sessions only.ResourceGroupLifecycleException
- If the resource group fails to gracefully
shutdown. A ResourceGroupLifeCycleRuntimeMBean.forceShutdown()
operation can be invoked.public ResourceGroupLifeCycleTaskRuntimeMBean shutdown(int timeout, boolean ignoreSessions, boolean waitForAllSessions, TargetMBean[] targets) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
SHUTDOWN
.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
Please use ResourceGroupLifeCycleTaskRuntimeMBean.shutdown(int timeout, boolean ignoreSessions, boolean waitForAllSessions, TargetMBean[] targets)
shutdown
in interface ResourceGroupLifeCycleRuntimeMBean
timeout
- Number of seconds to wait before aborting inflight work
and force shutting down the server.ignoreSessions
- Set to true
to ignore pending HTTP
sessions during inflight work handling.waitForAllSessions
- Set to true
to wait for all HTTP sessions
duirng inflight work handling; false
to wait for non-persisted
HTTP sessions only.targets
- the specific targets on which to shut down this resource groupResourceGroupLifecycleException
- If the resource group fails to gracefully
shutdown. A ResourceGroupLifeCycleRuntimeMBean.forceShutdown()
operation can be invoked.public ResourceGroupLifeCycleTaskRuntimeMBean shutdown(int timeout, boolean ignoreSessions, boolean waitForAllSessions, java.lang.String[] targetNames) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
SHUTDOWN
.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
shutdown
in interface ResourceGroupLifeCycleRuntimeMBean
timeout
- Number of seconds to wait before aborting inflight work
and force shutting down the server.ignoreSessions
- Set to true
to ignore pending HTTP
sessions during inflight work handling.waitForAllSessions
- Set to true
to wait for all HTTP sessions
duirng inflight work handling; false
to wait for non-persisted
HTTP sessions only.targetNames
- the specific servers on which to shut down this resource groupResourceGroupLifecycleException
- If the resource group fails to gracefully
shutdown. A ResourceGroupLifeCycleRuntimeMBean.forceShutdown()
operation can be invoked.public ResourceGroupLifeCycleTaskRuntimeMBean shutdown(int timeout, boolean ignoreSessions, TargetMBean[] targets) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to shut down this resource group gracefully on the specified targets, changing its state to SHUTDOWN
.
(equivalent to shutdown(timeout, ignoreSessions, false, targets)).
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
Please use ResourceGroupLifeCycleTaskRuntimeMBean.shutdown(int timeout, boolean ignoreSessions, String[] targetNames)
shutdown
in interface ResourceGroupLifeCycleRuntimeMBean
timeout
- Number of seconds to wait before aborting
inflight work and shutting down the server.ignoreSessions
- true
indicates ignore pending
HTTP sessions during inflight work handling.targets
- the specific targets on which to shut down this resource groupResourceGroupLifecycleException
- Thrown if the resource group cannot
gracefully shutdown. Use the forceShutdown command to shutdown the resource group.public ResourceGroupLifeCycleTaskRuntimeMBean shutdown(int timeout, boolean ignoreSessions, java.lang.String[] targetNames) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to shut down this resource group gracefully on the specified targets, changing its state to SHUTDOWN
.
(equivalent to shutdown(timeout, ignoreSessions, false, targets)).
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
shutdown
in interface ResourceGroupLifeCycleRuntimeMBean
timeout
- Number of seconds to wait before aborting
inflight work and shutting down the server.ignoreSessions
- true
indicates ignore pending
HTTP sessions during inflight work handling.targetNames
- the specific servers on which to shut down this resource groupResourceGroupLifecycleException
- Thrown if the resource group cannot
gracefully shutdown. Use the forceShutdown command to shutdown the resource group.public ResourceGroupLifeCycleTaskRuntimeMBean shutdown(int timeout, boolean ignoreSessions) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to shut down this resource group gracefully on all targeted servers, changing its state to SHUTDOWN
.
(equivalent to shutdown(timeout, ignoreSessions, false)).
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
shutdown
in interface ResourceGroupLifeCycleRuntimeMBean
timeout
- Number of seconds to wait before aborting
inflight work and shutting down the server.ignoreSessions
- true
indicates ignore pending
HTTP sessions during inflight work handling.ResourceGroupLifecycleException
- Thrown if the resource group cannot
gracefully shutdown. Use the forceShutdown command to shutdown the resource group.public ResourceGroupLifeCycleTaskRuntimeMBean shutdown(TargetMBean[] targets) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to shut down this resource group gracefully on the specified targets, changing its state to SHUTDOWN
.
(equivalent to shutdown(targets, 0, false)).
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
Please use ResourceGroupLifeCycleTaskRuntimeMBean.shutdown(String[] targetNames)
shutdown
in interface ResourceGroupLifeCycleRuntimeMBean
targets
- the specific targets on which to start this resource groupResourceGroupLifecycleException
- if the shutdown failspublic ResourceGroupLifeCycleTaskRuntimeMBean shutdown(java.lang.String[] targetNames) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to shut down this resource group gracefully on the specified targets, changing its state to SHUTDOWN
.
(equivalent to shutdown(targets, 0, false)).
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
shutdown
in interface ResourceGroupLifeCycleRuntimeMBean
targetNames
- the specific servers on which to shut down this resource groupResourceGroupLifecycleException
- if the shutdown failspublic ResourceGroupLifeCycleTaskRuntimeMBean shutdown() throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to shut down the resource group gracefully on all targeted servers, changing its state to SHUTDOWN
.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
shutdown
in interface ResourceGroupLifeCycleRuntimeMBean
ResourceGroupLifecycleException
- if the shutdown failspublic ResourceGroupLifeCycleTaskRuntimeMBean forceShutdown(TargetMBean[] targets) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to force the shutdown of this resource group on the specified targets, changing its state to SHUTDOWN
.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
Please use ResourceGroupLifeCycleTaskRuntimeMBean.forceShutdown(String[] targetNames)
forceShutdown
in interface ResourceGroupLifeCycleRuntimeMBean
targets
- the specific targets on which to force a shutdown on this resource groupResourceGroupLifecycleException
- if the resource group fails to shut downpublic ResourceGroupLifeCycleTaskRuntimeMBean forceShutdown(java.lang.String[] targetNames) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to force the shutdown of this resource group on the specified targets, changing its state to SHUTDOWN
.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
forceShutdown
in interface ResourceGroupLifeCycleRuntimeMBean
targetNames
- the specific servers on which to force a shutdown on this resource groupResourceGroupLifecycleException
- if the resource group fails to shut downpublic ResourceGroupLifeCycleTaskRuntimeMBean forceShutdown() throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
Begins to force the shutdown of this resource group on all targeted servers, changing its state to SHUTDOWN
.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
forceShutdown
in interface ResourceGroupLifeCycleRuntimeMBean
ResourceGroupLifecycleException
- if the resource group fails to shut downpublic ResourceGroupLifeCycleTaskRuntimeMBean suspend(int timeout, boolean ignoreSessions, TargetMBean[] targets) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
RUNNING
to
ADMIN
state gracefully on the specified targets.
Applications are in admin mode. Inflight work is completed.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
Please use ResourceGroupLifeCycleTaskRuntimeMBean.suspend(timeout, boolean ignoreSessions, String[] targetNames)
suspend
in interface ResourceGroupLifeCycleRuntimeMBean
timeout
- Seconds to wait for the resource group to transition gracefully.
The resource group automatically calls ResourceGroupLifeCycleRuntimeMBean.forceSuspend()
after timeout.ignoreSessions
- drop inflight HTTP sessions during graceful suspendtargets
- the specific targets on which to start this resource groupResourceGroupLifecycleException
- resource group failed to suspend gracefully.
A ResourceGroupLifeCycleRuntimeMBean.forceSuspend()
or a ResourceGroupLifeCycleRuntimeMBean.forceShutdown()
operation can be
invoked.public ResourceGroupLifeCycleTaskRuntimeMBean suspend(int timeout, boolean ignoreSessions, java.lang.String[] targetNames) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
RUNNING
to
ADMIN
state gracefully on the specified targets.
Applications are in admin mode. Inflight work is completed.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
suspend
in interface ResourceGroupLifeCycleRuntimeMBean
timeout
- Seconds to wait for the resource group to transition gracefully.
The resource group automatically calls ResourceGroupLifeCycleRuntimeMBean.forceSuspend()
after timeout.ignoreSessions
- drop inflight HTTP sessions during graceful suspendtargetNames
- the specific servers on which to suspend this resource groupResourceGroupLifecycleException
- resource group failed to suspend gracefully.
A ResourceGroupLifeCycleRuntimeMBean.forceSuspend()
or a ResourceGroupLifeCycleRuntimeMBean.forceShutdown()
operation can be
invoked.public ResourceGroupLifeCycleTaskRuntimeMBean suspend(int timeout, boolean ignoreSessions) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
RUNNING
to
ADMIN
state gracefully on all targeted servers.
Applications are in admin mode. Inflight work is completed.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
suspend
in interface ResourceGroupLifeCycleRuntimeMBean
timeout
- Seconds to wait for the resource group to transition gracefully.
The resource group automatically calls ResourceGroupLifeCycleRuntimeMBean.forceSuspend()
after timeout.ignoreSessions
- drop inflight HTTP sessions during graceful suspendResourceGroupLifecycleException
- resource group failed to suspend gracefully.
A ResourceGroupLifeCycleRuntimeMBean.forceSuspend()
or a ResourceGroupLifeCycleRuntimeMBean.forceShutdown()
operation can be
invoked.public ResourceGroupLifeCycleTaskRuntimeMBean suspend(TargetMBean[] targets) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
RUNNING
state to the ADMIN
state on the specified targets.
(equivalent to suspend(0, false, targets))
New requests
are rejected and inflight work is allowed to complete.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
Please use ResourceGroupLifeCycleTaskRuntimeMBean.suspend(String[] targetNames)
suspend
in interface ResourceGroupLifeCycleRuntimeMBean
targets
- the specific targets on which to start this resource groupResourceGroupLifecycleException
- If the operation failsResourceGroupLifeCycleRuntimeMBean.suspend(int, boolean)
public ResourceGroupLifeCycleTaskRuntimeMBean suspend(java.lang.String[] targetNames) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
RUNNING
state to the ADMIN
state on the specified targets.
(equivalent to suspend(0, false, targets))
New requests
are rejected and inflight work is allowed to complete.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
suspend
in interface ResourceGroupLifeCycleRuntimeMBean
targetNames
- the specific servers on which to suspend this resource groupResourceGroupLifecycleException
- If the operation failsResourceGroupLifeCycleRuntimeMBean.suspend(int, boolean)
public ResourceGroupLifeCycleTaskRuntimeMBean suspend() throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
RUNNING
state to the ADMIN
state on all targeted servers.
(equivalent to suspend(0, false))
New requests
are rejected and inflight work is allowed to complete.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
suspend
in interface ResourceGroupLifeCycleRuntimeMBean
ResourceGroupLifecycleException
- If the operation failsResourceGroupLifeCycleRuntimeMBean.suspend(int, boolean)
public ResourceGroupLifeCycleTaskRuntimeMBean forceSuspend(TargetMBean[] targets) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
RUNNING
state to the ADMIN
state on the specified targets.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
Please use ResourceGroupLifeCycleTaskRuntimeMBean.forceSuspend(String[] targetNames)
forceSuspend
in interface ResourceGroupLifeCycleRuntimeMBean
targets
- the specific targets on which to start this resource groupResourceGroupLifecycleException
- the resource group could not suspend.public ResourceGroupLifeCycleTaskRuntimeMBean forceSuspend(java.lang.String[] targetNames) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
RUNNING
state to the ADMIN
state on the specified targets.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
forceSuspend
in interface ResourceGroupLifeCycleRuntimeMBean
targetNames
- the specific servers on which to force a suspend of this resource groupResourceGroupLifecycleException
- the resource group could not suspend.public ResourceGroupLifeCycleTaskRuntimeMBean forceSuspend() throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
RUNNING
state to the ADMIN
state on all targeted servers.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
forceSuspend
in interface ResourceGroupLifeCycleRuntimeMBean
ResourceGroupLifecycleException
- the resource group could not suspend.public ResourceGroupLifeCycleTaskRuntimeMBean resume(TargetMBean[] targets) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
ADMIN
state to the RUNNING
state on the specified targets.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
Please use ResourceGroupLifeCycleTaskRuntimeMBean.resume(String[] targetNames)
resume
in interface ResourceGroupLifeCycleRuntimeMBean
targets
- the specific targets on which to start this resource groupResourceGroupLifecycleException
- If the resume operation failspublic ResourceGroupLifeCycleTaskRuntimeMBean resume(java.lang.String[] targetNames) throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
ADMIN
state to the RUNNING
state on the specified targets.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
resume
in interface ResourceGroupLifeCycleRuntimeMBean
targetNames
- the specific servers on which to resume this resource groupResourceGroupLifecycleException
- If the resume operation failspublic ResourceGroupLifeCycleTaskRuntimeMBean resume() throws ResourceGroupLifecycleException
ResourceGroupLifeCycleRuntimeMBean
ADMIN
state to the RUNNING
state on all targeted servers.
Use the returned ResourceGroupLifeCycleTaskRuntimeMBean
value to check for completion.
resume
in interface ResourceGroupLifeCycleRuntimeMBean
ResourceGroupLifecycleException
- If the resume operation failspublic void purgeTasks()
ResourceGroupLifeCycleRuntimeMBean
purgeTasks
in interface ResourceGroupLifeCycleRuntimeMBean
public ResourceGroupLifecycleOperations.RGState state()
public void setState(ResourceGroupLifecycleOperations.RGState newState)
public void markStarted()
private ResourceGroupLifeCycleTaskRuntime createTaskMbean(ResourceGroupLifecycleOperations.RGOperation operation, java.lang.String operationMsg, java.lang.String serverName) throws ManagementException
ManagementException
private ResourceGroupLifeCycleTaskRuntime initiateRGLifecycleRequest(TargetMBean[] targets, ResourceGroupLifecycleOperations.RGOperation operation, java.lang.String msg, boolean targetsSpecified) throws ResourceGroupLifecycleException
ResourceGroupLifecycleException
private ResourceGroupLifeCycleTaskRuntime initiateRGLifecycleRequest(TargetMBean[] targets, ResourceGroupLifecycleOperations.RGOperation operation, java.lang.String msg, int timeout, boolean ignoreSessions, boolean targetsSpecified) throws ResourceGroupLifecycleException
ResourceGroupLifecycleException
private ResourceGroupLifeCycleTaskRuntime initiateRGLifecycleRequest(TargetMBean[] targets, ResourceGroupLifecycleOperations.RGOperation operation, java.lang.String msg, int timeout, boolean ignoreSessions, boolean waitForAllSessions, boolean targetsSpecified) throws ResourceGroupLifecycleException
ResourceGroupLifecycleException
private void logRGAlreadyExpectedState(java.lang.String operationName)
private ResourceGroupLifeCycleTaskRuntime alreadyCompletedTask(ResourceGroupLifecycleOperations.RGOperation operation) throws ManagementException, ResourceGroupLifecycleException
private static void updateTaskMBeanOnCompletion(ResourceGroupLifeCycleTaskRuntime rlcTaskRuntime)
public void clearOldResourceGroupLifeCycleTaskRuntimes()
private boolean isServerActionNeeded(java.lang.String server, java.lang.String resourceGroupName, ResourceGroupLifecycleOperations.RGState state) throws ResourceGroupLifecycleException
ResourceGroupLifecycleException
private boolean isDomainRGSameState(java.lang.String resourceGroupName, ServerRuntimeMBean svrRuntime, java.lang.String state) throws ResourceGroupLifecycleException
ResourceGroupLifecycleException
private void updateStoreForDesiredState(ResourceGroupLifecycleOperations.RGState state, java.lang.String... servers) throws ResourceGroupLifecycleException
ResourceGroupLifecycleException
private java.lang.String[] getSvrsForSettingDesiredState(java.util.Set<java.lang.String> targets, boolean targetsSpecified)
private static void debug(java.lang.String debugMessage)