diff options
author | epbugaev <[email protected]> | 2023-02-03 14:50:02 +0300 |
---|---|---|
committer | epbugaev <[email protected]> | 2023-02-03 14:50:02 +0300 |
commit | e83e0247eb4e3c03003a6c21625932c25d8497b2 (patch) | |
tree | 547e4203df0624e0f0a8c7fda2c7e79a3fd838b8 | |
parent | 26b6e08dbc1f4fb74fe369e9fbca6e877893c926 (diff) |
YQL logger refactoring fix stream names
[] Fix log stream names
-rw-r--r-- | ydb/library/yql/utils/log/log.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/ydb/library/yql/utils/log/log.cpp b/ydb/library/yql/utils/log/log.cpp index 978915e543b..b4eb6833525 100644 --- a/ydb/library/yql/utils/log/log.cpp +++ b/ydb/library/yql/utils/log/log.cpp @@ -124,8 +124,8 @@ NYql::NLog::EComponent ConvertComponent(NYql::NProto::TLoggingConfig::EComponent TString ConvertDestinationType(NYql::NProto::TLoggingConfig::ELogTo c) { switch (c) { - case NYql::NProto::TLoggingConfig::STDOUT: return "stdout"; - case NYql::NProto::TLoggingConfig::STDERR: return "stderr"; + case NYql::NProto::TLoggingConfig::STDOUT: return "cout"; + case NYql::NProto::TLoggingConfig::STDERR: return "cerr"; case NYql::NProto::TLoggingConfig::CONSOLE: return "console"; default : { ythrow yexception() << "unsupported ELogTo destination in Convert"; @@ -137,9 +137,9 @@ TString ConvertDestinationType(NYql::NProto::TLoggingConfig::ELogTo c) { NYql::NProto::TLoggingConfig::TLogDestination CreateLogDestination(const TString& c) { NYql::NProto::TLoggingConfig::TLogDestination destination; - if (c == "stdout") { + if (c == "cout") { destination.SetType(NYql::NProto::TLoggingConfig::STDOUT); - } else if (c == "stderr") { + } else if (c == "cerr") { destination.SetType(NYql::NProto::TLoggingConfig::STDERR); } else if (c == "console") { destination.SetType(NYql::NProto::TLoggingConfig::CONSOLE); @@ -277,7 +277,7 @@ void InitLogger(const NProto::TLoggingConfig& config, bool startAsDaemon) { // Set stderr log destination if none was described in config if (config.LogDestSize() == 0) { - backends.emplace_back(CreateLogBackend("stderr", LOG_MAX_PRIORITY, false)); + backends.emplace_back(CreateLogBackend("cerr", LOG_MAX_PRIORITY, false)); } for (const auto& logDestionation : config.GetLogDest()) { |