CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
EventStreamHandler.cc
Go to the documentation of this file.
1 // $Id: EventStreamHandler.cc,v 1.11 2012/04/20 10:48:02 mommsen Exp $
3 
8 
9 
10 namespace stor {
11 
13  (
14  const EventStreamConfigurationInfo& streamConfig,
15  const SharedResourcesPtr sharedResources,
16  const DbFileHandlerPtr dbFileHandler
17  ):
18  StreamHandler(sharedResources, dbFileHandler),
19  streamConfig_(streamConfig),
20  initMsgCollection_(sharedResources->initMsgCollection_)
21  {
22  streamRecord_->streamName = streamLabel();
23  streamRecord_->outputModuleLabel = streamConfig_.outputModuleLabel();
24  streamRecord_->fractionToDisk = fractionToDisk();
25  }
26 
27 
30  {
31  // the INIT message is not available when the EventStreamHandler is
32  // constructed, so we need to fetch it when we first need a new file
33  // handler (when the first event is received, which is after the
34  // INIT messages have been received)
35  if (initMsgView_.get() == 0)
36  {
37  initMsgView_ = initMsgCollection_->getElementForOutputModuleId( event.outputModuleId() );
38  }
39 
41 
44  );
45  fileHandlers_.push_back(newFileHandler);
46 
47  return newFileHandler;
48  }
49 
50 } // namespace stor
51 
InitMsgCollectionPtr initMsgCollection_
boost::shared_ptr< SharedResources > SharedResourcesPtr
const DbFileHandlerPtr dbFileHandler_
boost::shared_ptr< FileRecord > FileRecordPtr
virtual FileHandlerPtr newFileHandler(const I2OChain &event)
unsigned long long getMaxFileSize() const
boost::shared_ptr< DbFileHandler > DbFileHandlerPtr
Definition: DbFileHandler.h:71
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
FilesMonitorCollection::FileRecordPtr getNewFileRecord(const I2OChain &event)
FileHandlers fileHandlers_
boost::shared_ptr< FileHandler > FileHandlerPtr
Definition: StreamHandler.h:67
InitMsgSharedPtr initMsgView_
EventStreamHandler(const EventStreamConfigurationInfo &, const SharedResourcesPtr, const DbFileHandlerPtr)
uint32_t outputModuleId() const
Definition: I2OChain.cc:505