messaging-activemq/src/main/java/org/wildfly/extension/messaging/activemq/deployment/JMSConnectionFactoryDefinitionInjectionSource.java
static boolean targetsExternalPooledConnectionFactory(String resourceAdapter, ServiceRegistry serviceRegistry) {
        // if the resourceAdapter is not defined, the default behaviour is to create a pooled-connection-factory.
        if (resourceAdapter == null || resourceAdapter.isEmpty()) {
            return false;
        }
        //let's look into the external-pooled-connection-factory
        ServiceName pcfName = JMSServices.getPooledConnectionFactoryBaseServiceName(MessagingServices.getActiveMQServiceName("")).append(resourceAdapter);
        return serviceRegistry.getServiceNames().contains(pcfName);
    }
static boolean targetsExternalPooledConnectionFactory(String resourceAdapter, ServiceRegistry serviceRegistry) {
        // if the resourceAdapter is not defined, the default behaviour is to create a pooled-connection-factory.
        if (resourceAdapter == null || resourceAdapter.isEmpty()) {
            return false;
        }
        //let's look into the external-pooled-connection-factory
        ServiceName pcfName = JMSServices.getPooledConnectionFactoryBaseServiceName(MessagingServices.getActiveMQServiceName("")).append(resourceAdapter);
        return serviceRegistry.getServiceNames().contains(pcfName);
    }
Return whether the definition targets an existing external pooled connection factory.

Checks the service registry for a PooledConnectionFactoryService with the ServiceName
created by the {@code server} property (or {@code "default") and the {@code resourceAdapter} property.