Buggy code:
public class DomainSlaveHandler implements NewStepHandler { private static final Logger log = Logger . getLogger ( "org.jboss.as.controller" ) ; private final ExecutorService executorService ; private final DomainOperationContext domainOperationContext ; private final Map < String , NewProxyController > hostProxies ; public DomainSlaveHandler ( final Map < String , NewProxyController > hostProxies , final DomainOperationContext domainOperationContext , final ExecutorService executorService ) { } @ Override public void execute ( final NewOperationContext context , final ModelNode operation ) throws OperationFailedException { if ( context . hasFailureDescription ( ) ) { context . setRollbackOnly ( ) ; context . completeStep ( ) ; return ; } final Map < String , ProxyTask > tasks = new HashMap < String , ProxyTask > ( ) ; final Map < String , Future < ModelNode > > futures = new HashMap < String , Future < ModelNode > > ( ) ; for ( Map . Entry < String , NewProxyController > entry : hostProxies . entrySet ( ) ) { String host = entry . getKey ( ) ; <START_BUG> ProxyTask task = new ProxyTask ( host , operation , context , entry . getValue ( ) ) ; <END_BUG> tasks . put ( host , task ) ; futures . put ( host , executorService . submit ( task ) ) ; } boolean interrupted = false ; try { for ( Map . Entry < String , ProxyTask > entry : tasks . entrySet ( ) ) { ProxyTask task = entry . getValue ( ) ; ModelNode result = null ; try { result = entry . getValue ( ) . getUncommittedResult ( ) ; } catch ( InterruptedException e ) { result = new ModelNode ( ) ; result . get ( OUTCOME ) . set ( FAILED ) ; result . get ( FAILURE_DESCRIPTION ) . set ( String . format ( "Interrupted<seq2seq4repair_space>waiting<seq2seq4repair_space>for<seq2seq4repair_space>result<seq2seq4repair_space>from<seq2seq4repair_space>host<seq2seq4repair_space>%s" , entry . getKey ( ) ) ) ; interrupted = true ; task . cancel ( ) ; futures . get ( entry . getKey ( ) ) . cancel ( true ) ; } System . out . println ( ( ( ( "Result<seq2seq4repair_space>for<seq2seq4repair_space>" + ( entry . getKey ( ) ) ) + "<seq2seq4repair_space>is<seq2seq4repair_space>" ) + result ) ) ; domainOperationContext . addHostControllerResult ( entry . getKey ( ) , result ) ; } context . completeStep ( ) ; } finally { try { boolean rollback = domainOperationContext . isCompleteRollback ( ) ; for ( ProxyTask task : tasks . values ( ) ) { task . finalizeTransaction ( ( ! rollback ) ) ; } final short timeout = 10 ; for ( Map . Entry < String , Future < ModelNode > > entry : futures . entrySet ( ) ) { Future < ModelNode > future = entry . getValue ( ) ; try { ModelNode finalResult = ( future . isCancelled ( ) ) ? getCancelledResult ( ) : future . get ( ) ; domainOperationContext . addHostControllerResult ( entry . getKey ( ) , finalResult ) ; } catch ( InterruptedException e ) { interrupted = true ; DomainSlaveHandler . log . warnf ( "Interrupted<seq2seq4repair_space>awaiting<seq2seq4repair_space>final<seq2seq4repair_space>response<seq2seq4repair_space>from<seq2seq4repair_space>host<seq2seq4repair_space>%s" , entry . getKey ( ) ) ; } catch ( ExecutionException e ) { DomainSlaveHandler . log . warnf ( e . getCause ( ) , "Caught<seq2seq4repair_space>exception<seq2seq4repair_space>awaiting<seq2seq4repair_space>final<seq2seq4repair_space>response<seq2seq4repair_space>from<seq2seq4repair_space>host<seq2seq4repair_space>%s" , entry . getKey ( ) ) ; } } } finally { if ( interrupted ) { Thread . currentThread ( ) . interrupt ( ) ; } } } } private ModelNode getCancelledResult ( ) { } }

Fix:
ProxyTask task = new ProxyTask ( host , operation . clone ( ) , context , entry . getValue ( ) ) ;