public class BindingAddHandler extends SocketBindingAddHandler
Modifier and Type | Field and Description |
---|---|
static BindingAddHandler |
INSTANCE |
OPERATION_NAME
Modifier and Type | Method and Description |
---|---|
static org.jboss.msc.service.ServiceController<SocketBinding> |
installBindingService(OperationContext context,
org.jboss.dmr.ModelNode config,
String name) |
static List<ClientMapping> |
parseClientMappings(org.jboss.dmr.ModelNode mappings) |
protected void |
performRuntime(OperationContext context,
org.jboss.dmr.ModelNode operation,
org.jboss.dmr.ModelNode model,
ServiceVerificationHandler verificationHandler,
List<org.jboss.msc.service.ServiceController<?>> newControllers)
Make any runtime changes necessary to effect the changes indicated by the given
operation . |
protected boolean |
requiresRuntime(OperationContext context)
|
protected boolean |
requiresRuntimeVerification()
Gets whether the
ServiceVerificationHandler parameter passed to
AbstractAddStepHandler.performRuntime(OperationContext, org.jboss.dmr.ModelNode, org.jboss.dmr.ModelNode, ServiceVerificationHandler, java.util.List)
should be added to the operation context as a step. |
getOperation, populateModel
execute, populateModel, populateModel, rollbackRuntime
public static final BindingAddHandler INSTANCE
protected void performRuntime(OperationContext context, org.jboss.dmr.ModelNode operation, org.jboss.dmr.ModelNode model, ServiceVerificationHandler verificationHandler, List<org.jboss.msc.service.ServiceController<?>> newControllers) throws OperationFailedException
AbstractAddStepHandler
operation
. Executes
after AbstractAddStepHandler.populateModel(org.jboss.dmr.ModelNode, org.jboss.dmr.ModelNode)
, so the given model
parameter will reflect any changes made in that method.
This default implementation does nothing.
performRuntime
in class AbstractAddStepHandler
context
- the operation contextoperation
- the operation being executedmodel
- persistent configuration model node that corresponds to the address of operation
verificationHandler
- step handler that can be added as a listener to any new services installed in order to
validate the services installed correctly during the
VERIFY stage
newControllers
- holder for the ServiceController
for any new services installed by the method. The
method should add the ServiceController
for any new services to this list. If the
overall operation needs to be rolled back, the list will be used in
AbstractAddStepHandler.rollbackRuntime(OperationContext, ModelNode, ModelNode, java.util.List)
to automatically removed
the newly added servicesOperationFailedException
- if operation
is invalid or updating the runtime otherwise failsprotected boolean requiresRuntime(OperationContext context)
AbstractAddStepHandler
AbstractAddStepHandler.performRuntime(OperationContext, org.jboss.dmr.ModelNode, org.jboss.dmr.ModelNode, ServiceVerificationHandler, java.util.List)
}
should be called. This default implementation always returns true
. Subclasses that perform no runtime
update could override and return false
.requiresRuntime
in class AbstractAddStepHandler
context
- operation contexttrue
if performRuntime
should be invoked; false
otherwise.protected boolean requiresRuntimeVerification()
AbstractAddStepHandler
ServiceVerificationHandler
parameter passed to
AbstractAddStepHandler.performRuntime(OperationContext, org.jboss.dmr.ModelNode, org.jboss.dmr.ModelNode, ServiceVerificationHandler, java.util.List)
should be added to the operation context as a step.
This default implementation always returns true
.
requiresRuntimeVerification
in class AbstractAddStepHandler
true
if the service verification step should be added; false
if it's not necessary.public static org.jboss.msc.service.ServiceController<SocketBinding> installBindingService(OperationContext context, org.jboss.dmr.ModelNode config, String name) throws UnknownHostException, OperationFailedException
public static List<ClientMapping> parseClientMappings(org.jboss.dmr.ModelNode mappings) throws OperationFailedException
OperationFailedException
Copyright © 2013 JBoss, a division of Red Hat, Inc.. All rights reserved.