camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject git commit: Added more logging when listener container stops and whether shared connections is stopped as well.
Date Wed, 06 Nov 2013 10:18:16 GMT
Updated Branches:
  refs/heads/camel-2.12.x e8080add6 -> 17f225478


Added more logging when listener container stops and whether shared connections is stopped
as well.


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

Branch: refs/heads/camel-2.12.x
Commit: 17f225478bbfc2ff832339fe500793b51dab0177
Parents: e8080ad
Author: Claus Ibsen <davsclaus@apache.org>
Authored: Tue Nov 5 17:37:13 2013 +0100
Committer: Claus Ibsen <davsclaus@apache.org>
Committed: Wed Nov 6 11:19:15 2013 +0100

----------------------------------------------------------------------
 .../jms/DefaultJmsMessageListenerContainer.java | 30 +++++++++++++++++++-
 1 file changed, 29 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/17f22547/components/camel-jms/src/main/java/org/apache/camel/component/jms/DefaultJmsMessageListenerContainer.java
----------------------------------------------------------------------
diff --git a/components/camel-jms/src/main/java/org/apache/camel/component/jms/DefaultJmsMessageListenerContainer.java
b/components/camel-jms/src/main/java/org/apache/camel/component/jms/DefaultJmsMessageListenerContainer.java
index ca89f0c..793bb75 100644
--- a/components/camel-jms/src/main/java/org/apache/camel/component/jms/DefaultJmsMessageListenerContainer.java
+++ b/components/camel-jms/src/main/java/org/apache/camel/component/jms/DefaultJmsMessageListenerContainer.java
@@ -19,6 +19,7 @@ package org.apache.camel.component.jms;
 import org.apache.camel.util.concurrent.CamelThreadFactory;
 import org.springframework.core.task.SimpleAsyncTaskExecutor;
 import org.springframework.core.task.TaskExecutor;
+import org.springframework.jms.JmsException;
 import org.springframework.jms.listener.DefaultMessageListenerContainer;
 import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor;
 
@@ -80,5 +81,32 @@ public class DefaultJmsMessageListenerContainer extends DefaultMessageListenerCo
             return answer;
         }
     }
-    
+
+    @Override
+    public void stop() throws JmsException {
+        if (logger.isDebugEnabled()) {
+            logger.debug("Stopping listenerContainer: " + this + " with cacheLevel: " + getCacheLevel()
+                    + " and sharedConnectionEnabled: " + sharedConnectionEnabled());
+        }
+        super.stop();
+    }
+
+    @Override
+    public void destroy() {
+        if (logger.isDebugEnabled()) {
+            logger.debug("Destroying listenerContainer: " + this + " with cacheLevel: " +
getCacheLevel()
+                    + " and sharedConnectionEnabled: " + sharedConnectionEnabled());
+        }
+        super.destroy();
+    }
+
+    @Override
+    protected void stopSharedConnection() {
+        if (logger.isDebugEnabled()) {
+            if (sharedConnectionEnabled()) {
+                logger.debug("Stopping shared connection on listenerContainer: " + this);
+            }
+        }
+        super.stopSharedConnection();
+    }
 }


Mime
View raw message