title: Spring Jms warn message every second
body: <p>Java - Spring - JMS</p>
  
  <p>I am using Spring with JMS listener and the following is my code snippet.</p>
  
  <pre><code>report.broker.url=failover:(tcp://w-dlapp00:5061?daemon=true;tcp://w-dlapp01:5061?daemon=true)?randomize=false&amp;timeout=3000
  </code></pre>
  
  <p>spring context, I found the problem is it's giving warning because queue w-dlapp00:5061 is down but due to it being in failover the other queue is working - how can I get rid of this warning?</p>
  
  <pre><code>&lt;!-- Active MQ changes --&gt;
    &lt;bean id="connectionFactory" class="org.apache.activemq.ActiveMQConnectionFactory"&gt;
      &lt;property name="brokerURL"&gt;
        &lt;value&gt;${royality.report.broker.url}&lt;/value&gt;
      &lt;/property&gt;
    &lt;/bean&gt;
  
    &lt;bean id="destinationRoyaltyReport" class="org.apache.activemq.command.ActiveMQQueue"&gt;
      &lt;constructor-arg value="${royality.report.queue}"/&gt;
    &lt;/bean&gt;
  
    &lt;bean id="jmsTemplate" class="org.springframework.jms.core.JmsTemplate"&gt;
      &lt;property name="connectionFactory" ref="connectionFactory"/&gt;
      &lt;property name="defaultDestination" ref="destinationRoyaltyReport"/&gt;
    &lt;/bean&gt;
  
    &lt;jms:listener-container connection-factory="connectionFactory"&gt;
      &lt;jms:listener destination="${royality.report.markingrid.queue}" ref="royaltyReportListener" method="onReceivedRoyaltyReportGridRequest"/&gt;
      &lt;jms:listener destination="${royality.report.queue}" ref="royaltyReportListener" method="onReceivedRoyaltyReportViewRequest"/&gt;
    &lt;/jms:listener-container&gt;
    &lt;!-- Active MQ changes --&gt;
  </code></pre>
  
  <p>When i look at the log file it is full with JMS info and WARN statements as following, could not figure out what is going on. There is warn message seems some thing is crashing ? </p>
  
  <pre><code>2013-02-20 14:34:28,691 [org.springframework.jms.listener.DefaultMessageListenerContainer#0-1] WARN  [DefaultMessageListenerContainer.java:834] : id[] Setup of JMS message listener invoker failed for destination 'royaltyReportMarkInGridQueue' - trying to recover. Cause: Failover timeout of 3000 ms reached.
  2013-02-20 14:34:31,763 [org.springframework.jms.listener.DefaultMessageListenerContainer#1-1] WARN  [DefaultMessageListenerContainer.java:834] : id[] Setup of JMS message listener invoker failed for destination 'royaltyReportQueue' - trying to recover. Cause: Failover timeout of 3000 ms reached.
  2013-02-20 14:34:31,767 [org.springframework.jms.listener.DefaultMessageListenerContainer#0-1] INFO  [FailoverTransport.java:507] : id[] Failover timed out after 3073ms
  2013-02-20 14:34:31,768 [org.springframework.jms.listener.DefaultMessageListenerContainer#0-1] WARN  [DefaultMessageListenerContainer.java:888] : id[] Could not refresh JMS Connection for destination 'royaltyReportMarkInGridQueue' - retrying in 5000 ms. Cause: Failover timeout of 3000 ms reached.
  2013-02-20 14:34:34,838 [org.springframework.jms.listener.DefaultMessageListenerContainer#1-1] INFO  [FailoverTransport.java:507] : id[] Failover timed out after 3073ms
  2013-02-20 14:34:34,838 [org.springframework.jms.listener.DefaultMessageListenerContainer#1-1] WARN  [DefaultMessageListenerContainer.java:888] : id[] Could not refresh JMS Connection for destination 'royaltyReportQueue' - retrying in 5000 ms. Cause: Failover timeout of 3000 ms reached.
  2013-02-20 14:34:39,839 [org.springframework.jms.listener.DefaultMessageListenerContainer#0-1] INFO  [FailoverTransport.java:507] : id[] Failover timed out after 3065ms
  2013-02-20 14:34:39,841 [org.springframework.jms.listener.DefaultMessageListenerContainer#0-1] WARN  [DefaultMessageListenerContainer.java:888] : id[] Could not refresh JMS Connection for destination 'royaltyReportMarkInGridQueue' - retrying in 5000 ms. Cause: Failover timeout of 3000 ms reached.
  2013-02-20 14:34:42,910 [org.springframework.jms.listener.DefaultMessageListenerContainer#1-1] INFO  [FailoverTransport.java:507] : id[] Failover timed out after 3068ms
  2013-02-20 14:34:42,910 [org.springframework.jms.listener.DefaultMessageListenerContainer#1-1] WARN  [DefaultMessageListenerContainer.java:888] : id[] Could not refresh JMS Connection for destination 'royaltyReportQueue' - retrying in 5000 ms. Cause: Failover timeout of 3000 ms reached.
  </code></pre>