CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
edm::SecondaryEventProvider Class Reference

#include <SecondaryEventProvider.h>

Public Member Functions

void beginJob (ProductRegistry const &iRegistry, eventsetup::ESRecordsToProxyIndices const &)
 
void beginLuminosityBlock (LuminosityBlockPrincipal &lumi, const edm::EventSetupImpl &setup, ModuleCallingContext const *, StreamContext &sContext)
 
void beginRun (RunPrincipal &run, const edm::EventSetupImpl &setup, ModuleCallingContext const *, StreamContext &sContext)
 
void beginStream (edm::StreamID iID, StreamContext &sContext)
 
void endJob ()
 
void endLuminosityBlock (LuminosityBlockPrincipal &lumi, const edm::EventSetupImpl &setup, ModuleCallingContext const *, StreamContext &sContext)
 
void endRun (RunPrincipal &run, const edm::EventSetupImpl &setup, ModuleCallingContext const *, StreamContext &sContext)
 
void endStream (edm::StreamID iID, StreamContext &sContext)
 
 SecondaryEventProvider (std::vector< ParameterSet > &psets, ProductRegistry &pregistry, std::shared_ptr< ProcessConfiguration > processConfiguration)
 
void setupPileUpEvent (EventPrincipal &ep, const EventSetupImpl &setup, StreamContext &sContext)
 

Private Attributes

std::unique_ptr< ExceptionToActionTableexceptionToActionTable_
 
WorkerManager workerManager_
 

Detailed Description

Definition at line 14 of file SecondaryEventProvider.h.

Constructor & Destructor Documentation

◆ SecondaryEventProvider()

edm::SecondaryEventProvider::SecondaryEventProvider ( std::vector< ParameterSet > &  psets,
ProductRegistry pregistry,
std::shared_ptr< ProcessConfiguration processConfiguration 
)

Definition at line 9 of file SecondaryEventProvider.cc.

12  : exceptionToActionTable_(new ExceptionToActionTable),
13  workerManager_(std::make_shared<ActivityRegistry>(), *exceptionToActionTable_) {
14  std::vector<std::string> shouldBeUsedLabels;
15  std::set<std::string> unscheduledLabels;
16  const PreallocationConfiguration preallocConfig;
17  for (auto& pset : psets) {
18  std::string label = pset.getParameter<std::string>("@module_label");
20  pset, preg, &preallocConfig, processConfiguration, label, unscheduledLabels, shouldBeUsedLabels);
21  }
22  if (!unscheduledLabels.empty()) {
23  preg.setUnscheduledProducts(unscheduledLabels);
24  }
25  } // SecondaryEventProvider::SecondaryEventProvider

References edm::WorkerManager::addToUnscheduledWorkers(), label, muonDTDigis_cfi::pset, edm::ProductRegistry::setUnscheduledProducts(), AlCaHLTBitMon_QueryRunRegistry::string, and workerManager_.

Member Function Documentation

◆ beginJob()

void edm::SecondaryEventProvider::beginJob ( ProductRegistry const &  iRegistry,
eventsetup::ESRecordsToProxyIndices const &  iIndices 
)

Definition at line 27 of file SecondaryEventProvider.cc.

28  {
29  workerManager_.beginJob(iRegistry, iIndices);
30  }

References edm::WorkerManager::beginJob(), and workerManager_.

◆ beginLuminosityBlock()

void edm::SecondaryEventProvider::beginLuminosityBlock ( LuminosityBlockPrincipal lumi,
const edm::EventSetupImpl setup,
ModuleCallingContext const *  mcc,
StreamContext sContext 
)

Definition at line 44 of file SecondaryEventProvider.cc.

47  {
48  workerManager_.processOneOccurrence<OccurrenceTraits<LuminosityBlockPrincipal, BranchActionGlobalBegin> >(
49  lumi, setup, StreamID::invalidStreamID(), nullptr, mcc);
50  workerManager_.processOneOccurrence<OccurrenceTraits<LuminosityBlockPrincipal, BranchActionStreamBegin> >(
51  lumi, setup, sContext.streamID(), &sContext, mcc);
52  }

References edm::StreamID::invalidStreamID(), BXlumiParameters_cfi::lumi, edm::WorkerManager::processOneOccurrence(), singleTopDQM_cfi::setup, edm::StreamContext::streamID(), and workerManager_.

◆ beginRun()

void edm::SecondaryEventProvider::beginRun ( RunPrincipal run,
const edm::EventSetupImpl setup,
ModuleCallingContext const *  mcc,
StreamContext sContext 
)

Definition at line 34 of file SecondaryEventProvider.cc.

37  {
38  workerManager_.processOneOccurrence<OccurrenceTraits<RunPrincipal, BranchActionGlobalBegin> >(
39  run, setup, StreamID::invalidStreamID(), nullptr, mcc);
40  workerManager_.processOneOccurrence<OccurrenceTraits<RunPrincipal, BranchActionStreamBegin> >(
41  run, setup, sContext.streamID(), &sContext, mcc);
42  }

References edm::StreamID::invalidStreamID(), edm::WorkerManager::processOneOccurrence(), writedatasetfile::run, singleTopDQM_cfi::setup, edm::StreamContext::streamID(), and workerManager_.

◆ beginStream()

void edm::SecondaryEventProvider::beginStream ( edm::StreamID  iID,
StreamContext sContext 
)

Definition at line 79 of file SecondaryEventProvider.cc.

79  {
80  workerManager_.beginStream(iID, sContext);
81  }

References edm::WorkerManager::beginStream(), and workerManager_.

◆ endJob()

void edm::SecondaryEventProvider::endJob ( void  )
inline

Definition at line 41 of file SecondaryEventProvider.h.

References edm::WorkerManager::endJob(), and workerManager_.

◆ endLuminosityBlock()

void edm::SecondaryEventProvider::endLuminosityBlock ( LuminosityBlockPrincipal lumi,
const edm::EventSetupImpl setup,
ModuleCallingContext const *  mcc,
StreamContext sContext 
)

Definition at line 64 of file SecondaryEventProvider.cc.

67  {
68  workerManager_.processOneOccurrence<OccurrenceTraits<LuminosityBlockPrincipal, BranchActionStreamEnd> >(
69  lumi, setup, sContext.streamID(), &sContext, mcc);
70  workerManager_.processOneOccurrence<OccurrenceTraits<LuminosityBlockPrincipal, BranchActionGlobalEnd> >(
71  lumi, setup, StreamID::invalidStreamID(), nullptr, mcc);
72  }

References edm::StreamID::invalidStreamID(), BXlumiParameters_cfi::lumi, edm::WorkerManager::processOneOccurrence(), singleTopDQM_cfi::setup, edm::StreamContext::streamID(), and workerManager_.

◆ endRun()

void edm::SecondaryEventProvider::endRun ( RunPrincipal run,
const edm::EventSetupImpl setup,
ModuleCallingContext const *  mcc,
StreamContext sContext 
)

Definition at line 54 of file SecondaryEventProvider.cc.

57  {
58  workerManager_.processOneOccurrence<OccurrenceTraits<RunPrincipal, BranchActionStreamEnd> >(
59  run, setup, sContext.streamID(), &sContext, mcc);
60  workerManager_.processOneOccurrence<OccurrenceTraits<RunPrincipal, BranchActionGlobalEnd> >(
61  run, setup, StreamID::invalidStreamID(), nullptr, mcc);
62  }

References edm::StreamID::invalidStreamID(), edm::WorkerManager::processOneOccurrence(), writedatasetfile::run, singleTopDQM_cfi::setup, edm::StreamContext::streamID(), and workerManager_.

◆ endStream()

void edm::SecondaryEventProvider::endStream ( edm::StreamID  iID,
StreamContext sContext 
)

Definition at line 83 of file SecondaryEventProvider.cc.

83  {
84  workerManager_.endStream(iID, sContext);
85  }

References edm::WorkerManager::endStream(), and workerManager_.

◆ setupPileUpEvent()

void edm::SecondaryEventProvider::setupPileUpEvent ( EventPrincipal ep,
const EventSetupImpl setup,
StreamContext sContext 
)

Member Data Documentation

◆ exceptionToActionTable_

std::unique_ptr<ExceptionToActionTable> edm::SecondaryEventProvider::exceptionToActionTable_
private

Definition at line 47 of file SecondaryEventProvider.h.

◆ workerManager_

WorkerManager edm::SecondaryEventProvider::workerManager_
private
edm::WorkerManager::addToUnscheduledWorkers
void addToUnscheduledWorkers(ParameterSet &pset, ProductRegistry &preg, PreallocationConfiguration const *prealloc, std::shared_ptr< ProcessConfiguration > processConfiguration, std::string label, std::set< std::string > &unscheduledLabels, std::vector< std::string > &shouldBeUsedLabels)
Definition: WorkerManager.cc:42
edm::SecondaryEventProvider::exceptionToActionTable_
std::unique_ptr< ExceptionToActionTable > exceptionToActionTable_
Definition: SecondaryEventProvider.h:47
singleTopDQM_cfi.setup
setup
Definition: singleTopDQM_cfi.py:37
BXlumiParameters_cfi.lumi
lumi
Definition: BXlumiParameters_cfi.py:6
edm::WorkerManager::beginJob
void beginJob(ProductRegistry const &iRegistry, eventsetup::ESRecordsToProxyIndices const &)
Definition: WorkerManager.cc:81
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
edm::WorkerManager::beginStream
void beginStream(StreamID iID, StreamContext &streamContext)
Definition: WorkerManager.cc:105
edm::StreamID::invalidStreamID
static StreamID invalidStreamID()
Definition: StreamID.h:44
edm::WorkerManager::processOneOccurrence
void processOneOccurrence(typename T::MyPrincipal &principal, EventSetupImpl const &eventSetup, StreamID streamID, typename T::Context const *topContext, U const *context, bool cleaningUpAfterException=false)
Definition: WorkerManager.h:108
edm::SecondaryEventProvider::workerManager_
WorkerManager workerManager_
Definition: SecondaryEventProvider.h:48
writedatasetfile.run
run
Definition: writedatasetfile.py:27
edm::WorkerManager::setupOnDemandSystem
void setupOnDemandSystem(Principal &principal, EventSetupImpl const &es)
Definition: WorkerManager.cc:125
edm::WorkerManager::endStream
void endStream(StreamID iID, StreamContext &streamContext)
Definition: WorkerManager.cc:111
SiStripBadComponentsDQMServiceTemplate_cfg.ep
ep
Definition: SiStripBadComponentsDQMServiceTemplate_cfg.py:86
label
const char * label
Definition: PFTauDecayModeTools.cc:11
muonDTDigis_cfi.pset
pset
Definition: muonDTDigis_cfi.py:27
edm::WorkerManager::endJob
void endJob()
Definition: WorkerManager.cc:65