camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ningji...@apache.org
Subject git commit: CAMEL-7967 write info log when RabbitMQConsumer cannot connect to the server
Date Mon, 27 Oct 2014 13:56:26 GMT
Repository: camel
Updated Branches:
  refs/heads/camel-2.14.x 83df741a1 -> 4cd5e42a0


CAMEL-7967 write info log when RabbitMQConsumer cannot connect to the server


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/4cd5e42a
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/4cd5e42a
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/4cd5e42a

Branch: refs/heads/camel-2.14.x
Commit: 4cd5e42a0c9bca9c691825255ad782afe22f91b8
Parents: 83df741
Author: Willem Jiang <willem.jiang@gmail.com>
Authored: Mon Oct 27 20:21:10 2014 +0800
Committer: Willem Jiang <willem.jiang@gmail.com>
Committed: Mon Oct 27 21:54:19 2014 +0800

----------------------------------------------------------------------
 .../org/apache/camel/component/rabbitmq/RabbitMQConsumer.java     | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/4cd5e42a/components/camel-rabbitmq/src/main/java/org/apache/camel/component/rabbitmq/RabbitMQConsumer.java
----------------------------------------------------------------------
diff --git a/components/camel-rabbitmq/src/main/java/org/apache/camel/component/rabbitmq/RabbitMQConsumer.java
b/components/camel-rabbitmq/src/main/java/org/apache/camel/component/rabbitmq/RabbitMQConsumer.java
index 7bb0bd8..a8dd785 100644
--- a/components/camel-rabbitmq/src/main/java/org/apache/camel/component/rabbitmq/RabbitMQConsumer.java
+++ b/components/camel-rabbitmq/src/main/java/org/apache/camel/component/rabbitmq/RabbitMQConsumer.java
@@ -116,6 +116,7 @@ public class RabbitMQConsumer extends DefaultConsumer {
             openConnection();
             startConsumers();
         } catch (Exception e) {
+            log.info("Connection failed, will start background thread to retry!", e);
             // Open connection, and start message listener in background
             Integer networkRecoveryInterval = getEndpoint().getNetworkRecoveryInterval();
             final long connectionRetryInterval = networkRecoveryInterval != null &&
networkRecoveryInterval > 0 ? networkRecoveryInterval : 100L;
@@ -293,7 +294,7 @@ public class RabbitMQConsumer extends DefaultConsumer {
                     openConnection();
                     connectionFailed = false;
                 } catch (Exception e) {
-                    log.debug("Connection failed, will retry in {}" + connectionRetryInterval
+ "ms", e);
+                    log.info("Connection failed, will retry in {}" + connectionRetryInterval
+ "ms", e);
                     Thread.sleep(connectionRetryInterval);
                 }
             }


Mime
View raw message