Add support for shutting down the ZK connection asynchronously.