Buggy code:
public final class CompositeOperationHandler implements OperationStepHandler { @ Deprecated public static final OperationContext . AttachmentKey < Boolean > DOMAIN_EXECUTION_KEY = AttachmentKey . create ( Boolean . class ) ; public static final CompositeOperationHandler INSTANCE = new CompositeOperationHandler ( ) ; public static final String NAME = ModelDescriptionConstants . COMPOSITE ; private static final AttributeDefinition STEPS = new PrimitiveListAttributeDefinition . Builder ( ModelDescriptionConstants . STEPS , org . jboss . dmr . ModelType . OBJECT ) . build ( ) ; public static final OperationDefinition DEFINITION = new SimpleOperationDefinitionBuilder ( CompositeOperationHandler . NAME , org . jboss . as . controller . descriptions . common . ControllerResolver . getResolver ( "root" ) ) . addParameter ( CompositeOperationHandler . STEPS ) . setReplyType ( ModelType . OBJECT ) . setPrivateEntry ( ) . build ( ) ; private CompositeOperationHandler ( ) { } public void execute ( final OperationContext context , final ModelNode operation ) throws OperationFailedException { CompositeOperationHandler . STEPS . validateOperation ( operation ) ; ImmutableManagementResourceRegistration registry = context . getResourceRegistration ( ) ; final List < ModelNode > list = operation . get ( ModelDescriptionConstants . STEPS ) . asList ( ) ; final ModelNode responseMap = context . getResult ( ) . setEmptyObject ( ) ; Map < String , OperationStepHandler > stepHandlerMap = new HashMap < String , OperationStepHandler > ( ) ; final int size = list . size ( ) ; for ( int i = 0 ; i < size ; i ++ ) { String stepName = "step-" + ( i + 1 ) ; responseMap . get ( stepName ) ; final ModelNode subOperation = list . get ( i ) ; PathAddress stepAddress = PathAddress . pathAddress ( subOperation . get ( OP_ADDR ) ) ; String stepOpName = subOperation . require ( OP ) . asString ( ) ; OperationStepHandler stepHandler = registry . getOperationHandler ( stepAddress , stepOpName ) ; if ( stepHandler == null ) { ImmutableManagementResourceRegistration child = registry . getSubModel ( stepAddress ) ; if ( child == null ) { context . getFailureDescription ( ) . set ( ControllerMessages . MESSAGES . noSuchResourceType ( stepAddress ) ) ; } else { context . getFailureDescription ( ) . set ( ControllerMessages . MESSAGES . noHandlerForOperation ( stepOpName , stepAddress ) ) ; } context . completeStep ( NOOP_ROLLBACK_HANDLER ) ; return ; } stepHandlerMap . put ( stepName , stepHandler ) ; } for ( int i = size - 1 ; i >= 0 ; i -- ) { final ModelNode subOperation = list . get ( i ) ; String stepName = "step-" + ( i + 1 ) ; <START_BUG> context . addStep ( responseMap . get ( stepName ) . setEmptyObject ( ) , subOperation , stepHandlerMap . get ( stepName ) , IMMEDIATE ) ; <END_BUG> } context . completeStep ( new OperationContext . RollbackHandler ( ) { @ Override public void handleRollback ( OperationContext context , ModelNode operation ) { if ( ( context . getAttachment ( org . jboss . as . controller . DOMAIN_EXECUTION_KEY ) ) != null ) { return ; } final ModelNode failureMsg = new ModelNode ( ) ; for ( int i = 0 ; i < size ; i ++ ) { String stepName = "step-" + ( i + 1 ) ; ModelNode stepResponse = responseMap . get ( stepName ) ; if ( stepResponse . hasDefined ( FAILURE_DESCRIPTION ) ) { failureMsg . get ( ControllerMessages . MESSAGES . compositeOperationFailed ( ) , ControllerMessages . MESSAGES . operation ( stepName ) ) . set ( stepResponse . get ( FAILURE_DESCRIPTION ) ) ; } } if ( ! ( failureMsg . isDefined ( ) ) ) { failureMsg . set ( ControllerMessages . MESSAGES . compositeOperationRolledBack ( ) ) ; } context . getFailureDescription ( ) . set ( failureMsg ) ; } } ) ; } }

Fix:
context . addStep ( responseMap . get ( stepName ) . setEmptyObject ( ) , subOperation , stepHandlerMap . get ( stepName ) , MODEL , true ) ;