mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-10 01:25:21 +00:00
Avoid busy loop in DDLWorker when ZooKeeper is not available [#CLICKHOUSE-4126]
This commit is contained in:
parent
b21aa60e99
commit
8f50c62033
@ -882,8 +882,12 @@ void DDLWorker::run()
|
||||
catch (const Coordination::Exception & e)
|
||||
{
|
||||
if (!Coordination::isHardwareError(e.code))
|
||||
throw;
|
||||
throw; /// A logical error.
|
||||
|
||||
tryLogCurrentException(__PRETTY_FUNCTION__);
|
||||
|
||||
/// Avoid busy loop when ZooKeeper is not available.
|
||||
::sleep(1);
|
||||
}
|
||||
}
|
||||
catch (...)
|
||||
|
Loading…
Reference in New Issue
Block a user