Package org.jboss.as.model.test
Class FailedOperationTransformationConfig
java.lang.Object
org.jboss.as.model.test.FailedOperationTransformationConfig
Sets up how to handle failed transformation for use with
ModelTestUtils#checkFailedTransformedAddOperation(ModelTestKernelServices, org.jboss.as.controller.ModelVersion, ModelNode, FailedOperationTransformationConfig)- Author:
- Kabir Khan
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classFailedOperationTransformationConfig.AttributesPathAddressConfig<T extends FailedOperationTransformationConfig.AttributesPathAddressConfig<T>>static interfaceA callback that can be used to e.g. make adjustments to the model before transforming and executing the composite resulting from the transformation of the boot operationsstatic classA standard configuration that allows several checkers to be used for an attribute.static classA standard configuration for theDiscardUndefinedAttributesTransformerfor use with attributes that are new in a version.static interfaceConfiguration of how to deal with rejected operations transformations for a PathAddress.static classA standard configuration for the reject expression values transformer -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddFailedAttribute(org.jboss.as.controller.PathAddress pathAddress, FailedOperationTransformationConfig.PathAddressConfig config) Add a handler for failed operation transformers at a resource addressvoidoperationDone(org.jboss.dmr.ModelNode operation) Sets a callback that gets executed before transforming and executing the resulting composite.THe default behaviour is to add the original operations to a composite, once they have been 'fixed'.
-
Field Details
-
NO_FAILURES
-
DISCARDED_RESOURCE
-
REJECTED_RESOURCE
-
-
Constructor Details
-
FailedOperationTransformationConfig
public FailedOperationTransformationConfig()
-
-
Method Details
-
addFailedAttribute
public FailedOperationTransformationConfig addFailedAttribute(org.jboss.as.controller.PathAddress pathAddress, FailedOperationTransformationConfig.PathAddressConfig config) Add a handler for failed operation transformers at a resource address- Parameters:
pathAddress- the path addressconfig- the config- Returns:
- this config
-
setDontTransformComposite
THe default behaviour is to add the original operations to a composite, once they have been 'fixed'. That composite is then transformed before executing it in the legacy controller. However some transformers rely on inspecting the model, and use aconfigthat changes the model. For these cases, we can call this method, which instead adds the transformed and fully 'fixed' operations to the resulting composite.- Returns:
- this config
-
setCallback
public FailedOperationTransformationConfig setCallback(FailedOperationTransformationConfig.BeforeExecuteCompositeCallback callback) Sets a callback that gets executed before transforming and executing the resulting composite.- Parameters:
callback- the callback- Returns:
- this config
-
operationDone
public void operationDone(org.jboss.dmr.ModelNode operation)
-