curator-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From randg...@apache.org
Subject curator git commit: Ignore any shutdown errors
Date Tue, 08 Sep 2015 17:37:28 GMT
Repository: curator
Updated Branches:
  refs/heads/CURATOR-3.0 b161867c1 -> a69f3a435


Ignore any shutdown errors


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

Branch: refs/heads/CURATOR-3.0
Commit: a69f3a435755b1dfdd1e706cb028d3169a7c9632
Parents: b161867
Author: randgalt <randgalt@apache.org>
Authored: Tue Sep 8 12:37:20 2015 -0500
Committer: randgalt <randgalt@apache.org>
Committed: Tue Sep 8 12:37:20 2015 -0500

----------------------------------------------------------------------
 .../org/apache/curator/test/TestingZooKeeperMain.java   | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/curator/blob/a69f3a43/curator-test/src/main/java/org/apache/curator/test/TestingZooKeeperMain.java
----------------------------------------------------------------------
diff --git a/curator-test/src/main/java/org/apache/curator/test/TestingZooKeeperMain.java
b/curator-test/src/main/java/org/apache/curator/test/TestingZooKeeperMain.java
index bb70da5..637166a 100644
--- a/curator-test/src/main/java/org/apache/curator/test/TestingZooKeeperMain.java
+++ b/curator-test/src/main/java/org/apache/curator/test/TestingZooKeeperMain.java
@@ -119,7 +119,15 @@ public class TestingZooKeeperMain extends ZooKeeperServerMain implements
ZooKeep
     @Override
     public void close() throws IOException
     {
-        shutdown();
+        try
+        {
+            shutdown();
+        }
+        catch ( Throwable e )
+        {
+            // ignore any errors
+            e.printStackTrace();
+        }
 
         try
         {
@@ -138,7 +146,7 @@ public class TestingZooKeeperMain extends ZooKeeperServerMain implements
ZooKeep
                 }
             }
         }
-        catch ( Exception e )
+        catch ( Throwable e )
         {
             e.printStackTrace();    // just ignore - this class is only for testing
         }


Mime
View raw message