CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Classes | Public Types | Public Member Functions | Protected Member Functions | Private Attributes
edm::JobReport Class Reference

#include <JobReport.h>

Inheritance diagram for edm::JobReport:
edm::service::JobReportService

Classes

struct  InputFile
 
struct  JobReportImpl
 
struct  LumiSectionReport
 
struct  OutputFile
 
struct  RunReport
 

Public Types

typedef unsigned int RunNumber
 
typedef std::size_t Token
 

Public Member Functions

void childAfterFork (std::string const &jobReportFile, unsigned int childIndex, unsigned int numberOfChildren)
 New output file for child. More...
 
std::string dumpFiles (void)
 debug/test util More...
 
void eventReadFromFile (Token fileToken, unsigned int run, unsigned int event)
 
void eventWrittenToFile (Token fileToken, unsigned int run, unsigned int event)
 
void inputFileClosed (Token fileToken)
 
Token inputFileOpened (std::string const &physicalFileName, std::string const &logicalFileName, std::string const &catalog, std::string const &inputType, std::string const &inputSourceClassName, std::string const &moduleLabel, std::string const &guid, std::vector< std::string > const &branchNames)
 
 JobReport ()
 
 JobReport (std::ostream *outputStream)
 
void outputFileClosed (Token fileToken)
 
Token outputFileOpened (std::string const &physicalFileName, std::string const &logicalFileName, std::string const &catalog, std::string const &outputModuleClassName, std::string const &moduleLabel, std::string const &guid, std::string const &dataType, std::string const &branchHash, std::vector< std::string > const &branchNames)
 
void overrideContributingInputs (Token outputToken, std::vector< Token > const &inputTokens)
 
void overrideEventsRead (Token fileToken, int const eventsRead)
 
void overrideEventsWritten (Token fileToken, int const eventsWritten)
 
void parentAfterFork (std::string const &jobReportFile)
 
void parentBeforeFork (std::string const &jobReportFile, unsigned int numberOfChildren)
 
void reportAnalysisFile (std::string const &fileName, std::map< std::string, std::string > const &fileData)
 
void reportDataType (Token fileToken, std::string const &dataType)
 
void reportError (std::string const &shortDesc, std::string const &longDesc)
 
void reportError (std::string const &shortDesc, std::string const &longDesc, int const &exitCode)
 
void reportFallbackAttempt (std::string const &pfn, std::string const &lfn, std::string const &err)
 
void reportFastClonedBranches (std::set< std::string > const &fastClonedBranches, long long nEvents)
 Inform the job report that branches have been fast Cloned. More...
 
void reportFastCopyingStatus (Token t, std::string const &inputFileName, bool fastCopying)
 
void reportGeneratorInfo (std::string const &name, std::string const &value)
 
void reportInputLumiSection (unsigned int run, unsigned int lumiSectId)
 
void reportInputRunNumber (unsigned int run)
 
void reportLumiSection (unsigned int run, unsigned int lumiSectId)
 
void reportMemoryInfo (std::vector< std::string > const &memoryData)
 
void reportMessageInfo (std::map< std::string, double > const &messageData)
 
void reportPerformanceForModule (std::string const &metricClass, std::string const &moduleName, std::map< std::string, std::string > const &metrics)
 
void reportPerformanceSummary (std::string const &metricClass, std::map< std::string, std::string > const &metrics)
 
void reportPSetHash (std::string const &hashValue)
 
void reportRandomStateFile (std::string const &name)
 
void reportReadBranch (std::string const &branchName)
 Inform the job report that a branch has been read. More...
 
void reportReadBranches ()
 
void reportRunNumber (unsigned int run)
 
void reportSkippedEvent (unsigned int run, unsigned int event)
 
void reportSkippedFile (std::string const &pfn, std::string const &lfn)
 
 ~JobReport ()
 

Protected Member Functions

boost::scoped_ptr
< JobReportImpl > & 
impl ()
 

Private Attributes

boost::scoped_ptr< JobReportImplimpl_
 

Detailed Description

Definition at line 40 of file JobReport.h.

Member Typedef Documentation

typedef unsigned int edm::JobReport::RunNumber

Definition at line 42 of file JobReport.h.

typedef std::size_t edm::JobReport::Token

Definition at line 43 of file JobReport.h.

Constructor & Destructor Documentation

JobReport::JobReport ( )

Definition at line 435 of file JobReport.cc.

435  :
436  impl_(new JobReportImpl(0)) {
437  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
JobReport::JobReport ( std::ostream *  outputStream)

Definition at line 439 of file JobReport.cc.

References impl_.

439  : impl_(new JobReportImpl(iOstream)) {
440  if(impl_->ost_) {
441  *(impl_->ost_) << "<FrameworkJobReport>\n";
442  }
443  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
JobReport::~JobReport ( )

Definition at line 427 of file JobReport.cc.

References impl_.

427  {
428  impl_->writeGeneratorInfo();
429  impl_->flushFiles();
430  if(impl_->ost_) {
431  *(impl_->ost_) << "</FrameworkJobReport>\n" << std::flush;
432  }
433  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434

Member Function Documentation

void JobReport::childAfterFork ( std::string const &  jobReportFile,
unsigned int  childIndex,
unsigned int  numberOfChildren 
)

New output file for child.

Definition at line 492 of file JobReport.cc.

References impl_, and AlCaHLTBitMon_ParallelJobs::p.

492  {
493  std::ofstream* p = dynamic_cast<std::ofstream*>(impl_->ost_);
494  if(!p) return;
495  std::ostringstream ofilename;
496  toFileName(jobReportFile, childIndex, numberOfChildren, ofilename);
497  p->open(ofilename.str().c_str());
498  *p << "<FrameworkJobReport>\n";
499  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
std::string JobReport::dumpFiles ( void  )

debug/test util

Definition at line 888 of file JobReport.cc.

References f, edm::findOrDefault(), impl_, edm::JobReport::InputFile::logicalFileName, lumiQueryAPI::msg, and edm::JobReport::InputFile::physicalFileName.

888  {
889  std::ostringstream msg;
890 
891  typedef std::vector<JobReport::OutputFile>::iterator iterator;
892 
893  for(iterator f = impl_->outputFiles_.begin(), fEnd = impl_->outputFiles_.end(); f != fEnd; ++f) {
894 
895  msg << "\n<File>";
896  msg << *f;
897 
898  msg << "\n<LumiSections>";
899  //typedef std::vector<JobReport::LumiSectionReport>::iterator Iter;
900  //for(Iter iLumi = f->lumiSections.begin(),
901  // iLumiEnd = f->lumiSections.end();
902  // iLumi != iLumiEnd; ++iLumi) {
903  // msg << *iLumi;
904  //}
905  //msg << "\n</LumiSections>\n";
906  msg << "\n<Inputs>";
907  typedef std::vector<JobReport::Token>::iterator iterator;
908  for(iterator iInput = f->contributingInputs.begin(),
909  iInputEnd = f->contributingInputs.end();
910  iInput != iInputEnd; ++iInput) {
911  JobReport::InputFile inpFile = impl_->inputFiles_[*iInput];
912  msg << "\n<Input>";
913  msg << "\n <LFN>" << TiXmlText(inpFile.logicalFileName) << "</LFN>";
914  msg << "\n <PFN>" << TiXmlText(inpFile.physicalFileName) << "</PFN>";
915  msg << "\n <FastCopying>" << findOrDefault(f->fastCopyingInputs, inpFile.physicalFileName) << "</FastCopying>";
916  msg << "\n</Input>";
917  }
918  msg << "\n</Inputs>";
919  msg << "\n</File>";
920 
921  }
922  return msg.str();
923  }
tuple InputFile
Open Root file and provide MEs ############.
double f[11][100]
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
Value const & findOrDefault(std::map< Key, Value > const &m, Key const &k, Value const &defaultValue)
Definition: Map.h:28
void JobReport::eventReadFromFile ( JobReport::Token  fileToken,
unsigned int  run,
unsigned int  event 
)

Report that the event with the given id has been read from the file identified by the given Token.

Definition at line 537 of file JobReport.cc.

References f, impl_, and edm::JobReport::InputFile::numEventsRead.

537  {
538  JobReport::InputFile& f = impl_->getInputFileForToken(fileToken);
539  ++f.numEventsRead;
540  //f.runsSeen.insert(run);
541  }
tuple InputFile
Open Root file and provide MEs ############.
double f[11][100]
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::eventWrittenToFile ( JobReport::Token  fileToken,
unsigned int  run,
unsigned int  event 
)

Report that the event with the given id has been written to the file identified by the given Token.

Definition at line 593 of file JobReport.cc.

References f, impl_, and edm::JobReport::OutputFile::numEventsWritten.

593  {
594  JobReport::OutputFile& f = impl_->getOutputFileForToken(fileToken);
595  ++f.numEventsWritten;
596  //f.runsSeen.insert(run);
597  }
double f[11][100]
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
boost::scoped_ptr<JobReportImpl>& edm::JobReport::impl ( )
inlineprotected

Definition at line 431 of file JobReport.h.

References impl_.

Referenced by edm::service::JobReportService::frameworkShutdownOnFailure(), and edm::service::JobReportService::postEndJob().

431 {return impl_;}
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::inputFileClosed ( JobReport::Token  fileToken)

Report that the input file identified by the given Token has been closed. An exception will be thrown if the given Token was not obtained from inputFileOpened.

Definition at line 550 of file JobReport.cc.

References f, edm::JobReport::InputFile::fileHasBeenClosed, and impl_.

Referenced by DQMRootSource::closeFile_().

550  {
551  JobReport::InputFile& f = impl_->getInputFileForToken(fileToken);
552  // Dump information to the MessageLogger's JobSummary
553  // about this file.
554  // After setting the file to 'closed', we will no longer be able
555  // to reference it by ID.
556  f.fileHasBeenClosed = true;
557  impl_->writeInputFile(f);
558  }
tuple InputFile
Open Root file and provide MEs ############.
double f[11][100]
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
JobReport::Token JobReport::inputFileOpened ( std::string const &  physicalFileName,
std::string const &  logicalFileName,
std::string const &  catalog,
std::string const &  inputType,
std::string const &  inputSourceClassName,
std::string const &  moduleLabel,
std::string const &  guid,
std::vector< std::string > const &  branchNames 
)

Report that an input file has been opened. The returned Token should be used for later identification of this file.

Definition at line 502 of file JobReport.cc.

References edm::JobReport::InputFile::branchNames, validate_alignment_devdb10_cfg::catalog, edm::JobReport::InputFile::catalog, edm::JobReport::InputFile::fastClonedBranches, edm::JobReport::InputFile::fileHasBeenClosed, edm::JobReport::InputFile::guid, impl_, edm::JobReport::InputFile::inputSourceClassName, edm::JobReport::InputFile::inputType, edm::JobReport::InputFile::logicalFileName, edm::JobReport::InputFile::moduleLabel, edm::JobReport::InputFile::numEventsRead, edm::JobReport::InputFile::physicalFileName, and alignCSCRings::r.

Referenced by DQMRootSource::readFile_().

509  {
510  // Do we have to worry about thread safety here? Or is this
511  // service used in a way to make this safe?
512  impl_->inputFiles_.push_back(JobReport::InputFile());
513  JobReport::InputFile& r = impl_->inputFiles_.back();
514  impl_->fastClonedBranches_ = &r.fastClonedBranches;
515 
516  r.logicalFileName = logicalFileName;
517  r.physicalFileName = physicalFileName;
518  r.catalog = catalog;
519  r.inputType = inputType;
520  r.inputSourceClassName = inputSourceClassName;
521  r.moduleLabel = moduleLabel;
522  r.guid = guid;
523  // r.runsSeen is not modified
524  r.numEventsRead = 0;
525  r.branchNames = branchNames;
526  r.fileHasBeenClosed = false;
527 
528  JobReport::Token newToken = impl_->inputFiles_.size()-1;
529  //
530  // Add the new input file token to all output files
531  // currently open.
532  impl_->insertInputForOutputs(newToken);
533  return newToken;
534  }
tuple InputFile
Open Root file and provide MEs ############.
std::size_t Token
Definition: JobReport.h:43
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::outputFileClosed ( JobReport::Token  fileToken)

Report that the output file identified by the given Token has been closed. An exception will be thrown if the given Token was not obtained from outputFileOpened.

Definition at line 600 of file JobReport.cc.

References f, edm::JobReport::OutputFile::fileHasBeenClosed, and impl_.

Referenced by DQMRootOutputModule::finishEndFile().

600  {
601  JobReport::OutputFile& f = impl_->getOutputFileForToken(fileToken);
602  // Dump information to the MessageLogger's JobSummary
603  // about this file.
604  // After setting the file to 'closed', we will no longer be able
605  // to reference it by ID.
606  f.fileHasBeenClosed = true;
607  impl_->writeOutputFile(f);
608  }
double f[11][100]
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
JobReport::Token JobReport::outputFileOpened ( std::string const &  physicalFileName,
std::string const &  logicalFileName,
std::string const &  catalog,
std::string const &  outputModuleClassName,
std::string const &  moduleLabel,
std::string const &  guid,
std::string const &  dataType,
std::string const &  branchHash,
std::vector< std::string > const &  branchNames 
)

Report that an output file has been opened. The returned Token should be used for later identification of this file.

Definition at line 561 of file JobReport.cc.

References edm::JobReport::OutputFile::branchHash, edm::JobReport::OutputFile::branchNames, validate_alignment_devdb10_cfg::catalog, edm::JobReport::OutputFile::catalog, edm::JobReport::OutputFile::contributingInputs, dtTPAnalyzer_cfg::dataType, edm::JobReport::OutputFile::dataType, edm::JobReport::OutputFile::fileHasBeenClosed, edm::JobReport::OutputFile::guid, impl_, edm::JobReport::OutputFile::logicalFileName, edm::JobReport::OutputFile::moduleLabel, edm::JobReport::OutputFile::numEventsWritten, edm::JobReport::OutputFile::outputModuleClassName, edm::JobReport::OutputFile::physicalFileName, and alignCSCRings::r.

Referenced by DQMRootOutputModule::openFile().

569  {
570  impl_->outputFiles_.push_back(JobReport::OutputFile());
571  JobReport::OutputFile& r = impl_->outputFiles_.back();
572 
573  r.logicalFileName = logicalFileName;
574  r.physicalFileName = physicalFileName;
575  r.catalog = catalog;
576  r.outputModuleClassName = outputModuleClassName;
577  r.moduleLabel = moduleLabel;
578  r.guid = guid;
579  r.dataType = dataType;
580  r.branchHash = branchHash;
581  // r.runsSeen is not modified
582  r.numEventsWritten = 0;
583  r.branchNames = branchNames;
584  r.fileHasBeenClosed = false;
585  //
586  // Init list of contributors to list of open input file Tokens
587  //
588  impl_->openInputFiles(r.contributingInputs);
589  return impl_->outputFiles_.size()-1;
590  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::overrideContributingInputs ( Token  outputToken,
std::vector< Token > const &  inputTokens 
)

Override the list of input files seen by an output file for use with EdmFastMerge

Definition at line 633 of file JobReport.cc.

References edm::JobReport::OutputFile::contributingInputs, f, and impl_.

634  {
635  // Get the required output file instance using the token
636  JobReport::OutputFile& f = impl_->getOutputFileForToken(outputToken);
637  // override its contributing inputs data
638  f.contributingInputs = inputTokens;
639  }
double f[11][100]
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::overrideEventsRead ( Token  fileToken,
int const  eventsRead 
)

For use by fast merge: Since the event by event counter cant be used for fast merges, use this method to forcibly set the events read count for an input file before reporting it closed

Definition at line 625 of file JobReport.cc.

References f, impl_, and edm::JobReport::InputFile::numEventsRead.

625  {
626  // Get the required input file instance using the token
627  JobReport::InputFile& f = impl_->getInputFileForToken(fileToken);
628  // set the events read parameter to the provided value
629  f.numEventsRead = eventsRead;
630  }
tuple InputFile
Open Root file and provide MEs ############.
double f[11][100]
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::overrideEventsWritten ( Token  fileToken,
int const  eventsWritten 
)

For use by fast merge: Since the event by event counter cant be used for fast merges, use this method to forcibly set the events written count for an output file before reporting it closed

Definition at line 617 of file JobReport.cc.

References f, impl_, and edm::JobReport::OutputFile::numEventsWritten.

617  {
618  // Get the required output file instance using the token
619  JobReport::OutputFile& f = impl_->getOutputFileForToken(fileToken);
620  // set the eventsWritten parameter to the provided value
621  f.numEventsWritten = eventsWritten;
622  }
double f[11][100]
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::parentAfterFork ( std::string const &  jobReportFile)

Definition at line 488 of file JobReport.cc.

488  {
489  }
void JobReport::parentBeforeFork ( std::string const &  jobReportFile,
unsigned int  numberOfChildren 
)

Definition at line 470 of file JobReport.cc.

References i, impl_, and AlCaHLTBitMon_ParallelJobs::p.

470  {
471  if(impl_->ost_) {
472  *(impl_->ost_) << "<ChildProcessFiles>\n";
473  for(unsigned int i = 0; i < numberOfChildren; ++i) {
474  std::ostringstream ofilename;
475  toFileName(jobReportFile, i, numberOfChildren, ofilename);
476  *(impl_->ost_) << " <ChildProcessFile>" << ofilename.str() << "</ChildProcessFile>\n";
477  }
478  *(impl_->ost_) << "</ChildProcessFiles>\n";
479  *(impl_->ost_) << "</FrameworkJobReport>\n";
480  std::ofstream* p = dynamic_cast<std::ofstream *>(impl_->ost_);
481  if(p) {
482  p->close();
483  }
484  }
485  }
int i
Definition: DBlmapReader.cc:9
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportAnalysisFile ( std::string const &  fileName,
std::map< std::string, std::string > const &  fileData 
)

Definition at line 685 of file JobReport.cc.

References impl_, lumiQueryAPI::msg, and pos.

Referenced by TFileService::afterBeginJob(), DQMStoreStats::calcstats(), PCLMetadataWriter::endRun(), and DQMFileSaver::saveJobReport().

685  {
686  if(impl_->ost_) {
687  std::ostream& msg = *(impl_->ost_);
688  //std::ostringstream msg;
689  msg << "<AnalysisFile>\n"
690  << " <FileName>" << TiXmlText(fileName) << "</FileName>\n";
691 
692  typedef std::map<std::string, std::string>::const_iterator const_iterator;
693  for(const_iterator pos = fileData.begin(), posEnd = fileData.end(); pos != posEnd; ++pos) {
694  msg << " <" << pos->first
695  << " Value=\"" << pos->second << "\" />"
696  << "\n";
697  }
698  msg << "</AnalysisFile>\n";
699  //LogError("FwkJob") << msg.str();
700  msg << std::flush;
701  }
702  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportDataType ( Token  fileToken,
std::string const &  dataType 
)

Report the data type of a file after it has been opened Needed since the data type isn't known until an event has been read

Definition at line 544 of file JobReport.cc.

References dtTPAnalyzer_cfg::dataType, edm::JobReport::OutputFile::dataType, f, and impl_.

544  {
545  JobReport::OutputFile& f = impl_->getOutputFileForToken(fileToken);
546  f.dataType = dataType;
547  }
double f[11][100]
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportError ( std::string const &  shortDesc,
std::string const &  longDesc 
)

Report an exception, providing details of the problem as a short description (Eg "XXXError") and a long description (Eg "XXX crashed because...") Also overload this method to accept an optional standard exit code

Definition at line 672 of file JobReport.cc.

References impl_, and lumiQueryAPI::msg.

Referenced by edm::printCmsException(), and edm::printCmsExceptionWarning().

673  {
674  if(impl_->ost_) {
675  std::ostream& msg = *(impl_->ost_);
676  msg << "<FrameworkError ExitStatus=\"1\" Type=\"" << shortDesc << "\" >\n";
677  msg << "<![CDATA[\n" << longDesc << "\n]]>\n";
678  msg << "</FrameworkError>\n";
679  //LogError("FwkJob") << msg.str();
680  msg << std::flush;
681  }
682  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportError ( std::string const &  shortDesc,
std::string const &  longDesc,
int const &  exitCode 
)

Definition at line 705 of file JobReport.cc.

References impl_, and lumiQueryAPI::msg.

707  {
708  if(impl_->ost_) {
709  std::ostream& msg = *(impl_->ost_);
710  //std::ostringstream msg;
711  msg << "<FrameworkError ExitStatus=\""<< exitCode
712  << "\" Type=\"" << shortDesc << "\" >\n";
713  msg << "<![CDATA[\n" << longDesc << "\n]]>\n";
714  msg << "</FrameworkError>\n";
715  //LogError("FwkJob") << msg.str();
716  msg << std::flush;
717  }
718  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportFallbackAttempt ( std::string const &  pfn,
std::string const &  lfn,
std::string const &  err 
)

Definition at line 735 of file JobReport.cc.

References impl_, lumiQueryAPI::msg, and TiXmlElement::SetAttribute().

735  {
736  if(impl_->ost_) {
737  std::ostream& msg = *(impl_->ost_);
738  TiXmlElement fallback("FallbackAttempt");
739  fallback.SetAttribute("Pfn", pfn);
740  fallback.SetAttribute("Lfn", lfn);
741  msg << fallback << "\n";
742  msg << "<![CDATA[\n" << err << "\n]]>\n";
743  msg << std::flush;
744  //LogInfo("FwkJob") << msg.str();
745  }
746  }
list pfn
Definition: dbtoconf.py:76
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportFastClonedBranches ( std::set< std::string > const &  fastClonedBranches,
long long  nEvents 
)

Inform the job report that branches have been fast Cloned.

Definition at line 806 of file JobReport.cc.

References impl_, and nEvents.

806  {
807  for(std::set<std::string>::const_iterator it = fastClonedBranches.begin(), itEnd = fastClonedBranches.end();
808  it != itEnd; ++it) {
809  if(impl_->fastClonedBranches_->insert(*it).second) {
810  impl_->readBranches_[*it] += nEvents;
811  }
812  }
813  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
UInt_t nEvents
Definition: hcalCalib.cc:43
void JobReport::reportFastCopyingStatus ( JobReport::Token  fileToken,
std::string const &  inputFileName,
bool  fastCopying 
)

Definition at line 611 of file JobReport.cc.

References f, edm::JobReport::OutputFile::fastCopyingInputs, and impl_.

611  {
612  JobReport::OutputFile& f = impl_->getOutputFileForToken(fileToken);
613  f.fastCopyingInputs.insert(std::make_pair(inputFileName, fastCopying));
614  }
double f[11][100]
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportGeneratorInfo ( std::string const &  name,
std::string const &  value 
)

Report key/value style generator/lumi information Eg: reportGeneratorInfo("CrossSection" , "ValueHere") No special chars in the value string.

Definition at line 816 of file JobReport.cc.

References impl_.

816  {
817  impl_->addGeneratorInfo(name, value);
818  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportInputLumiSection ( unsigned int  run,
unsigned int  lumiSectId 
)

API for reporting a Lumi Section to the job report. for input files, call only if lumi section is physically read from the input file

Definition at line 658 of file JobReport.cc.

References impl_.

Referenced by DQMRootSource::readLuminosityBlock_().

658  {
659  impl_->associateInputLumiSection(run, lumiSectId);
660  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportInputRunNumber ( unsigned int  run)

API to report a run read from input

Definition at line 667 of file JobReport.cc.

References impl_.

Referenced by DQMRootSource::readRun_().

667  {
668  impl_->associateInputRun(run);
669  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportLumiSection ( unsigned int  run,
unsigned int  lumiSectId 
)

API for reporting a Lumi Section to the job report. for output files, call only if lumi section is written to the output file

Definition at line 653 of file JobReport.cc.

References impl_.

Referenced by DQMRootOutputModule::writeLuminosityBlock().

653  {
654  impl_->associateLumiSection(run, lumiSectId);
655  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportMemoryInfo ( std::vector< std::string > const &  memoryData)

Report Memory statistics ALTERNATE FORM - USING THIS MAY NECESSITATE CHANGES IN PARSING XML! Invoked by the Memory service to send an end of job summary about memory usage for inclusion in the job report

Definition at line 749 of file JobReport.cc.

References impl_, lumiQueryAPI::msg, and pos.

749  {
750  if(impl_->ost_) {
751  std::ostream& msg = *(impl_->ost_);
752  msg << "<MemoryService>\n";
753 
754  typedef std::vector<std::string>::const_iterator const_iterator;
755  for(const_iterator pos = memoryData.begin(), posEnd = memoryData.end(); pos != posEnd; ++pos) {
756  msg << *pos << "\n";
757  }
758  msg << "</MemoryService>\n";
759  msg << std::flush;
760  }
761  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportMessageInfo ( std::map< std::string, double > const &  messageData)

Report Message statistics Invoked by the MessageLogger service to send an end of job summary about numbers of various categories messages issued for inclusion in the job report

Definition at line 764 of file JobReport.cc.

References impl_, lumiQueryAPI::msg, and pos.

Referenced by edm::service::MessageLogger::SummarizeInJobReport().

764  {
765  if(impl_->ost_) {
766  std::ostream& msg = *(impl_->ost_);
767  msg << "<MessageSummary>\n";
768  typedef std::map<std::string, double>::const_iterator const_iterator;
769  for(const_iterator pos = messageData.begin(), posEnd = messageData.end(); pos != posEnd; ++pos) {
770  msg << " <" << pos->first
771  << " Value=\"" << pos->second << "\" />"
772  << "\n";
773  }
774  msg << "</MessageSummary>\n";
775  msg << std::flush;
776  }
777  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportPerformanceForModule ( std::string const &  metricClass,
std::string const &  moduleName,
std::map< std::string, std::string > const &  metrics 
)

Definition at line 865 of file JobReport.cc.

References impl_, and lumiQueryAPI::msg.

867  {
868  if(impl_->ost_) {
869  std::ostream& msg = *(impl_->ost_);
870  msg << "<PerformanceReport>\n"
871  << " <PerformanceModule Metric=\"" << metricClass << "\" "
872  << " Module=\"" << moduleName << "\" >\n";
873 
874  typedef std::map<std::string, std::string>::const_iterator const_iterator;
875  for(const_iterator iter = metrics.begin(), iterEnd = metrics.end(); iter != iterEnd; ++iter) {
876  msg << " <Metric Name=\"" << iter->first << "\" "
877  << "Value=\"" << iter->second << "\"/>\n";
878  }
879 
880  msg << " </PerformanceModule>\n"
881  << "</PerformanceReport>\n";
882  msg << std::flush;
883  //LogInfo("FwkJob") << msg.str();
884  }
885  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportPerformanceSummary ( std::string const &  metricClass,
std::map< std::string, std::string > const &  metrics 
)

Performance Reports

Two categories: Summary for entire job and module for a specific module Each one requires a performance metric class such as Timing, Memory, CPU, Trigger etc.

Definition at line 844 of file JobReport.cc.

References impl_, and lumiQueryAPI::msg.

Referenced by TFileAdaptor::termination().

845  {
846  if(impl_->ost_) {
847  std::ostream& msg = *(impl_->ost_);
848  msg << "<PerformanceReport>\n"
849  << " <PerformanceSummary Metric=\"" << metricClass << "\">\n";
850 
851  typedef std::map<std::string, std::string>::const_iterator const_iterator;
852  for(const_iterator iter = metrics.begin(), iterEnd = metrics.end(); iter != iterEnd; ++iter) {
853  msg << " <Metric Name=\"" << iter->first << "\" "
854  << "Value=\"" << iter->second << "\"/>\n";
855  }
856 
857  msg << " </PerformanceSummary>\n"
858  << "</PerformanceReport>\n";
859  msg << std::flush;
860  //LogInfo("FwkJob") << msg.str();
861  }
862  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportPSetHash ( std::string const &  hashValue)

Report PSetHash

Definition at line 832 of file JobReport.cc.

References impl_, and lumiQueryAPI::msg.

832  {
833  if(impl_->ost_) {
834  std::ostream& msg = *(impl_->ost_);
835  msg << "<PSetHash>"
836  << hashValue
837  << "</PSetHash>\n";
838  //LogInfo("FwkJob") << msg.str();
839  msg << std::flush;
840  }
841  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportRandomStateFile ( std::string const &  name)

Report the name of the random engine persistency file

Definition at line 820 of file JobReport.cc.

References impl_, and lumiQueryAPI::msg.

820  {
821  if(impl_->ost_) {
822  std::ostream& msg = *(impl_->ost_);
823  msg << "<RandomServiceStateFile>\n"
824  << TiXmlText(name) << "\n"
825  << "</RandomServiceStateFile>\n";
826  //LogInfo("FwkJob") << msg.str();
827  msg << std::flush;
828  }
829  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportReadBranch ( std::string const &  branchName)

Inform the job report that a branch has been read.

Definition at line 798 of file JobReport.cc.

References impl_.

798  {
799  // Fast cloned branches have already been reported.
800  if(impl_->fastClonedBranches_->find(branchName) == impl_->fastClonedBranches_->end()) {
801  ++impl_->readBranches_[branchName];
802  }
803  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportReadBranches ( )

Report read branches Invoked by the source that reads ROOT/EDM files at the end of a job to report which product branches in the Events tree have been read, with a count of the number of events for which the branch was read.

Definition at line 780 of file JobReport.cc.

References impl_, and TiXmlElement::SetAttribute().

780  {
781  if(impl_->ost_) {
782  std::ostream& ost = *(impl_->ost_);
783  ost << "<ReadBranches>\n";
784  typedef std::map<std::string, long long>::const_iterator const_iterator;
785  for(const_iterator it = impl_->readBranches_.begin(), itEnd = impl_->readBranches_.end(); it != itEnd; ++it) {
786  TiXmlElement branch("Branch");
787  branch.SetAttribute("Name", it->first);
788  branch.SetAttribute("ReadCount", it->second);
789  ost << branch << "\n";
790  // ost << " <Branch Name=" << '"' << it->first << '"'<< " ReadCount=" << it->second << ">\n";
791  }
792  ost << "</ReadBranches>\n";
793  ost << std::flush;
794  }
795  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportRunNumber ( unsigned int  run)

API to report the a run written to output

Definition at line 663 of file JobReport.cc.

References impl_.

Referenced by DQMRootOutputModule::writeRun().

663  {
664  impl_->associateRun(run);
665  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportSkippedEvent ( unsigned int  run,
unsigned int  event 
)

Definition at line 642 of file JobReport.cc.

References impl_, and lumiQueryAPI::msg.

642  {
643  if(impl_->ost_) {
644  std::ostream& msg = *(impl_->ost_);
645  msg << "<SkippedEvent Run=\"" << run << "\"";
646  msg << " Event=\"" << event << "\" />\n";
647  msg << std::flush;
648  //LogInfo("FwkJob") << msg.str();
649  }
650  }
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434
void JobReport::reportSkippedFile ( std::string const &  pfn,
std::string const &  lfn 
)

Report Skipped File

Report that a file has been skipped due to it not being found.

Definition at line 721 of file JobReport.cc.

References impl_, lumiQueryAPI::msg, and TiXmlElement::SetAttribute().

722  {
723  if(impl_->ost_) {
724  std::ostream& msg = *(impl_->ost_);
725  TiXmlElement skipped("SkippedFile");
726  skipped.SetAttribute("Pfn", pfn);
727  skipped.SetAttribute("Lfn", lfn);
728  msg << skipped << "\n";
729  msg << std::flush;
730  //LogInfo("FwkJob") << msg.str();
731  }
732  }
list pfn
Definition: dbtoconf.py:76
boost::scoped_ptr< JobReportImpl > impl_
Definition: JobReport.h:434

Member Data Documentation

boost::scoped_ptr<JobReportImpl> edm::JobReport::impl_
private