public class ReloadRequiredWriteAttributeHandler extends AbstractWriteAttributeHandler<Void>
AbstractWriteAttributeHandler that triggers putting the process in a restart-required state if attribute that
has flag AttributeAccess.Flag.RESTART_JVM otherwise it puts process in
reload-required state.AbstractWriteAttributeHandler.HandbackHolder<T>| Constructor and Description |
|---|
ReloadRequiredWriteAttributeHandler(AttributeDefinition... definitions) |
ReloadRequiredWriteAttributeHandler(Collection<AttributeDefinition> definitions) |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
applyUpdateToRuntime(OperationContext context,
org.jboss.dmr.ModelNode operation,
String attributeName,
org.jboss.dmr.ModelNode resolvedValue,
org.jboss.dmr.ModelNode currentValue,
AbstractWriteAttributeHandler.HandbackHolder<Void> voidHandback)
Hook to allow subclasses to make runtime changes to effect the attribute value change.
|
protected void |
revertUpdateToRuntime(OperationContext context,
org.jboss.dmr.ModelNode operation,
String attributeName,
org.jboss.dmr.ModelNode valueToRestore,
org.jboss.dmr.ModelNode resolvedValue,
Void handback)
Hook to allow subclasses to revert runtime changes made in
AbstractWriteAttributeHandler.applyUpdateToRuntime(OperationContext, ModelNode, String, ModelNode, ModelNode, HandbackHolder). |
execute, finishModelStage, getAttributeDefinition, recordCapabilitiesAndRequirements, requiresRuntime, validateUpdatedModelpublic ReloadRequiredWriteAttributeHandler(AttributeDefinition... definitions)
public ReloadRequiredWriteAttributeHandler(Collection<AttributeDefinition> definitions)
protected boolean applyUpdateToRuntime(OperationContext context, org.jboss.dmr.ModelNode operation, String attributeName, org.jboss.dmr.ModelNode resolvedValue, org.jboss.dmr.ModelNode currentValue, AbstractWriteAttributeHandler.HandbackHolder<Void> voidHandback) throws OperationFailedException
AbstractWriteAttributeHandlerapplyUpdateToRuntime in class AbstractWriteAttributeHandler<Void>context - the context of the operationoperation - the operationattributeName - the name of the attribute being modifiedresolvedValue - the new value for the attribute, after any ValueExpression has been resolvedcurrentValue - the existing value for the attributevoidHandback - holder for an arbitrary object to pass to
AbstractWriteAttributeHandler.revertUpdateToRuntime(OperationContext, ModelNode, String, ModelNode, ModelNode, Object) if
the operation needs to be rolled backtrue if the server requires reload to effect the attribute
value change; false if notOperationFailedExceptionprotected void revertUpdateToRuntime(OperationContext context, org.jboss.dmr.ModelNode operation, String attributeName, org.jboss.dmr.ModelNode valueToRestore, org.jboss.dmr.ModelNode resolvedValue, Void handback) throws OperationFailedException
AbstractWriteAttributeHandlerAbstractWriteAttributeHandler.applyUpdateToRuntime(OperationContext, ModelNode, String, ModelNode, ModelNode, HandbackHolder).revertUpdateToRuntime in class AbstractWriteAttributeHandler<Void>context - the context of the operationoperation - the operationattributeName - the name of the attribute being modifiedvalueToRestore - the previous value for the attribute, before this operation was executedresolvedValue - the new value for the attribute that should be revertedhandback - an object, if any, passed in to the handbackHolder by the applyUpdateToRuntime
implementationOperationFailedExceptionCopyright © 2018 JBoss by Red Hat. All rights reserved.