For camel JmsConfiguration Spring cachingconnectionfactory can be used with JndiObjectFactoryBean inside websphere Appserver

My application is running under Websphere Application Server and uses apache camel to route messages. My QueueConnectionFactories and Queues are created as JMS resources in the Appserver using jndi pointing to the Queens Manager WebsphereMQ. Can I use SpringCachingConnectionFactory to improve performance inside JEE container like WAS with JNDI. Following the spring config:

<bean id="jmsDestinationResolver" class="org.springframework.jms.support.destination.JndiDestinationResolver">
</bean>
<bean id="myJndiObjectFacory" class="org.springframework.jndi.JndiObjectFactoryBean">
   <property name="jndiName" value="jms/MyQCF"/>
</bean>
<bean id="myJmsConfig" class="org.apache.camel.component.jms.JmsConfiguration">
    <property name="connectionFactory" ref="myJndiObjectFacory"/>
    <property name="transactionManager" ref="txManager"/>
    <property name="destinationResolver" ref="jmsDestinationResolver"/>

      

Will the above code have the same performance as the spring CachingConnectionFactory? or Is it possible to use the CachingConnectionFactory with Jndi lookup in JES container in websphere?

+3


source to share





All Articles