mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-22 23:52:03 +00:00
Use sync after reconnect to avoid stale reads
This commit is contained in:
parent
6c225bb04d
commit
df31b562ec
@ -233,9 +233,8 @@ void TransactionLog::runUpdatingThread()
|
||||
}
|
||||
|
||||
/// It's possible that we connected to different [Zoo]Keeper instance
|
||||
/// so we may read a bit stale state. Run some writing request before loading log entries
|
||||
/// to make that instance up-to-date.
|
||||
zookeeper->set(zookeeper_path_log, "");
|
||||
/// so we may read a bit stale state.
|
||||
zookeeper->sync(zookeeper_path_log);
|
||||
}
|
||||
|
||||
loadNewEntries();
|
||||
|
Loading…
Reference in New Issue
Block a user