Skip to content

Commit

Permalink
Use Lower Case FairLogger Severities
Browse files Browse the repository at this point in the history
Upper case severities are deprecated in FairLogger 1.10.
So switch all severities over to lower case.
  • Loading branch information
ChristianTackeGSI authored and dennisklein committed Apr 13, 2022
1 parent b2a059c commit dbd27ae
Show file tree
Hide file tree
Showing 10 changed files with 23 additions and 23 deletions.
4 changes: 2 additions & 2 deletions base/steer/FairRootManager.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -1059,7 +1059,7 @@ void FairRootManager::UpdateFileName(TString& fileName)

TFile* FairRootManager::GetOutFile()
{
LOG(WARNING) << "FairRootManager::GetOutFile() deprecated. Use separate file to store additional data.";
LOG(warning) << "FairRootManager::GetOutFile() deprecated. Use separate file to store additional data.";
auto sink = GetSink();
assert(sink->GetSinkType() == kFILESINK);
auto rootFileSink = static_cast<FairRootFileSink*>(sink);
Expand All @@ -1068,7 +1068,7 @@ TFile* FairRootManager::GetOutFile()

TTree* FairRootManager::GetOutTree()
{
LOG(WARNING) << "FairRootManager::GetOutTree() deprecated. Use separate file to store additional data.";
LOG(warning) << "FairRootManager::GetOutTree() deprecated. Use separate file to store additional data.";
auto sink = GetSink();
assert(sink->GetSinkType() == kFILESINK);
auto rootFileSink = static_cast<FairRootFileSink*>(sink);
Expand Down
8 changes: 4 additions & 4 deletions base/steer/FairRun.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ Bool_t FairRun::GetWriteRunInfoFile()

void FairRun::SetOutputFile(const char* fname)
{
LOG(WARNING) << "FairRun::SetOutputFile() deprecated. Use FairRootFileSink.";
LOG(warning) << "FairRun::SetOutputFile() deprecated. Use FairRootFileSink.";
fSink = new FairRootFileSink(fname);
if (fRootManager)
fRootManager->SetSink(fSink);
Expand All @@ -173,7 +173,7 @@ void FairRun::SetOutputFile(const char* fname)

void FairRun::SetOutputFile(TFile* f)
{
LOG(WARNING) << "FairRun::SetOutputFile() deprecated. Use FairRootFileSink.";
LOG(warning) << "FairRun::SetOutputFile() deprecated. Use FairRootFileSink.";
fSink = new FairRootFileSink(f);
if (fRootManager)
fRootManager->SetSink(fSink);
Expand All @@ -183,7 +183,7 @@ void FairRun::SetOutputFile(TFile* f)

void FairRun::SetOutputFileName(const TString& name)
{
LOG(WARNING) << "FairRun::SetOutputFileName() deprecated. Use FairRootFileSink.";
LOG(warning) << "FairRun::SetOutputFileName() deprecated. Use FairRootFileSink.";
fSink = new FairRootFileSink(name);
if (fRootManager)
fRootManager->SetSink(fSink);
Expand All @@ -192,7 +192,7 @@ void FairRun::SetOutputFileName(const TString& name)

TFile* FairRun::GetOutputFile()
{
LOG(WARNING) << "FairRun::GetOutputFile() deprecated. Use separate file to store additional data.";
LOG(warning) << "FairRun::GetOutputFile() deprecated. Use separate file to store additional data.";
auto sink = GetSink();
assert(sink->GetSinkType() == kFILESINK);
auto rootFileSink = static_cast<FairRootFileSink*>(sink);
Expand Down
6 changes: 3 additions & 3 deletions examples/MQ/pixelSimSplit/run/runMQGen.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -50,14 +50,14 @@ FairMQDevicePtr getDevice(const FairMQProgOptions& config)
primGen->AddGenerator(boxGen);

FairMQPrimaryGeneratorDevice* mqDevice = new FairMQPrimaryGeneratorDevice();
LOG(INFO) << "Going to generate " << config.GetValue<int64_t>("nof-events") << " events.";
LOG(info) << "Going to generate " << config.GetValue<int64_t>("nof-events") << " events.";
mqDevice->SetChunkSize(config.GetValue<int64_t>("chunk-size"));
mqDevice->RunInPushMode(true);
if (config.GetValue<std::string>("running-mode") == "rr") {
LOG(INFO) << "Going to reply with data.";
LOG(info) << "Going to reply with data.";
mqDevice->RunInPushMode(false);
} else {
LOG(INFO) << "Going to push data.";
LOG(info) << "Going to push data.";
}

mqDevice->SetNofEvents(config.GetValue<int64_t>("nof-events"));
Expand Down
4 changes: 2 additions & 2 deletions examples/MQ/pixelSimSplit/run/runMQTrans.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,10 @@ FairMQDevicePtr getDevice(const FairMQProgOptions& config)
FairMQTransportDevice* run = new FairMQTransportDevice();
run->RunInPullMode(true);
if (config.GetValue<std::string>("running-mode") == "rr") {
LOG(INFO) << "Going to request data.";
LOG(info) << "Going to request data.";
run->RunInPullMode(false);
} else {
LOG(INFO) << "Going to pull data.";
LOG(info) << "Going to pull data.";
}

// TString outputfilename = Form("outputfile_%d.root",(int)(getpid()));
Expand Down
8 changes: 4 additions & 4 deletions examples/advanced/propagator/src/FairEveRecoTracksExample.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -197,23 +197,23 @@ InitStatus FairEveRecoTracksExample::Init()
FairRootManager *mngr = FairRootManager::Instance();
fContainerReco = (TClonesArray *)mngr->GetObject("FairTutPropTracks");
if (fContainerReco == nullptr) {
LOG(ERROR) << "Reco traks not found";
LOG(error) << "Reco traks not found";
return kFATAL;
}
fHits1 = (TClonesArray *)mngr->GetObject("FairTutPropHits");
fHits2 = (TClonesArray *)mngr->GetObject("FairTutPropHits2");
if (fHits1 == nullptr || fHits2 == nullptr) {
LOG(ERROR) << "Hits not found";
LOG(error) << "Hits not found";
return kFATAL;
}
fContainerSim = (TClonesArray *)mngr->GetObject("MCTrack");
if (fContainerSim == nullptr) {
LOG(WARNING) << "No branch with MC tracks";
LOG(warning) << "No branch with MC tracks";
}
FairRunAna *ana = FairRunAna::Instance();
FairField *field = ana->GetField();
if (field == nullptr) {
LOG(ERROR) << "Lack of magnetic field map!";
LOG(error) << "Lack of magnetic field map!";
field = new FairField();
}
fRK = new FairRKPropagator(field);
Expand Down
2 changes: 1 addition & 1 deletion examples/common/eventdisplay/FairEveMCTracks.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ InitStatus FairEveMCTracks::Init()
FairRunAna *ana = FairRunAna::Instance();
FairField *field = ana->GetField();
if (field == nullptr) {
LOG(ERROR) << "Lack of magnetic field map!";
LOG(error) << "Lack of magnetic field map!";
} else {
fRK = new FairRKPropagator(field);
}
Expand Down
2 changes: 1 addition & 1 deletion examples/common/mcstack/FairStack.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,7 @@ void FairStack::Print(Option_t*) const
LOG(info) << "FairStack: Number of primaries = " << fNPrimaries;
LOG(info) << " Total number of particles = " << fNParticles;
LOG(info) << " Number of tracks in output = " << fNTracks;
if (gLogger->IsLogNeeded(fair::Severity::DEBUG1)) {
if (gLogger->IsLogNeeded(fair::Severity::debug1)) {
for (Int_t iTrack = 0; iTrack < fNTracks; iTrack++) {
(static_cast<FairMCTrack*>(fTracks->At(iTrack))->Print(iTrack));
}
Expand Down
4 changes: 2 additions & 2 deletions examples/simulation/Tutorial4/src/mc/FairTutorialDet4.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -112,9 +112,9 @@ void FairTutorialDet4::SetParContainers()
LOG(info) << "Set tutdet missallign parameters";
// Get Base Container
FairRun* sim = FairRun::Instance();
LOG_IF(FATAL, !sim) << "No run object";
LOG_IF(fatal, !sim) << "No run object";
FairRuntimeDb* rtdb = sim->GetRuntimeDb();
LOG_IF(FATAL, !rtdb) << "No runtime database";
LOG_IF(fatal, !rtdb) << "No runtime database";

fMisalignPar = static_cast<FairTutorialDet4MisalignPar*>(rtdb->getContainer("FairTutorialDet4MissallignPar"));
}
Expand Down
2 changes: 1 addition & 1 deletion fairtools/FairMonitor.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ void FairMonitor::PrintTask(TTask* tempTask, Int_t taskLevel) const
printString.Insert(0, "[\033[43m");
else
printString.Insert(0, "[\033[41m");
LOG(INFO) << printString.Data();
LOG(info) << printString.Data();
}

TList* subTaskList = tempTask->GetListOfTasks();
Expand Down
6 changes: 3 additions & 3 deletions parmq/ParameterMQServer.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -144,15 +144,15 @@ bool ParameterMQServer::ProcessRequest(FairMQMessagePtr& req, int /*index*/)
RootSerializer().Serialize(*rep, par);

if (Send(rep, fRequestChannelName, 0) < 0) {
LOG(ERROR) << "failed sending reply";
LOG(error) << "failed sending reply";
return false;
}
} else {
LOG(ERROR) << "Parameter uninitialized! Sending empty message back";
LOG(error) << "Parameter uninitialized! Sending empty message back";
// Send an empty message back to keep the REQ/REP cycle
FairMQMessagePtr rep(NewMessage());
if (Send(rep, fRequestChannelName, 0) < 0) {
LOG(ERROR) << "failed sending reply";
LOG(error) << "failed sending reply";
return false;
}
}
Expand Down

0 comments on commit dbd27ae

Please sign in to comment.