Merge pull request #21366 from songenjie/shutdown_timeout_log

[ClickHouse][LOG]correct shutdown timeout log
This commit is contained in:
alexey-milovidov 2021-03-03 01:55:15 +03:00 committed by GitHub
commit 6e5638cee8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -80,8 +80,9 @@ void NuKeeperServer::shutdown()
{ {
state_machine->shutdownStorage(); state_machine->shutdownStorage();
state_manager->flushLogStore(); state_manager->flushLogStore();
if (!launcher.shutdown(coordination_settings->shutdown_timeout.totalSeconds())) auto timeout = coordination_settings->shutdown_timeout.totalSeconds();
LOG_WARNING(&Poco::Logger::get("NuKeeperServer"), "Failed to shutdown RAFT server in {} seconds", 5); if (!launcher.shutdown(timeout))
LOG_WARNING(&Poco::Logger::get("NuKeeperServer"), "Failed to shutdown RAFT server in {} seconds", timeout);
} }
namespace namespace