In a container like jboss it should not be necessary to use the CachingConnectionFactory. Instead you should configure the resource adapter to support pooling.

Then you can simply lookup the ConnectionFactory on jndi and use it as it is.

The CachingConnectionFactory is typically used when you are not running in a container.

Christian

Am 26.04.2012 10:47, schrieb weberj:
Yes, the pool is defined in Spring XML. Camel should run in JBoss 4, MQ is in
the resource adapter (therefore the "application client container"
complaint).
Guess I'll have to remote debug the code..

The connection and route definitions cannot be totally wrong, as one or two
messages are delivered until the error comes up.

Juergen


        <bean id="jmswsmq" class="org.apache.camel.component.jms.JmsComponent">
                <property name="connectionFactory" 
ref="mqConnectionFactoryWrapper" />
                <property name="acknowledgementModeName" value="AUTO_ACKNOWLEDGE" 
/>
        </bean>

        <bean id="mqConnectionFactoryWrapper"
class="org.springframework.jms.connection.CachingConnectionFactory">
                <property name="targetConnectionFactory" 
ref="mqJmsConnectionFactoryJNDI"
/>
        </bean>

        <jee:jndi-lookup id="mqJmsConnectionFactoryJNDI" jndi-name="java:wmqcf" 
/>

--
View this message in context: 
http://camel.465427.n5.nabble.com/New-JMS-connection-being-created-for-every-message-tp5637735p5667039.html
Sent from the Camel - Users mailing list archive at Nabble.com.


--
Christian Schneider
http://www.liquid-reality.de

Open Source Architect
Talend Application Integration Division http://www.talend.com

Reply via email to