mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-09-23 10:10:50 +00:00
Fixed discrepancy between default values of "log_queries" and "log_query_threads" settings [#CLICKHOUSE-4030]
This commit is contained in:
parent
03d85227d1
commit
169dbfe200
@ -105,10 +105,13 @@ void ThreadStatus::finalizePerformanceCounters()
|
||||
|
||||
try
|
||||
{
|
||||
bool log_to_query_thread_log = global_context && query_context && query_context->getSettingsRef().log_query_threads.value != 0;
|
||||
if (log_to_query_thread_log)
|
||||
if (auto thread_log = global_context->getQueryThreadLog())
|
||||
logToQueryThreadLog(*thread_log);
|
||||
if (global_context && query_context)
|
||||
{
|
||||
auto & settings = query_context->getSettingsRef();
|
||||
if (settings.log_queries && settings.log_query_threads)
|
||||
if (auto thread_log = global_context->getQueryThreadLog())
|
||||
logToQueryThreadLog(*thread_log);
|
||||
}
|
||||
}
|
||||
catch (...)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user