camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject [1/4] camel git commit: ZooKeeperProducer does not stop ZooKeeper threads if Camel context ist stopped. Added overloaded doStop() method to shutdown ZooKeeperConnectionManager
Date Wed, 30 Dec 2015 16:05:08 GMT
Repository: camel
Updated Branches:
  refs/heads/camel-2.16.x 5c4f00876 -> cb6fc94c4
  refs/heads/master 5e2047aa1 -> bc5828966


ZooKeeperProducer does not stop ZooKeeper threads if Camel context ist stopped. Added overloaded
doStop() method to shutdown ZooKeeperConnectionManager


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

Branch: refs/heads/master
Commit: 249972fb796a7594d7c4574e7896bf9e550eda70
Parents: 5e2047a
Author: Klaus SchroŐąder <klaus.schroeder@next-audience.com>
Authored: Thu Dec 19 14:13:16 2013 +0100
Committer: Claus Ibsen <davsclaus@apache.org>
Committed: Wed Dec 30 16:56:21 2015 +0100

----------------------------------------------------------------------
 .../apache/camel/component/zookeeper/ZookeeperProducer.java | 9 +++++++++
 1 file changed, 9 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/249972fb/components/camel-zookeeper/src/main/java/org/apache/camel/component/zookeeper/ZookeeperProducer.java
----------------------------------------------------------------------
diff --git a/components/camel-zookeeper/src/main/java/org/apache/camel/component/zookeeper/ZookeeperProducer.java
b/components/camel-zookeeper/src/main/java/org/apache/camel/component/zookeeper/ZookeeperProducer.java
index d147b4f..aaf368b 100644
--- a/components/camel-zookeeper/src/main/java/org/apache/camel/component/zookeeper/ZookeeperProducer.java
+++ b/components/camel-zookeeper/src/main/java/org/apache/camel/component/zookeeper/ZookeeperProducer.java
@@ -119,6 +119,15 @@ public class ZookeeperProducer extends DefaultProducer {
         }
     }
 
+    @Override
+    protected void doStop() throws Exception {
+        super.doStop();
+        if (log.isTraceEnabled()) {
+            log.trace(String.format("Shutting down zookeeper producer of '%s'", configuration.getPath()));
+        }
+        zkm.shutdown();
+    }
+
     private void asynchronouslyDeleteNode(ZooKeeper connection, ProductionContext context)
{
         if (log.isDebugEnabled()) {
             log.debug(format("Deleting node '%s', not waiting for confirmation", context.node));


Mime
View raw message