Consider Poco::Net::HostNotFoundException as ZCONNECTIONLOSS.

This commit is contained in:
Vitaly Baranov 2022-10-11 13:36:25 +02:00
parent 084f7115aa
commit 9cb2052c7f

View File

@ -97,7 +97,7 @@ void ZooKeeper::init(ZooKeeperArgs args_)
if (dns_error)
throw KeeperException("Cannot resolve any of provided ZooKeeper hosts due to DNS error", Coordination::Error::ZCONNECTIONLOSS);
else
throw KeeperException("Cannot use any of provided ZooKeeper nodes", Coordination::Error::ZBADARGUMENTS);
throw KeeperException("Cannot use any of provided ZooKeeper nodes", Coordination::Error::ZCONNECTIONLOSS);
}
impl = std::make_unique<Coordination::ZooKeeper>(nodes, args, zk_log);