mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-23 08:02:02 +00:00
Merge pull request #34715 from azat/fix-opened-file-cache-race
Workaround for a bug in NuRaft library
This commit is contained in:
commit
576ff0b40d
@ -115,6 +115,15 @@ void KeeperStateManager::loadLogStore(uint64_t last_commited_index, uint64_t log
|
||||
log_store->init(last_commited_index, logs_to_keep);
|
||||
}
|
||||
|
||||
void KeeperStateManager::system_exit(const int /* exit_code */)
|
||||
{
|
||||
/// NuRaft itself calls exit() which will call atexit handlers
|
||||
/// and this may lead to an issues in multi-threaded program.
|
||||
///
|
||||
/// Override this with abort().
|
||||
abort();
|
||||
}
|
||||
|
||||
ClusterConfigPtr KeeperStateManager::getLatestConfigFromLogStore() const
|
||||
{
|
||||
auto entry_with_change = log_store->getLatestConfigChange();
|
||||
|
@ -73,7 +73,7 @@ public:
|
||||
|
||||
nuraft::ptr<nuraft::srv_config> get_srv_config() const { return configuration_wrapper.config; }
|
||||
|
||||
void system_exit(const int /* exit_code */) override {}
|
||||
void system_exit(const int exit_code) override;
|
||||
|
||||
int getPort() const
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user