This bundle provides default connection factories which let you connect with the ActiveMQ broker deployed in ServiceMix.This connection factories are used at least by the activemq
Camel component registered by the org.apache.servicemix.activemq.camel
bundle.
You can get the reference for the connection factory using following blueprint snippet
<reference id="pooledConnectionFactory" interface="javax.jms.ConnectionFactory" filter="(&(transacted=false)(name=default-cf))"/>
In case you need the transacted connection factory you should use following snippet
<reference id="pooledConnectionFactory" interface="javax.jms.ConnectionFactory" filter="(&(transacted=true)(name=default-cf-xa))"/>
The connection factories are associated the default broker installed by the activemq-broker
bundle - amq-broker
.
Assume, there are more brokers deployed in ServiceMix or you have changed the name of the default broker.
karaf@root> activemq:list brokerName = amq-broker brokerName = local-broker
If you want to change the broker associated with the connection factories (or you have changed the name of the default broker) you should change the broker-name
property using Config Admin
karaf@root>config:edit org.apache.servicemix.activemq.service karaf@root>property-set broker-name local-broker karaf@root>config:update