diff --git a/Framework/src/AggregatorRunner.cxx b/Framework/src/AggregatorRunner.cxx index 4ce15a2aa0..8d20853aa5 100644 --- a/Framework/src/AggregatorRunner.cxx +++ b/Framework/src/AggregatorRunner.cxx @@ -214,7 +214,7 @@ void AggregatorRunner::store(QualityObjectsWithAggregatorNameVector& qualityObje if (!qualityObjectsWithAggregatorNames.empty() && !qualityObjectsWithAggregatorNames.front().second.empty()) { const auto& qo = qualityObjectsWithAggregatorNames.front().second.front(); - ILOG(Info, Devel) << "Validity of QO '" << qo->GetName() << "' is (" << qo->getValidity().getMin() << ", " << qo->getValidity().getMax() << ")" << ENDM; + ILOG(Debug, Devel) << "Validity of QO '" << qo->GetName() << "' is (" << qo->getValidity().getMin() << ", " << qo->getValidity().getMax() << ")" << ENDM; } } catch (boost::exception& e) { diff --git a/Framework/src/Bookkeeping.cxx b/Framework/src/Bookkeeping.cxx index a130690097..aae2f505e1 100644 --- a/Framework/src/Bookkeeping.cxx +++ b/Framework/src/Bookkeeping.cxx @@ -52,7 +52,7 @@ std::string readClientToken() if (token.empty()) { throw std::runtime_error("BKP token file '" + tokenFileName + "' was provided but it is empty, please provide a valid token"); } - ILOG(Debug, Devel) << "Using token from file qc_bkp_client_token" << ENDM; + ILOG(Debug, Devel) << "Using token from file qc_bkp_client_token.txt" << ENDM; return token; } diff --git a/Framework/src/CheckRunner.cxx b/Framework/src/CheckRunner.cxx index 416fdbe889..b9083ae095 100644 --- a/Framework/src/CheckRunner.cxx +++ b/Framework/src/CheckRunner.cxx @@ -337,7 +337,7 @@ void CheckRunner::store(QualityObjectsType& qualityObjects, long validFrom) } if (!qualityObjects.empty()) { auto& qo = qualityObjects.at(0); - ILOG(Info, Devel) << "Validity of QO '" << qo->GetName() << "' is (" << qo->getValidity().getMin() << ", " << qo->getValidity().getMax() << ")" << ENDM; + ILOG(Debug, Devel) << "Validity of QO '" << qo->GetName() << "' is (" << qo->getValidity().getMin() << ", " << qo->getValidity().getMax() << ")" << ENDM; } } catch (boost::exception& e) { ILOG(Info, Support) << "Unable to " << diagnostic_information(e) << ENDM; @@ -356,7 +356,7 @@ void CheckRunner::store(std::vector>& monitorObje } if (!monitorObjects.empty()) { auto& mo = monitorObjects.at(0); - ILOG(Info, Devel) << "Validity of MO '" << mo->GetName() << "' is (" << mo->getValidity().getMin() << ", " << mo->getValidity().getMax() << ")" << ENDM; + ILOG(Debug, Devel) << "Validity of MO '" << mo->GetName() << "' is (" << mo->getValidity().getMin() << ", " << mo->getValidity().getMax() << ")" << ENDM; } } catch (boost::exception& e) { ILOG(Info, Support) << "Unable to " << diagnostic_information(e) << ENDM; diff --git a/Framework/src/TimekeeperAsynchronous.cxx b/Framework/src/TimekeeperAsynchronous.cxx index 360428fc43..94f2d6af0b 100644 --- a/Framework/src/TimekeeperAsynchronous.cxx +++ b/Framework/src/TimekeeperAsynchronous.cxx @@ -111,8 +111,8 @@ validity_time_t } else { // an exception could be thrown here once the values above are set correctly in production } - ILOG(Info, Devel) << "Received the following activity boundary propositions: " << ccdbTimestamp << ", " << ecsTimestamp - << ", " << configTimestamp << ", " << currentTimestamp << ". Selected: " << selected << ENDM; + ILOG(Debug, Devel) << "Received the following activity boundary propositions: " << ccdbTimestamp << ", " << ecsTimestamp + << ", " << configTimestamp << ", " << currentTimestamp << ". Selected: " << selected << ENDM; return selected; } @@ -131,7 +131,7 @@ ValidityInterval TimekeeperAsynchronous::computeTimestampFromTimeframeID(uint32_ if (mOrbitsPerTF == 0) { if (auto accessor = getCCDBOrbitsPerTFAccessor()) { mOrbitsPerTF = accessor(); - ILOG(Info, Support) << "Got nOrbitsPerTF " << mOrbitsPerTF << " for TF " << tfid << ENDM; + ILOG(Debug, Support) << "Got nOrbitsPerTF " << mOrbitsPerTF << " for TF " << tfid << ENDM; } else { ILOG(Error, Ops) << "CCDB OrbitsPerTF accessor is not available" << ENDM; } diff --git a/Framework/src/TimekeeperSynchronous.cxx b/Framework/src/TimekeeperSynchronous.cxx index d1a0c281e7..daa67f61bc 100644 --- a/Framework/src/TimekeeperSynchronous.cxx +++ b/Framework/src/TimekeeperSynchronous.cxx @@ -37,7 +37,7 @@ void TimekeeperSynchronous::updateByTimeFrameID(uint32_t tfid) { if (tfid == 0) { if (!mWarnedAboutTfIdZero) { - ILOG(Warning, Devel) << "Seen TFID equal to 0, which is not expected. Will not update TF-based validity, will not warn further." << ENDM; + ILOG(Debug, Devel) << "Seen TFID equal to 0, which is unexpected in production, but normal in test QC setups. Will not update TF-based validity, will not warn further." << ENDM; mWarnedAboutTfIdZero = true; } return; diff --git a/Framework/src/runQC.cxx b/Framework/src/runQC.cxx index 0fae551924..3461d4c80f 100644 --- a/Framework/src/runQC.cxx +++ b/Framework/src/runQC.cxx @@ -32,6 +32,7 @@ #include #include #include +#include #include "QualityControl/runnerUtils.h" #include "QualityControl/InfrastructureGenerator.h" #include "QualityControl/QcInfoLogger.h" @@ -108,7 +109,7 @@ bool validateArguments(const ConfigContext& config) ILOG(Warning, Support) << "No configuration path specified, returning an empty workflow." << ENDM; return false; } else if (!std::regex_match(qcConfigurationSource, configBackend)) { - ILOG(Error, Support) << "The --config option expects a backend name (e.g. json:// or consul-json://) preceding the path. User specified: " << qcConfigurationSource << ENDM; + ILOG(Error, Ops) << "The --config option expects a backend name (e.g. json:// or consul-json://) preceding the path. User specified: " << qcConfigurationSource << ENDM; return false; } @@ -119,13 +120,40 @@ bool validateArguments(const ConfigContext& config) exclusiveOptions += !config.options().get("local-batch").empty(); exclusiveOptions += !config.options().get("remote-batch").empty(); if (exclusiveOptions > 1) { - ILOG(Error, Support) << "More than one of the following options was specified: --local, --remote, --local-batch, --remote--batch. This is not allowed, returning an empty workflow." << ENDM; + ILOG(Error, Ops) << "More than one of the following options was specified: --local, --remote, --local-batch, --remote-batch, --full-chain. This is not allowed, returning an empty workflow." << ENDM; return false; } return true; } +void setupInfologger(const ConfigContext& config, boost::property_tree::ptree configTree) +{ + if (config.options().get("no-infologger")) { + quality_control::core::QcInfoLogger::disable(); + } else { + auto infologgerFilterDiscardDebug = configTree.get("qc.config.infologger.filterDiscardDebug", true); + auto infologgerDiscardLevel = configTree.get("qc.config.infologger.filterDiscardLevel", 21); + ILOG_INST.filterDiscardDebug(infologgerFilterDiscardDebug); + ILOG_INST.filterDiscardLevel(infologgerDiscardLevel); + } + auto infologgerDiscardFile = configTree.get("qc.config.infologger.filterDiscardFile", ""); + auto rotateMaxBytes = configTree.get("qc.config.infologger.filterRotateMaxBytes", 0); + auto rotateMaxFiles = configTree.get("qc.config.infologger.filterRotateMaxFiles", 0); + std::string debugInDiscardFile = configTree.get("qc.config.infologger.debugInDiscardFile", "false"); + auto debugInDiscardFileBool = debugInDiscardFile == "true"; + ILOG_INST.filterDiscardSetFile(infologgerDiscardFile.c_str(), rotateMaxBytes, rotateMaxFiles, 0, !debugInDiscardFileBool /*Do not store Debug messages in file*/); + + std::string id = "runQC"; + for (size_t i = 0; i < config.argc(); i++) { + if (std::strcmp(config.argv()[i], "--id") == 0 && i + 1 < config.argc()) { + id = config.argv()[i + 1]; + break; + } + } + o2::quality_control::core::QcInfoLogger::setFacility(id); +} + WorkflowSpec defineDataProcessing(const ConfigContext& config) { WorkflowSpec specs; @@ -155,29 +183,7 @@ WorkflowSpec defineDataProcessing(const ConfigContext& config) // we set the infologger levels as soon as possible to avoid spamming auto configTree = ConfigurationFactory::getConfiguration(qcConfigurationSource)->getRecursive(); - if (config.options().get("no-infologger")) { - quality_control::core::QcInfoLogger::disable(); - } else { - auto infologgerFilterDiscardDebug = configTree.get("qc.config.infologger.filterDiscardDebug", true); - auto infologgerDiscardLevel = configTree.get("qc.config.infologger.filterDiscardLevel", 21); - ILOG_INST.filterDiscardDebug(infologgerFilterDiscardDebug); - ILOG_INST.filterDiscardLevel(infologgerDiscardLevel); - } - auto infologgerDiscardFile = configTree.get("qc.config.infologger.filterDiscardFile", ""); - auto rotateMaxBytes = configTree.get("qc.config.infologger.filterRotateMaxBytes", 0); - auto rotateMaxFiles = configTree.get("qc.config.infologger.filterRotateMaxFiles", 0); - std::string debugInDiscardFile = configTree.get("qc.config.infologger.debugInDiscardFile", "false"); - auto debugInDiscardFileBool = debugInDiscardFile == "true"; - ILOG_INST.filterDiscardSetFile(infologgerDiscardFile.c_str(), rotateMaxBytes, rotateMaxFiles, 0, !debugInDiscardFileBool /*Do not store Debug messages in file*/); - - std::string id = "runQC"; - for (size_t i = 0; i < config.argc(); i++) { - if (std::strcmp(config.argv()[i], "--id") == 0 && i + 1 < config.argc()) { - id = config.argv()[i + 1]; - break; - } - } - o2::quality_control::core::QcInfoLogger::setFacility(id); + setupInfologger(config, configTree); ILOG(Info, Devel) << "Using config file '" << qcConfigurationSource << "'" << ENDM; auto keyValuesToOverride = quality_control::core::parseOverrideValues(config.options().get("override-values"));