use of com.jim.framework.activemq.producer.ConsumerConnctionFactory in project jim-framework by jiangmin168168.
the class ConnectionFactoryContainer method getConsumerConnectionFactory.
public static PooledConnectionFactory getConsumerConnectionFactory(String brokerUrl) {
PooledConnectionFactory connectionFactory = null;
synchronized (lock) {
if (consumerConnectionFactoryMap.containsKey(brokerUrl)) {
connectionFactory = (PooledConnectionFactory) consumerConnectionFactoryMap.get(brokerUrl);
} else {
ConsumerConnctionFactory consumerConnctionFactory = new ConsumerConnctionFactory();
// producerConnctionFactory.init();
connectionFactory = consumerConnctionFactory.create(brokerUrl);
consumerConnectionFactoryMap.put(brokerUrl, connectionFactory);
}
return connectionFactory;
}
}
Aggregations