activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hengyunabc <hengyun...@gmail.com>
Subject The cacmel.xml can not work in ActiveMQ5.8, works fine in ActiveMQ5.5
Date Thu, 09 May 2013 10:02:06 GMT
In ActiveMQ5.5 it works very well, but in ActiveMQ5.8, log:
It seems that there are two threads, but SingleConnectionFactory??

2013-05-09 17:55:21,624 | WARN  | Setup of JMS message listener invoker
failed for destination 'spring_test_topic' - trying to recover. Cause: You
cannot create a durable subscriber without specifying a unique clientID on a
Connection |
org.apache.camel.component.jms.DefaultJmsMessageListenerContainer | Camel
(camel) thread #0 - JmsConsumer[spring_test_topic]
2013-05-09 17:55:21,624 | INFO  | Successfully refreshed JMS Connection |
org.apache.camel.component.jms.DefaultJmsMessageListenerContainer | Camel
(camel) thread #0 - JmsConsumer[spring_test_topic]
2013-05-09 17:55:26,629 | WARN  | Setup of JMS message listener invoker
failed for destination 'spring_test_topic' - trying to recover. Cause: You
cannot create a durable subscriber without specifying a unique clientID on a
Connection |
org.apache.camel.component.jms.DefaultJmsMessageListenerContainer | Camel
(camel) thread #2 - JmsConsumer[spring_test_topic]
2013-05-09 17:55:26,630 | INFO  | Successfully refreshed JMS Connection |
org.apache.camel.component.jms.DefaultJmsMessageListenerContainer | Camel
(camel) thread #2 - JmsConsumer[spring_test_topic]

camel.xml:

<beans
   xmlns="http://www.springframework.org/schema/beans"  
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
   xsi:schemaLocation="http://camel.apache.org/schema/spring
http://camel.apache.org/schema/spring/camel-spring.xsd
   http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd">
  
  	<camelContext id="camel" xmlns="http://camel.apache.org/schema/spring">
        <route>
            <description>Example Camel Route 1</description>
            <from
uri="jms:topic:spring_test_topic?clientId=1&amp;durableSubscriptionName=bar1"/>
            <to uri="jms:queue:spring_test_queue1"/>
        </route>
    </camelContext>
    
    <bean id="jmsConnectionFactory"
class="org.apache.activemq.ActiveMQConnectionFactory"> 
      <property name="brokerURL"
value="failover:(vm://localhost:61616?create=false&amp;waitForStart=10000)"
/>
      <property name="userName" value="${activemq.username}"/>
      <property name="password" value="${activemq.password}"/>
    </bean>
    
    
     <bean id="singleJmsConnectionFactory"
class="org.springframework.jms.connection.SingleConnectionFactory"> 
        <constructor-arg index="0" type="javax.jms.ConnectionFactory">  
            <ref bean="jmsConnectionFactory" /> 
        </constructor-arg>  
    </bean>   

    <bean id="jmsTransactionManager"
class="org.springframework.jms.connection.JmsTransactionManager">
        <property name="connectionFactory"
ref="singleJmsConnectionFactory"/>
    </bean>
                                                                                         
                                        
    <bean id="jms"
class="org.apache.activemq.camel.component.ActiveMQComponent" >
        <property name="transacted" value="true"/>
        <property name="transactionManager" ref="jmsTransactionManager"/>
    </bean>

</beans>



--
View this message in context: http://activemq.2283324.n4.nabble.com/The-cacmel-xml-can-not-work-in-ActiveMQ5-8-works-fine-in-ActiveMQ5-5-tp4666808.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Mime
View raw message