You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by vj...@apache.org on 2020/08/12 11:47:22 UTC

[hbase] branch branch-2.2 updated: HBASE-24844 RecoverableZookeeper#close followed by ExecutorService shutdown

This is an automated email from the ASF dual-hosted git repository.

vjasani pushed a commit to branch branch-2.2
in repository https://gitbox.apache.org/repos/asf/hbase.git


The following commit(s) were added to refs/heads/branch-2.2 by this push:
     new a7cc7d8  HBASE-24844 RecoverableZookeeper#close followed by ExecutorService shutdown
a7cc7d8 is described below

commit a7cc7d823997544eefd009a686a6b87dbd896370
Author: WenFeiYi <we...@gmail.com>
AuthorDate: Wed Aug 12 16:25:49 2020 +0530

    HBASE-24844 RecoverableZookeeper#close followed by ExecutorService shutdown
    
    * Resolves Exception on standalone (master) shutdown
    
    Closes #2239
    
    Signed-off-by: Viraj Jasani <vj...@apache.org>
---
 .../src/main/java/org/apache/hadoop/hbase/zookeeper/ZKWatcher.java     | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/hbase-zookeeper/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKWatcher.java b/hbase-zookeeper/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKWatcher.java
index 8a8164a..3efbf03 100644
--- a/hbase-zookeeper/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKWatcher.java
+++ b/hbase-zookeeper/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKWatcher.java
@@ -670,11 +670,12 @@ public class ZKWatcher implements Watcher, Abortable, Closeable {
    */
   @Override
   public void close() {
-    zkEventProcessor.shutdownNow();
     try {
       recoverableZooKeeper.close();
     } catch (InterruptedException e) {
       Thread.currentThread().interrupt();
+    } finally {
+      zkEventProcessor.shutdownNow();
     }
   }