Description
When using the Netty connection implementation in ZooKeeper the JVM hangs on exit if the ZK Connection is not shut down explicitly.
While this should be fixed in some future ZK version, we can fix it short term by doing the right thing, and not leaving Connections open when exiting.
While this is fine as a general cleanup, it doesn't solve the ZK hang issue, as the HBase Connections are kept open in the cached CQSI objects.
Update 2:
The actual problem is that we throw an exception from the Tool's main thread, which causes an ungraceful shutdown.
If we catch the error, and return a non-zero exit code, then the JVM will shut down normall, and the shutdown hook will close the CQSI objects.
Attachments
Issue Links
- is caused by
-
ZOOKEEPER-4804 Use daemon threads for Netty client
- Closed
- links to