Buggy code:
public class JMSConnectionFactoryDefinitionInjectionSource extends ResourceDefinitionInjectionSource { private String interfaceName ; private String className ; private String resourceAdapter ; private String user ; private String password ; private String clientId ; private boolean transactional ; private int maxPoolSize ; private int minPoolSize ; public JMSConnectionFactoryDefinitionInjectionSource ( String jndiName ) { } void setInterfaceName ( String interfaceName ) { } void setClassName ( String className ) { } void setResourceAdapter ( String resourceAdapter ) { } void setUser ( String user ) { } void setPassword ( String password ) { } void setClientId ( String clientId ) { } void setTransactional ( boolean transactional ) { } void setMaxPoolSize ( int maxPoolSize ) { } void setMinPoolSize ( int minPoolSize ) { } @ Override public void getResourceValue ( ResolutionContext context , ServiceBuilder < ? > serviceBuilder , DeploymentPhaseContext phaseContext , Injector < ManagedReferenceFactory > injector ) throws DeploymentUnitProcessingException { } private void startedPooledConnectionFactory ( ResolutionContext context , String name , ServiceBuilder < ? > serviceBuilder , ServiceTarget serviceTarget , DeploymentUnit deploymentUnit , Injector < ManagedReferenceFactory > injector ) throws OperationFailedException , DeploymentUnitProcessingException { Map < String , String > props = new java . util . HashMap ( properties ) ; List < String > connectors = getConnectors ( props ) ; clearUnknownProperties ( properties ) ; ModelNode model = new ModelNode ( ) ; for ( String connector : connectors ) { model . get ( CommonAttributes . CONNECTOR ) . add ( connector ) ; } for ( Map . Entry < String , String > entry : properties . entrySet ( ) ) { model . get ( entry . getKey ( ) ) . set ( entry . getValue ( ) ) ; } model . get ( MIN_POOL_SIZE . getName ( ) ) . set ( minPoolSize ) ; model . get ( MAX_POOL_SIZE . getName ( ) ) . set ( maxPoolSize ) ; if ( ( ( user ) != null ) && ( ! ( user . isEmpty ( ) ) ) ) { model . get ( USER . getName ( ) ) . set ( user ) ; } if ( ( ( password ) != null ) && ( ! ( password . isEmpty ( ) ) ) ) { model . get ( PASSWORD . getName ( ) ) . set ( password ) ; } if ( ( ( clientId ) != null ) && ( ! ( clientId . isEmpty ( ) ) ) ) { model . get ( CLIENT_ID . getName ( ) ) . set ( clientId ) ; } final String discoveryGroupName = ( properties . containsKey ( DISCOVERY_GROUP_NAME . getName ( ) ) ) ? properties . get ( DISCOVERY_GROUP_NAME . getName ( ) ) : null ; if ( discoveryGroupName != null ) { model . get ( DISCOVERY_GROUP_NAME . getName ( ) ) . set ( discoveryGroupName ) ; } final String jgroupsChannelName = ( properties . containsKey ( CommonAttributes . JGROUPS_CHANNEL . getName ( ) ) ) ? properties . get ( CommonAttributes . JGROUPS_CHANNEL . getName ( ) ) : null ; if ( jgroupsChannelName != null ) { model . get ( CommonAttributes . JGROUPS_CHANNEL . getName ( ) ) . set ( jgroupsChannelName ) ; } List < PooledConnectionFactoryConfigProperties > adapterParams = getAdapterParams ( model ) ; String txSupport = ( transactional ) ? CommonAttributes . XA_TX : CommonAttributes . NO_TX ; final String pcfName = JMSConnectionFactoryDefinitionInjectionSource . uniqueName ( context , name ) ; final ContextNames . BindInfo bindInfo = ContextNames . bindInfoForEnvEntry ( context . getApplicationName ( ) , context . getModuleName ( ) , context . getComponentName ( ) , ( ! ( context . isCompUsesModule ( ) ) ) , name ) ; <START_BUG> PooledConnectionFactoryService . installService ( serviceTarget , pcfName , getHornetQServerName ( ) , connectors , discoveryGroupName , jgroupsChannelName , adapterParams , bindInfo , txSupport , minPoolSize , maxPoolSize , true ) ; <END_BUG> final ServiceName referenceFactoryServiceName = SERVICE_NAME_BASE . append ( bindInfo . getBinderServiceName ( ) ) ; serviceBuilder . addDependency ( referenceFactoryServiceName , ManagedReferenceFactory . class , injector ) ; String managementName = JMSConnectionFactoryDefinitionInjectionSource . managementName ( context , name ) ; final PathElement serverElement = PathElement . pathElement ( CommonAttributes . HORNETQ_SERVER , getHornetQServerName ( ) ) ; deploymentUnit . createDeploymentSubModel ( SUBSYSTEM_NAME , serverElement ) ; final PathElement pcfPath = PathElement . pathElement ( CommonAttributes . POOLED_CONNECTION_FACTORY , managementName ) ; PathAddress registration = PathAddress . pathAddress ( serverElement , pcfPath ) ; MessagingXmlInstallDeploymentUnitProcessor . createDeploymentSubModel ( registration , deploymentUnit ) ; INSTANCE . registerResource ( getHornetQServerName ( ) , managementName , model ) ; } private List < String > getConnectors ( Map < String , String > props ) { } void clearUnknownProperties ( final Map < String , String > props ) { } private static String uniqueName ( InjectionSource . ResolutionContext context , final String jndiName ) { } private static String managementName ( InjectionSource . ResolutionContext context , final String jndiName ) { } private List < PooledConnectionFactoryConfigProperties > getAdapterParams ( ModelNode model ) { } private String getHornetQServerName ( ) { } @ Override public boolean equals ( Object o ) { } @ Override public int hashCode ( ) { } }

Fix:
PooledConnectionFactoryService . installService ( null , null , serviceTarget , pcfName , getHornetQServerName ( ) , connectors , discoveryGroupName , jgroupsChannelName , adapterParams , bindInfo , txSupport , minPoolSize , maxPoolSize , true ) ;