We are running transacted camel routes with activemq on ec2 and it works fine. There was nothing special to set.

Just as a side remark, we experienced problems with hanging routes/consumers when activemq was restarted, which was solved by setting the prefetch to 0 (http://camel.465427.n5.nabble.com/Camel-ActiveMQ-consumers-do-not-consume-after-restart-td5716296.html).

On 06.11.2012 05:48, jiunjiunma wrote:
Hi,
     I am using camel with JMS transaction on. When I ran my test with a
local activemq, it works fine. However, when I switched it to an activemq on
ec2, no message is delivered and the test just hang. However, if I don't use
a transacted JMS component, the EC2 activemq also works fine. I am wondering
if anyone had tried to use camel to connect to a activemq on ec2 with
transacted connection and if there's anything special I need to set. Your
help is really appreciated.

Thanks,
--Jiunjiun

Snippet of my camel configuration below:

     <bean id="jmsConnectionFactory"
           class="org.apache.activemq.ActiveMQConnectionFactory">
         <property name="brokerURL" value="${activeMQBrokerURL}"/>
     </bean>

     <bean id="pooledConnectionFactory"
           class="org.apache.activemq.pool.PooledConnectionFactory"
init-method="start" destroy-method="stop">
         <property name="maxConnections" value="8" />
         <property name="connectionFactory" ref="jmsConnectionFactory" />
     </bean>

     <bean id="transactionManager"
class="org.springframework.jms.connection.JmsTransactionManager">
         <property name="connectionFactory" ref="pooledConnectionFactory"/>
     </bean>

     <bean id="activemq"
class="org.apache.activemq.camel.component.ActiveMQComponent">
         <property name="transacted" value="true"/>
         <property name="transactionManager" ref="transactionManager"/>
         <property name="concurrentConsumers" value="5"/>
     </bean>



--
View this message in context: 
http://camel.465427.n5.nabble.com/any-tried-using-transacted-activemq-on-ec2-tp5722186.html
Sent from the Camel - Users mailing list archive at Nabble.com.


Reply via email to