HBASE-19979 ReplicationSyncUp tool may leak Zookeeper connection
This commit is contained in:
parent
8e8e1e5a1b
commit
39e191e559
|
@ -111,14 +111,14 @@ public class ReplicationSyncUp extends Configured implements Tool {
|
||||||
while (manager.getOldSources().size() > 0) {
|
while (manager.getOldSources().size() > 0) {
|
||||||
Thread.sleep(SLEEP_TIME);
|
Thread.sleep(SLEEP_TIME);
|
||||||
}
|
}
|
||||||
|
manager.join();
|
||||||
} catch (InterruptedException e) {
|
} catch (InterruptedException e) {
|
||||||
System.err.println("didn't wait long enough:" + e);
|
System.err.println("didn't wait long enough:" + e);
|
||||||
return (-1);
|
return (-1);
|
||||||
|
} finally {
|
||||||
|
zkw.close();
|
||||||
}
|
}
|
||||||
|
|
||||||
manager.join();
|
|
||||||
zkw.close();
|
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue