Skip to content
Snippets Groups Projects
Commit b61bf4ac authored by Walter Lampl's avatar Walter Lampl
Browse files

Merge branch 'context.LArCellRec-20190509' into 'master'

LArCellRec: Avoid EventContext TLS lookups.

See merge request atlas/athena!23286
parents 55169d4e cfbbe39e
No related branches found
No related tags found
No related merge requests found
...@@ -65,11 +65,11 @@ StatusCode LArCellGainPathology::finalize() ...@@ -65,11 +65,11 @@ StatusCode LArCellGainPathology::finalize()
} }
StatusCode LArCellGainPathology::process (CaloCellContainer* theCont, StatusCode LArCellGainPathology::process (CaloCellContainer* theCont,
const EventContext& /*ctx*/) const const EventContext& ctx) const
{ {
ATH_MSG_DEBUG (" in LArCellGainPathology::process "); ATH_MSG_DEBUG (" in LArCellGainPathology::process ");
SG::ReadCondHandle<LArOnOffIdMapping> cablingHdl{m_cablingKey}; SG::ReadCondHandle<LArOnOffIdMapping> cablingHdl{m_cablingKey, ctx};
const LArOnOffIdMapping* cabling=*cablingHdl; const LArOnOffIdMapping* cabling=*cablingHdl;
// loop over all Febs // loop over all Febs
......
...@@ -30,7 +30,7 @@ StatusCode LArCellHVCorrAlg::initialize() { ...@@ -30,7 +30,7 @@ StatusCode LArCellHVCorrAlg::initialize() {
StatusCode LArCellHVCorrAlg::execute(CaloCellContainer* cellCollection, const EventContext& ctx) const { StatusCode LArCellHVCorrAlg::execute(CaloCellContainer* cellCollection, const EventContext& ctx) const {
// get offline HVScaleCorr // get offline HVScaleCorr
SG::ReadCondHandle<ILArHVScaleCorr> oflHVCorrHdl(m_offlineHVScaleCorrKey); SG::ReadCondHandle<ILArHVScaleCorr> oflHVCorrHdl(m_offlineHVScaleCorrKey, ctx);
const ILArHVScaleCorr *oflHVCorr = *oflHVCorrHdl; const ILArHVScaleCorr *oflHVCorr = *oflHVCorrHdl;
if(!oflHVCorr) { if(!oflHVCorr) {
ATH_MSG_ERROR("Do not have ofline HV corr. conditions object !!!!"); ATH_MSG_ERROR("Do not have ofline HV corr. conditions object !!!!");
...@@ -58,16 +58,16 @@ StatusCode LArCellHVCorrAlg::execute(CaloCellContainer* cellCollection, const Ev ...@@ -58,16 +58,16 @@ StatusCode LArCellHVCorrAlg::execute(CaloCellContainer* cellCollection, const Ev
void LArCellHVCorrAlg::MakeCorrection (CaloCell* theCell, void LArCellHVCorrAlg::MakeCorrection (CaloCell* theCell,
const EventContext& /*ctx*/) const // this method will be removed soon, but kept to make CI happy const EventContext& ctx) const // this method will be removed soon, but kept to make CI happy
{ {
// get offline HVScaleCorr // get offline HVScaleCorr
SG::ReadCondHandle<ILArHVScaleCorr> oflHVCorrHdl(m_offlineHVScaleCorrKey); SG::ReadCondHandle<ILArHVScaleCorr> oflHVCorrHdl(m_offlineHVScaleCorrKey, ctx);
const ILArHVScaleCorr *oflHVCorr = *oflHVCorrHdl; const ILArHVScaleCorr *oflHVCorr = *oflHVCorrHdl;
if(!oflHVCorr) { if(!oflHVCorr) {
ATH_MSG_ERROR("Do not have ofline HV corr. conditions object !!!!"); ATH_MSG_ERROR("Do not have ofline HV corr. conditions object !!!!");
return; return;
} }
SG::ReadCondHandle<LArOnOffIdMapping> cablingHdl{m_cablingKey}; SG::ReadCondHandle<LArOnOffIdMapping> cablingHdl{m_cablingKey, ctx};
const LArOnOffIdMapping* cabling{*cablingHdl}; const LArOnOffIdMapping* cabling{*cablingHdl};
if(!cabling){ if(!cabling){
ATH_MSG_ERROR("Do not have mapping object " << m_cablingKey.key() ); ATH_MSG_ERROR("Do not have mapping object " << m_cablingKey.key() );
......
...@@ -71,7 +71,7 @@ StatusCode LArCellMerger::process (CaloCellContainer* theCont, ...@@ -71,7 +71,7 @@ StatusCode LArCellMerger::process (CaloCellContainer* theCont,
return StatusCode::FAILURE; return StatusCode::FAILURE;
} }
SG::ReadCondHandle<LArOnOffIdMapping> larCablingHdl(m_cablingKey); SG::ReadCondHandle<LArOnOffIdMapping> larCablingHdl(m_cablingKey, ctx);
const LArOnOffIdMapping* cabling=*larCablingHdl; const LArOnOffIdMapping* cabling=*larCablingHdl;
unsigned nReplaced=0; unsigned nReplaced=0;
......
/* /*
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
*/ */
...@@ -95,7 +95,7 @@ StatusCode LArNoisyROAlg::execute (const EventContext& ctx) const ...@@ -95,7 +95,7 @@ StatusCode LArNoisyROAlg::execute (const EventContext& ctx) const
if ( badFEBFlag || badFEBFlag_W || badSaturatedTightCut || MNBLooseCut || MNBTightCut || MNBTight_PsVetoCut) if ( badFEBFlag || badFEBFlag_W || badSaturatedTightCut || MNBLooseCut || MNBTightCut || MNBTight_PsVetoCut)
{ {
// retrieve EventInfo // retrieve EventInfo
SG::ReadHandle<xAOD::EventInfo> eventInfo (m_eventInfoKey); SG::ReadHandle<xAOD::EventInfo> eventInfo (m_eventInfoKey, ctx);
bool failSetWARN=false; bool failSetWARN=false;
bool failSetWARNREASON=false; bool failSetWARNREASON=false;
......
/* /*
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
*/ */
#include "LArTimeVetoAlg.h" #include "LArTimeVetoAlg.h"
...@@ -64,7 +64,7 @@ StatusCode LArTimeVetoAlg::execute( const EventContext& ctx ) const ...@@ -64,7 +64,7 @@ StatusCode LArTimeVetoAlg::execute( const EventContext& ctx ) const
//m_nevtMasked++; //m_nevtMasked++;
// retrieve EventInfo // retrieve EventInfo
SG::ReadHandle<xAOD::EventInfo> eventInfo (m_eventInfoKey); SG::ReadHandle<xAOD::EventInfo> eventInfo (m_eventInfoKey, ctx);
if (!eventInfo->updateErrorState(xAOD::EventInfo::LAr,xAOD::EventInfo::Error)) { if (!eventInfo->updateErrorState(xAOD::EventInfo::LAr,xAOD::EventInfo::Error)) {
ATH_MSG_WARNING( " cannot set error state for LAr " ); ATH_MSG_WARNING( " cannot set error state for LAr " );
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment