activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jose María Zaragoza <demablo...@gmail.com>
Subject Re: maxReconnectAttempts in failover transport
Date Wed, 20 Nov 2013 11:49:13 GMT
I could find out that this error is caused by updateClusterClients="true"

 <transportConnector name="openwire"
uri="nio://0.0.0.0:61616?maximumConnections=1000&amp;wireformat.maxFrameSize=104857600"
updateClusterClients="true"/>


So, I need to se it to false

Thanks



2013/11/20 Jose María Zaragoza <demablogia@gmail.com>:
> Hello:
>
> I'm using AMQ 5.8.0
>
> I've defined the next transport failover
>
> "failover:(tcp://broker1:61616?connectionTimeout=3000,tcp://broker2:61616?connectionTimeout=3000)?timeout=5000&amp;startupMaxReconnectAttempts=1&amp;maxReconnectAttempts=1&amp;randomize=false&amp;priorityBackup=false"
>
>
> I start a Consumer, connects to broker1, and it listens correctly
>
> If I stop the AMQ server named broker1, an exception is thrown in
> ActiveMQMessageConsumer.dequeue, caused by doReconnect
> Why doesn't doReconnect() method retries to connect to broker2 ? What
> is maxReconnectAttempts value for ?
> Is it not monitorized the connection and is balanced transparently ?
>
> Thanks and regards
>
>
> javax.jms.JMSException: java.net.UnknownHostException
> at org.apache.activemq.util.JMSExceptionSupport.create(JMSExceptionSupport.java:62)
> at org.apache.activemq.ActiveMQMessageConsumer.dequeue(ActiveMQMessageConsumer.java:476)
> at org.apache.activemq.ActiveMQMessageConsumer.receive(ActiveMQMessageConsumer.java:594)
> at org.apache.activemq.pool.PooledMessageConsumer.receive(PooledMessageConsumer.java:67)
> at org.springframework.jms.listener.AbstractPollingMessageListenerContainer.receiveMessage(AbstractPollingMessageListenerContainer.java:429)
> at org.springframework.jms.listener.AbstractPollingMessageListenerContainer.doReceiveAndExecute(AbstractPollingMessageListenerContainer.java:310)
> at org.springframework.jms.listener.AbstractPollingMessageListenerContainer.receiveAndExecute(AbstractPollingMessageListenerContainer.java:263)
> at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener(DefaultMessageListenerContainer.java:1058)
> at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.executeOngoingLoop(DefaultMessageListenerContainer.java:1050)
> at org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run(DefaultMessageListenerContainer.java:947)
> at java.lang.Thread.run(Thread.java:662)
> Caused by: java.net.UnknownHostException
> at sun.nio.ch.Net.translateException(Net.java:82)
> at sun.nio.ch.SocketAdaptor.connect(SocketAdaptor.java:122)
> at org.apache.activemq.transport.tcp.TcpTransport.connect(TcpTransport.java:496)
> at org.apache.activemq.transport.nio.NIOTransport.doStart(NIOTransport.java:156)
> at org.apache.activemq.util.ServiceSupport.start(ServiceSupport.java:55)
> at org.apache.activemq.transport.AbstractInactivityMonitor.start(AbstractInactivityMonitor.java:140)
> at org.apache.activemq.transport.TransportFilter.start(TransportFilter.java:58)
> at org.apache.activemq.transport.WireFormatNegotiator.start(WireFormatNegotiator.java:72)
> at org.apache.activemq.transport.failover.FailoverTransport.doReconnect(FailoverTransport.java:993)
> at org.apache.activemq.transport.failover.FailoverTransport$2.iterate(FailoverTransport.java:143)
> at org.apache.activemq.thread.PooledTaskRunner.runTask(PooledTaskRunner.java:129)
> at org.apache.activemq.thread.PooledTaskRunner$1.run(PooledTaskRunner.java:47)
> at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)

Mime
View raw message