1 #ifndef FWCore_Framework_EventProcessor_h
2 #define FWCore_Framework_EventProcessor_h
32 #include "boost/thread/condition.hpp"
42 namespace statemachine {
49 class ExceptionToActionTable;
50 class BranchIDListHelper;
51 class ThinnedAssociationsHelper;
53 class HistoryAppender;
56 namespace eventsetup {
58 class EventSetupsController;
72 std::vector<std::string>
const& defaultServices = std::vector<std::string>(),
73 std::vector<std::string>
const& forcedServices = std::vector<std::string>());
78 std::vector<std::string>
const& defaultServices,
79 std::vector<std::string>
const& forcedServices = std::vector<std::string>());
117 std::vector<ModuleDescription const*>
225 void init(std::shared_ptr<ProcessDesc>& processDesc,
242 std::atomic<bool>* finishedProcessingEvents);
246 void readEvent(
unsigned int iStreamIndex);
std::string emptyRunLumiMode_
unsigned int numberOfSequentialEventsPerChild_
void readEvent(unsigned int iStreamIndex)
ProcessContext processContext_
void init(std::shared_ptr< ProcessDesc > &processDesc, ServiceToken const &token, serviceregistry::ServiceLegacy)
edm::propagate_const< std::unique_ptr< std::vector< SubProcess > > > subProcesses_
virtual void closeOutputFiles()
edm::propagate_const< std::unique_ptr< InputSource > > input_
std::unique_ptr< ExceptionToActionTable const > act_table_
static boost::mutex mutex
bool stateMachineWasInErrorState_
virtual void beginLumi(ProcessHistoryID const &phid, RunNumber_t run, LuminosityBlockNumber_t lumi)
bool alreadyHandlingException_
virtual void setExceptionMessageFiles(std::string &message)
void possiblyContinueAfterForkChildFailure()
ProcessConfiguration const & processConfiguration() const
virtual statemachine::Run readRun()
virtual void writeLumi(ProcessHistoryID const &phid, RunNumber_t run, LuminosityBlockNumber_t lumi)
edm::propagate_const< std::unique_ptr< HistoryAppender > > historyAppender_
void clearCounters()
Clears counters used by trigger report.
int numberOfForkedChildren_
std::shared_ptr< BranchIDListHelper const > branchIDListHelper() const
bool checkForAsyncStopRequest(StatusCode &)
edm::propagate_const< std::shared_ptr< ProductRegistry > > preg_
virtual void deleteRunFromCache(statemachine::Run const &run)
virtual void rewindInput()
std::set< std::pair< std::string, std::string > > ExcludedData
std::auto_ptr< statemachine::Machine > createStateMachine()
std::string exceptionMessageRuns_
PreallocationConfiguration preallocations_
unsigned int LuminosityBlockNumber_t
EventProcessor(std::string const &config, ServiceToken const &token=ServiceToken(), serviceregistry::ServiceLegacy=serviceregistry::kOverlapIsError, std::vector< std::string > const &defaultServices=std::vector< std::string >(), std::vector< std::string > const &forcedServices=std::vector< std::string >())
bool forkProcess(std::string const &jobReportFile)
virtual void beginRun(statemachine::Run const &run)
bool continueAfterChildFailure_
void terminateMachine(std::auto_ptr< statemachine::Machine > &)
ServiceToken serviceToken_
bool endPathsEnabled() const
std::atomic< bool > deferredExceptionPtrIsSet_
virtual bool alreadyHandlingException() const
std::shared_ptr< ThinnedAssociationsHelper const > thinnedAssociationsHelper() const
std::string exceptionMessageLumis_
std::shared_ptr< ProductRegistry const > preg() const
virtual void setExceptionMessageLumis(std::string &message)
virtual void setExceptionMessageRuns(std::string &message)
ExcludedDataMap eventSetupDataToExcludeFromPrefetching_
InputSource::ItemType nextItemTypeFromProcessingEvents_
edm::propagate_const< std::shared_ptr< EDLooperBase > > looper_
virtual void readAndProcessEvent()
void processEvent(unsigned int iStreamIndex)
virtual StatusCode runToCompletion()
EventProcessor & operator=(EventProcessor const &)=delete
edm::propagate_const< std::unique_ptr< Schedule > > schedule_
std::shared_ptr< T > & get_underlying_safe(propagate_const< std::shared_ptr< T >> &iP)
std::shared_ptr< ProcessConfiguration const > processConfiguration_
bool hasSubProcesses() const
std::string exceptionMessageFiles_
virtual statemachine::Run readAndMergeRun()
std::shared_ptr< BranchIDListHelper > & branchIDListHelper()
virtual int readLuminosityBlock()
std::shared_ptr< EDLooperBase > & looper()
virtual void respondToCloseInputFile()
virtual void writeRun(statemachine::Run const &run)
StatusCode asyncStopStatusCodeFromProcessingEvents_
virtual void respondToOpenInputFile()
virtual bool shouldWeCloseOutput() const
virtual void doErrorStuff()
edm::propagate_const< std::unique_ptr< FileBlock > > fb_
virtual void endLumi(ProcessHistoryID const &phid, RunNumber_t run, LuminosityBlockNumber_t lumi, bool cleaningUpAfterException)
std::map< std::string, ExcludedData > ExcludedDataMap
edm::propagate_const< std::unique_ptr< eventsetup::EventSetupsController > > espController_
virtual void openOutputFiles()
bool forceESCacheClearOnNewRun_
edm::propagate_const< std::shared_ptr< ThinnedAssociationsHelper > > thinnedAssociationsHelper_
std::shared_ptr< ProductRegistry > & preg()
edm::propagate_const< std::shared_ptr< eventsetup::EventSetupProvider > > esp_
virtual void deleteLumiFromCache(ProcessHistoryID const &phid, RunNumber_t run, LuminosityBlockNumber_t lumi)
virtual void closeInputFile(bool cleaningUpAfterException)
std::exception_ptr deferredExceptionPtr_
int totalEventsFailed() const
PathsAndConsumesOfModules pathsAndConsumesOfModules_
virtual void prepareForNextLoop()
virtual void endRun(statemachine::Run const &run, bool cleaningUpAfterException)
virtual void startingNewLoop()
bool asyncStopRequestedWhileProcessingEvents_
std::shared_ptr< ActivityRegistry > actReg_
std::mutex nextTransitionMutex_
void processEventsForStreamAsync(unsigned int iStreamIndex, std::atomic< bool > *finishedProcessingEvents)
std::vector< ModuleDescription const * > getAllModuleDescriptions() const
int totalEventsPassed() const
edm::propagate_const< std::shared_ptr< BranchIDListHelper > > branchIDListHelper_
virtual int readAndMergeLumi()
std::shared_ptr< ThinnedAssociationsHelper > & thinnedAssociationsHelper()
std::shared_ptr< EDLooperBase const > looper() const
PrincipalCache principalCache_
virtual bool shouldWeStop() const
void enableEndPaths(bool active)
void getTriggerReport(TriggerReport &rep) const