5#include <GaudiKernel/DataIncident.h>
8#define ATHENASERVICES_ATHENAHIVEEVENTLOOPMGR_CPP
29#include "GaudiKernel/IAlgorithm.h"
30#include "GaudiKernel/SmartIF.h"
31#include "GaudiKernel/Incident.h"
32#include "GaudiKernel/DataObject.h"
33#include "GaudiKernel/IIncidentSvc.h"
34#include "GaudiKernel/IEvtSelector.h"
35#include "GaudiKernel/IDataManagerSvc.h"
36#include "GaudiKernel/IDataProviderSvc.h"
37#include "GaudiKernel/IConversionSvc.h"
38#include "GaudiKernel/GaudiException.h"
39#include "GaudiKernel/AppReturnCode.h"
40#include "GaudiKernel/MsgStream.h"
41#include "Gaudi/Property.h"
42#include "GaudiKernel/EventIDBase.h"
43#include "GaudiKernel/ThreadLocalContext.h"
47#include "EventInfo/EventInfo.h"
55#include <GaudiKernel/IScheduler.h>
57#include "tbb/tick_count.h"
66 : base_class(nam, svcLoc),
79 "Name of Event Selector to use. If empty string (default) "
80 "take value from ApplicationMgr");
82 "Histogram persistency technology to use: ROOT, HBOOK, NONE. "
83 "By default (empty string) get property value from "
86 "histogram write/update interval");
88 "Controls behaviour of event loop depending on return code of"
89 " Algorithms. 0: all non-SUCCESSes terminate job. "
90 "1: RECOVERABLE skips to next event, FAILURE terminates job "
91 "(DEFAULT). 2: RECOVERABLE and FAILURE skip to next events");
93 "Print event heartbeat printouts every m_eventPrintoutInterval events");
94 declareProperty(
"PreSelectTools",
m_tools,
"AlgTools for event pre-selection")->
98 "Name of the scheduler to be used");
101 "Name of the Whiteboard to be used");
107 "ServiceHandle for EvtIdModifierSvc");
109 declareProperty(
"FakeLumiBlockInterval",
m_flmbi = 0,
110 "Event interval at which to increment lumiBlock# when "
111 "creating events without an EventSelector. Zero means "
112 "don't increment it");
114 "timestamp interval between events when creating Events "
115 "without an EventSelector");
117 "Require valid input attribute list to be present");
119 "In case of DoubleEventSelector use event number from secondary input");
122 "process all of first event before scheduling any more");
144 StatusCode
sc = MinimalEventLoopMgr::initialize();
145 if ( !
sc.isSuccess() )
147 ATH_MSG_ERROR (
"Failed to initialize base class MinimalEventLoopMgr" );
158 return StatusCode::FAILURE;
163 ATH_MSG_FATAL (
"Error retrieving SchedulerSvc interface ISchedulerSvc." );
164 return StatusCode::FAILURE;
170 return StatusCode::FAILURE;
173 m_aess = serviceLocator()->service(
"AlgExecStateSvc");
176 return StatusCode::FAILURE;
180 if( !
sc.isSuccess() )
182 ATH_MSG_FATAL (
"Error retrieving pointer to StoreGateSvc" );
191 if( !
sc.isSuccess() )
200 SmartIF<IProperty> prpMgr(serviceLocator());
201 if ( !prpMgr.isValid() )
203 ATH_MSG_FATAL (
"IProperty interface not found in ApplicationMgr." );
204 return StatusCode::FAILURE;
212 if( !
sc.isSuccess() )
219 if ( histPersName.length() == 0 )
224 if ( histPersName !=
"NONE" ) {
229 SmartIF<IProperty> histSvc;
230 if (histPersName ==
"ROOT") {
231 histSvc = serviceLocator()->service(
"RootHistSvc");
232 }
else if ( histPersName ==
"HBOOK" ) {
233 histSvc = serviceLocator()->service(
"HbookHistSvc");
237 ATH_MSG_ERROR (
"could not locate actual Histogram persistency service" );
239 const Gaudi::Details::PropertyBase &prop = histSvc->getProperty(
"OutputFile");
242 const StringProperty &sprop =
dynamic_cast<const StringProperty&
>( prop );
245 ATH_MSG_VERBOSE (
"could not dcast OutputFile property to a StringProperty."
246 " Need to fix Gaudi." );
247 val = prop.toString();
251 val !=
"UndefinedROOTOutputFileName" &&
252 val !=
"UndefinedHbookOutputFileName" ) {
265 ATH_MSG_DEBUG (
"EventID modifier Service not set. No run number, ... overrides will be applied." );
268 ATH_MSG_INFO (
"Could not find EventID modifier Service. No run number, ... overrides will be applied." );
274 const std::string& selName(
m_evtsel.value());
281 if( !selName.empty() && selName !=
"NONE") {
282 SmartIF<IEvtSelector> theEvtSel{serviceLocator()->service( selName )};
289 ATH_MSG_FATAL (
"Can not create the event selector Context." );
290 return StatusCode::FAILURE;
292 if (msgLevel(MSG::INFO)) {
293 SmartIF<INamedInterface> named(theEvtSel);
295 ATH_MSG_INFO (
"Setup EventSelector service {}", named->name( ) );
298 }
else if (
sc.isFailure()) {
299 ATH_MSG_FATAL (
"No valid event selector called {}", selName );
300 return StatusCode::FAILURE;
338 unsigned int toolCtr = 0;
339 for ( ; firstTool != lastTool; ++firstTool )
359 StatusCode
sc = MinimalEventLoopMgr::finalize();
393 unsigned int toolCtr = 0;
394 ATH_MSG_INFO (
"Summary of AthenaEvtLoopPreSelectTool invocation: (invoked/success/failure)" );
395 ATH_MSG_INFO (
"-----------------------------------------------------" );
397 for ( ; firstTool != lastTool; ++firstTool ) {
400 (*firstTool)->name(),
407 return (
sc.isFailure() || sc2.isFailure() ) ? StatusCode::FAILURE :
417 StatusCode
sc (StatusCode::SUCCESS);
420 std::vector<DataObject*> objects;
422 DataObject* obj = reg->object();
423 if ( !obj || obj->clID() == CLID_StatisticsFile )
return false;
424 objects.push_back( obj );
428 if ( !
sc.isSuccess() ) {
429 ATH_MSG_ERROR (
"Error while traversing Histogram data store" );
433 if ( objects.size() > 0) {
436 if (
m_nevt == 1 || force ||
437 (writeInterval != 0 &&
m_nevt%writeInterval == 0) ) {
440 sc = std::accumulate( begin( objects ), end( objects ),
sc, [&]( StatusCode isc,
auto& i ) {
441 IOpaqueAddress* pAddr =
nullptr;
443 if ( iret.isFailure() )
return iret;
444 i->registry()->setAddress( pAddr );
447 sc = std::accumulate( begin( objects ), end( objects ),
sc, [&]( StatusCode isc,
auto& i ) {
448 IRegistry* reg = i->registry();
449 StatusCode iret =
m_histoPersSvc->fillRepRefs( reg->address(), i );
450 return iret.isFailure() ? iret : isc;
452 if ( !
sc.isSuccess() ) {
457 if (force || (writeInterval != 0 &&
m_nevt%writeInterval == 0) ) {
473 return StatusCode::SUCCESS;
481 return StatusCode::SUCCESS;
493 ATH_MSG_ALWAYS (
"A stopRun was requested by an incidentListener. "
494 "Do not process this event." );
496 return (StatusCode::SUCCESS);
502 Gaudi::Hive::setCurrentContext ( ctx );
505 if (declEvtRootSc == 0 ) {
507 return StatusCode::SUCCESS;
508 }
else if ( declEvtRootSc == -1) {
510 ATH_MSG_ERROR (
"declareEventRootAddress for context " << ctx <<
" failed" );
511 return StatusCode::FAILURE;
514 EventID::event_number_t evtNumber = ctx.eventID().event_number();
515 unsigned int conditionsRun = ctx.eventID().run_number();
520 if (attr->exists (
"ConditionsRun")) {
521 conditionsRun = (*attr)[
"ConditionsRun"].data<
unsigned int>();
526 Gaudi::Hive::setCurrentContext ( ctx );
529 if (
m_eventStore->record(std::make_unique<EventContext> (ctx),
530 "EventContext").isFailure())
533 return (StatusCode::FAILURE);
553 bool toolsPassed=
true;
558 unsigned int toolCtr=0;
560 tool_store::iterator theTool =
m_tools.begin();
561 tool_store::iterator lastTool =
m_tools.end();
562 while(toolsPassed && theTool!=lastTool )
564 toolsPassed = (*theTool)->passEvent(ctx.eventID());
576 ATH_MSG_INFO (
" ===>>> start processing event #{}, run #{} on slot {}, {} events processed so far <<<===",
580 ATH_MSG_INFO (
" ===>>> start processing event #{}, run #{} on slot {}, {} events read and {} events processed so far <<<===",
590 Gaudi::Hive::setCurrentContext(EventContext());
591 return StatusCode::FAILURE;
600 Gaudi::Hive::setCurrentContext( EventContext() );
602 return StatusCode::SUCCESS;
613 bool eventfailed =
false;
621 return StatusCode::FAILURE;
624 return StatusCode::SUCCESS;
631 SmartIF<IProperty> appmgr(serviceLocator());
632 if(Gaudi::setAppReturnCode(appmgr, Gaudi::ReturnCode::ScheduledStop,
true).isFailure()) {
633 ATH_MSG_ERROR (
"Could not set return code of the application ({})",
634 Gaudi::ReturnCode::ScheduledStop);
637 return StatusCode::SUCCESS;
651 StatusCode
sc = MinimalEventLoopMgr::stop();
658 for (
size_t islot = 0; islot < nslot; islot++) {
662 Gaudi::Hive::setCurrentContext( EventContext() );
673 if (0 == maxevt)
return StatusCode::SUCCESS;
676 Gaudi::setAppReturnCode(
m_appMgrProperty, Gaudi::ReturnCode::Success,
true).ignore();
687 bool loop_ended=
false;
688 StatusCode
sc(StatusCode::SUCCESS);
693 auto start_time = tbb::tick_count::now();
694 auto secsFromStart = [&start_time]()->
double{
695 return (tbb::tick_count::now()-start_time).seconds();
698 while ( !loop_ended and ( (maxevt < 0) or (finishedEvts < maxevt) ) ){
703 (newEvtAllowed || createdEvts == 0) &&
704 ( (createdEvts < maxevt) or (maxevt<0) ) &&
712 if ( !ctx.valid() ) {
713 sc = StatusCode::FAILURE;
718 if (
sc.isFailure()) {
719 ATH_MSG_ERROR (
"Terminating event processing loop due to errors" );
738 sc = StatusCode::FAILURE;
739 }
else if (
ir == 0) {
742 sc = StatusCode::SUCCESS;
746 newEvtAllowed =
true;
751 ATH_MSG_INFO (
"---> Loop Finished (seconds): {}", secsFromStart() );
768 ATH_MSG_ERROR (
"Seek failed; unsupported by event selector" );
769 return StatusCode::FAILURE;
774 ATH_MSG_FATAL (
"Can not create the event selector Context." );
775 return StatusCode::FAILURE;
781 if (
sc.isSuccess()) {
782 m_incidentSvc->fireIncident(ContextIncident<std::tuple<int, int>>(
783 name(),
"SkipEvents", std::tuple<int, int>(
m_nevt, evt)));
808 ATH_MSG_ERROR (
"Collection size unsupported by event selector" );
814 ATH_MSG_FATAL (
"Can not create the event selector Context." );
829 if(inc.type() ==
"EndAlgorithms") {
835 if( !
sc.isSuccess() ) {
841 if(inc.type()!=
"BeforeFork")
845 ATH_MSG_WARNING (
"Skipping BeforeFork handler. Either no event selector is provided or begin run has already passed" );
857 if(!
sc.isSuccess()) {
861 IOpaqueAddress* addr{
nullptr};
863 if (
sc.isFailure()) {
870 if(!
sc.isSuccess()) {
884 if(!
sc.isSuccess()) {
894 if(!
sc.isSuccess()) {
905 if ( !
sc.isSuccess() ) {
910 if( !
sc.isSuccess() ) {
912 if (
sc.isSuccess() ) {
914 if ( !
sc.isSuccess() ) {
931 StatusCode
sc(StatusCode::SUCCESS);
936 std::unique_ptr<const EventInfo> pEvent{};
943 IOpaqueAddress* addr{};
947 if ( !
sc.isSuccess() ) {
963 if( !
sc.isSuccess() ) {
973 bool consume_modifier_stream =
false;
977 if ( pAttrList !=
nullptr && pAttrList->size() > 6 ) {
979 unsigned int runNumber = (*pAttrList)[
"RunNumber"].data<
unsigned int>();
980 unsigned long long eventNumber = (*pAttrList)[
"EventNumber"].data<
unsigned long long>();
981 unsigned int eventTime = (*pAttrList)[
"EventTime"].data<
unsigned int>();
982 unsigned int eventTimeNS = (*pAttrList)[
"EventTimeNanoSec"].data<
unsigned int>();
983 unsigned int lumiBlock = (*pAttrList)[
"LumiBlockN"].data<
unsigned int>();
984 unsigned int bunchId = (*pAttrList)[
"BunchId"].data<
unsigned int>();
987 consume_modifier_stream =
true;
990 unsigned long long eventNumberSecondary{};
991 if ( !(pAttrList->exists(
"hasSecondaryInput") && (*pAttrList)[
"hasSecondaryInput"].data<
bool>()) ) {
992 ATH_MSG_FATAL (
"Secondary EventNumber requested, but secondary input does not exist!" );
995 if ( pAttrList->exists(
"EventNumber_secondary") ) {
996 eventNumberSecondary = (*pAttrList)[
"EventNumber_secondary"].data<
unsigned long long>();
1002 if (pEventSecondary) {
1003 eventNumberSecondary = pEventSecondary->
event_ID()->event_number();
1006 ATH_MSG_FATAL (
"Secondary EventNumber requested, but it does not exist!" );
1010 if (eventNumberSecondary != 0) {
1014 ATH_MSG_INFO (
" ===>>> using secondary event #{} instead of #{} <<<===",
1015 eventNumberSecondary, eventNumber);
1017 eventNumber = eventNumberSecondary;
1021 pEvent = std::make_unique<EventInfo>(
1022 std::make_unique<EventID>(runNumber, eventNumber, eventTime,
1023 eventTimeNS, lumiBlock, bunchId),
1028 ATH_MSG_FATAL (
"Valid input attribute list required but not present!" );
1032 const EventInfo* pEventObserver{pEvent.get()};
1033 if (!pEventObserver) {
1038 if (pEventObserver) {
1039 consume_modifier_stream =
false;
1046 if( !
sc.isSuccess() ) {
1050 consume_modifier_stream =
true;
1053 pEvent = std::make_unique<EventInfo>(
1056 pEventObserver = pEvent.get();
1058 if( !
sc.isSuccess() ) {
1066 consume_modifier_stream);
1073 unsigned int runNmb{1}, evtNmb{
m_nevt + 1};
1080 auto eid = std::make_unique<EventID> (runNmb,evtNmb,
m_timeStamp);
1082 eid->set_lumi_block( runNmb );
1086 pEvent = std::make_unique<EventInfo>(std::move(eid),
1087 std::make_unique<EventType>());
1089 bool consume_modifier_stream =
true;
1100 ATH_MSG_DEBUG (
"recording EventInfo " << *pEvent->event_ID() <<
" in "
1104 if( !
sc.isSuccess() ) {
1121 m_evtIdModSvc->modify_evtid(new_eID, ctx.evt(), consume_modifier_stream);
1122 if (msgLevel(MSG::DEBUG)) {
1123 unsigned int oldrunnr=eID.run_number();
1124 unsigned int oldLB=eID.lumi_block();
1125 unsigned int oldTS=eID.time_stamp();
1126 unsigned int oldTSno=eID.time_stamp_ns_offset();
1127 ATH_MSG_DEBUG (
"modifyEventContext: use evtIdModSvc runnr={} -> {}",
1128 oldrunnr, new_eID.run_number());
1129 ATH_MSG_DEBUG (
"modifyEventContext: use evtIdModSvc LB={} -> {}",
1130 oldLB, new_eID.lumi_block());
1131 ATH_MSG_DEBUG (
"modifyEventContext: use evtIdModSvc TimeStamp={} -> {}",
1132 oldTS, new_eID.time_stamp());
1133 ATH_MSG_DEBUG (
"modifyEventContext: use evtIdModSvc TimeStamp ns Offset={} -> {}",
1134 oldTSno, new_eID.time_stamp_ns_offset());
1136 ctx.setEventID( new_eID );
1141 ctx.setEventID( eID );
1150 const size_t slot =
m_whiteboard->allocateStore(eventNumber);
1151 if (slot == std::string::npos) {
1153 return EventContext{};
1158 return EventContext{};
1160 EventContext ctx{eventNumber, slot};
1171 auto submitted = std::make_unique<EventContext>(ctx);
1173 Incident(
name(), IncidentType::BeginProcessing, ctx));
1176 Incident(
name(), IncidentType::EndProcessing, ctx));
1178 return StatusCode::FAILURE;
1180 submitted.release();
1183 ctx = EventContext();
1184 return StatusCode::SUCCESS;
1188 if (
m_aess->eventStatus(ctx) != EventStatus::Success) {
1191 <<
m_aess->eventStatus(ctx));
1192 return StatusCode::FAILURE;
1194 return StatusCode::SUCCESS;
1198 StatusCode result =
m_whiteboard->selectStore(ctx.slot());
1199 if (result.isSuccess()) {
1200 Gaudi::Hive::setCurrentContext(ctx);
1203 Incident(
name(), IncidentType::EndProcessing, ctx));
1205 ATH_MSG_ERROR(
"Could not select completed slot {}", ctx.slot());
1214 m_aess->eventStatus(ctx) != EventStatus::Success) {
1218 if (result.isFailure()) {
1219 Gaudi::Hive::setCurrentContext(EventContext());
1225 const auto n_evt = ctx.eventID().event_number();
1226 const auto n_run = ctx.eventID().run_number();
1227 ATH_MSG_INFO(
" ===>>> done processing event #{}, run #{} on slot {}, {} events processed so far <<<===",
1228 n_evt, n_run, ctx.slot(),
m_proc);
1229 std::ofstream outfile(
"eventLoopHeartBeat.txt");
1232 Gaudi::Hive::setCurrentContext(EventContext());
1233 return StatusCode::FAILURE;
1235 std::println(outfile,
" done processing event #{}, run #{} {} events read so far <<<===",
1236 n_evt, n_run,
m_nev);
1238 Gaudi::Hive::setCurrentContext(EventContext());
1239 return StatusCode::SUCCESS;
1247 StatusCode
sc(StatusCode::SUCCESS);
1250 std::vector<std::unique_ptr<EventContext>> finishedEvtContexts;
1252 EventContext* finishedEvtContext(
nullptr);
1255 ATH_MSG_DEBUG (
"drainScheduler: [{}] Waiting for a context", finishedEvts);
1259 if (
sc.isSuccess()){
1261 ATH_MSG_DEBUG (
"drainScheduler: scheduler not empty: Context "
1262 << finishedEvtContext );
1263 finishedEvtContexts.emplace_back(finishedEvtContext);
1271 while (
m_schedulerSvc->tryPopFinishedEvent(finishedEvtContext).isSuccess()){
1272 finishedEvtContexts.emplace_back(finishedEvtContext);
1277 for (
auto& thisFinishedEvtContext : finishedEvtContexts){
1278 if (!thisFinishedEvtContext) {
1279 ATH_MSG_FATAL (
"Detected nullptr ctxt while clearing WB!");
1284 if (
finishEvent(*thisFinishedEvtContext).isFailure()) {
1292 return ( fail ? -1 : 1 );
#define ATH_MSG_DEBUG(x,...)
#define ATH_MSG_ERROR(x,...)
#define ATH_MSG_ALWAYS(x,...)
#define ATH_MSG_WARNING(x,...)
#define ATH_MSG_VERBOSE(x,...)
#define ATH_MSG_INFO(x,...)
#define ATH_MSG_FATAL(x,...)
The default ATLAS batch event loop manager.
Helpers for checking error return status codes and reporting errors.
#define CHECK(...)
Evaluate an expression and check for errors.
Assign a CLID to EventContext.
This class provides a unique identification for each event, in terms of run/event number and/or a tim...
EventID eventIDFromxAOD(const xAOD::EventInfo *xaod)
Create EventID object from xAOD::EventInfo.
EventType eventTypeFromxAOD(const xAOD::EventInfo *xaod)
Create EventType object from xAOD::EventInfo.
This class provides general information about an event.
Abstract interface for seeking within an event stream.
Extension to IEvtSelector to allow for seeking.
void setProperty(columnar::PythonToolHandle &self, const std::string &key, nb::object value)
An AttributeList represents a logical row of attributes in a metadata table.
AthMessaging(IMessageSvc *msgSvc, const std::string &name)
Constructor.
An AttributeList represents a logical row of attributes in a metadata table.
UnsignedIntegerProperty m_eventPrintoutInterval
IEvtSelector * m_evtSelector
Reference to the Event Selector.
virtual StatusCode stopRun() override
implementation of IEventProcessor::stopRun()
virtual void handle(const Incident &inc) override
IIncidentListenet interfaces.
ServiceHandle< IConversionSvc > IConversionSvc_t
virtual StatusCode initialize() override
implementation of IAppMgrUI::initalize
IntegerProperty m_failureMode
SmartIF< IHiveWhiteBoard > m_whiteboard
Reference to the Whiteboard interface.
StatusCode getEventRoot(IOpaqueAddress *&refpAddr)
Create event address using event selector.
IConversionSvc_t m_histoPersSvc
int drainScheduler(int &finishedEvents)
Drain the scheduler from all actions that may be queued.
number_type m_currentRun
current run number
virtual int size() override
Return the size of the collection.
SmartIF< IAlgExecStateSvc > m_aess
Reference to the Algorithm Execution State Svc.
virtual const std::string & name() const override
std::string m_schedulerName
Name of the scheduler to be used.
UnsignedIntegerProperty m_writeInterval
virtual StatusCode eventFinished(const EventContext &ctx)
Process an event's result and decide whether the driving loop may continue.
EventContext allocateEventContext(size_t eventNumber)
std::string m_whiteboardName
Name of the Whiteboard to be used.
tool_stats m_toolAccept
tool returns StatusCode::SUCCESS counter
virtual StatusCode executeRun(int maxevt) override
implementation of IEventProcessor::executeRun(int maxevt)
tool_store::const_iterator tool_iterator
unsigned int m_nev
events processed
tool_stats m_toolInvoke
tool called counter
IIncidentSvc_t m_incidentSvc
Reference to the incident service.
virtual StatusCode stop() override
implementation of IService::stop
bool m_useSecondaryEventNumber
read event number from secondary input
bool m_requireInputAttributeList
require input attribute list
StatusCode submitEvent(EventContext &ctx)
Submit a recorded context; the scheduler receives its own copy.
SmartIF< IProperty > m_appMgrProperty
Property interface of ApplicationMgr.
StoreGateSvc_t m_eventStore
Reference to StoreGateSvc;.
StringProperty m_histPersName
EvtContext * m_evtContext
Gaudi event selector Context (may be used as a cursor by the evt selector).
virtual StatusCode seek(int evt) override
Seek to a given event.
int declareEventRootAddress(EventContext &)
Declare the root address of the event.
AthenaHiveEventLoopMgr()=delete
virtual StatusCode finalize() override
implementation of IAppMgrUI::finalize
virtual StatusCode executeEvent(EventContext &&ctx) override
implementation of IEventProcessor::executeEvent(void* par)
IDataManagerSvc_t m_histoDataMgrSvc
Reference to the Histogram Data Service.
EventContext m_lastEventContext
bool m_scheduledStop
Scheduled stop of event processing.
virtual EventContext createEventContext() override
Create event context.
StatusCode initializeAlgorithms()
Initialize all algorithms and output streams.
virtual ~AthenaHiveEventLoopMgr()
Standard Destructor.
virtual bool clearStoreOnEndAlgorithms() const
Batch jobs clear in the algorithm context; external drivers can retain the store until eventFinished(...
StatusCode clearWBSlot(int evtSlot)
Clear a slot in the WB.
ServiceHandle< Athena::IConditionsCleanerSvc > m_conditionsCleaner
tool_store m_tools
internal tool store
StatusCode finishEvent(const EventContext &ctx)
Finish one scheduler-returned event on the driving thread.
virtual void modifyEventContext(EventContext &ctx, const EventID &eID, bool consume_modifier_stream)
virtual StatusCode writeHistograms(bool force=false)
Dump out histograms as needed.
void setupPreSelectTools(Gaudi::Details::PropertyBase &)
property update handler:sets up the Pre-selection tools
SmartIF< IScheduler > m_schedulerSvc
A shortcut for the scheduler.
virtual int curEvent() const override
Return the current event count.
tool_stats m_toolReject
tool returns StatusCode::FAILURE counter
IEvtIdModifierSvc_t m_evtIdModSvc
SmartIF< IAlgResourcePool > m_algResourcePool
Reference to the Algorithm resource pool.
virtual StatusCode nextEvent(int maxevt) override
implementation of IAppMgrUI::nextEvent. maxevt==0 returns immediately
virtual StatusCode executeAlgorithms()
Run the algorithms for the current event.
unsigned int m_timeStampInt
void resetTimeout(Timeout &instance)
Reset timeout.
static Timeout & instance()
Get reference to Timeout singleton.
void setConditionsRun(EventIDBase::number_type conditionsRun)
This class provides a unique identification for each event, in terms of run/event number and/or a tim...
This class provides general information about an event.
EventID * event_ID()
the unique identification of the event.
Abstract interface for seeking for an event selector.
virtual StatusCode seek(IEvtSelector::Context &c, int evtnum) const =0
Seek to a given event number.
virtual int size(IEvtSelector::Context &c) const =0
Return the size of the collection, or -1 if we can't get the size.
uint32_t runNumber() const
The current event's run number.
int ir
counter of the current depth
void setExtendedEventContext(EventContext &ctx, ExtendedEventContext &&ectx)
Move an extended context into a context object.
const ExtendedEventContext & getExtendedEventContext(const EventContext &ctx)
Retrieve an extended context from a context object.
event_number_t eventIndex
EventInfo_v1 EventInfo
Definition of the latest event info version.