1 #ifndef art_Framework_Core_OutputModule_h 2 #define art_Framework_Core_OutputModule_h 30 #include "cetlib/BasicPluginFactory.h" 47 class ResultsPrincipal;
57 std::vector<std::unique_ptr<FileCatalogMetadataPlugin>>;
64 return {
"module_label"};
76 std::vector<std::string>{
"keep *"}};
80 R
"(The "fileName" parameter is a pattern used to form the name of the output file. 81 The ROOT output module supports the placeholders described at: 83 https://cdcvs.fnal.gov/redmine/projects/art_root_io/wiki/Output_file_renaming_for_ROOT_files)"), 90 "The 'FCMDPlugins' parameter is a sequence of tables of the form:\n\n" 91 " FCMDPlugins: [ { plugin_type: <pluginClassName> ...}, ... ]\n\n" 92 "where each sequence element is the configuration for an instance\n" 93 "of a FileCatalogMetadataPlugin object. Please review the " 95 "at the top of \"art/Framework/Core/FileCatalogMetadataPlugin.h\" " 97 "more information.")};
144 std::atomic<std::size_t>& counts_run,
145 std::atomic<std::size_t>& counts_passed,
146 std::atomic<std::size_t>& counts_failed);
212 std::vector<fhicl::ParameterSet>
const& psets);
virtual void writeFileIdentifier()
bool doOpenFile(FileBlock const &fb)
std::array< bool, NumBranchTypes > const & hasNewlyDroppedBranch() const
void doWriteEvent(EventPrincipal &ep, ModuleContext const &mc)
virtual void writeProcessConfigurationRegistry()
fhicl::Atom< std::string > fileName
void updateBranchParents(EventPrincipal &ep)
virtual void readResults(ResultsPrincipal const &resp)
virtual void doBeginJob(detail::SharedResources const &resources)
virtual void finishEndFile()
fhicl::Sequence< std::string > outputCommands
virtual void incrementInputFileNumber()
fhicl::Atom< std::string > moduleType
virtual void event(EventPrincipal const &)
virtual void respondToCloseOutputFiles(FileBlock const &)
virtual void writeRun(RunPrincipal &r)=0
virtual void writeSubRun(SubRunPrincipal &sr)=0
virtual void doRegisterProducts(ProductDescriptions &, ModuleDescription const &)
std::vector< std::string > pluginNames_
OutputModule & operator=(OutputModule const &)=delete
bool doEndSubRun(SubRunPrincipal const &srp, ModuleContext const &mc)
virtual void respondToOpenInputFile(FileBlock const &)
void writeFileCatalogMetadata()
void doWriteSubRun(SubRunPrincipal &srp)
std::vector< BranchDescription > ProductDescriptions
void doSelectProducts(ProductTables const &)
bool doBeginSubRun(SubRunPrincipal const &srp, ModuleContext const &mc)
virtual void writeFileFormatVersion()
virtual void beginRun(RunPrincipal const &)
bool doEvent(EventPrincipal const &ep, ModuleContext const &mc, std::atomic< std::size_t > &counts_run, std::atomic< std::size_t > &counts_passed, std::atomic< std::size_t > &counts_failed)
BranchChildren branchChildren_
virtual void endRun(RunPrincipal const &)
virtual bool isFileOpen() const
virtual std::string const & lastClosedFileName() const
std::vector< std::unique_ptr< FileCatalogMetadataPlugin >> PluginCollection_t
void doRespondToCloseInputFile(FileBlock const &fb)
OutputFileStatus fileStatus() const
void selectProducts(ProductTables const &)
fhicl::TableFragment< Observer::EOConfig > eoFragment
virtual void writeFileIndex()
virtual void respondToOpenOutputFiles(FileBlock const &)
GroupSelectorRules groupSelectorRules_
PluginCollection_t plugins_
virtual void setSubRunAuxiliaryRangeSetID(RangeSet const &)
fhicl::OptionalDelegatedParameter fcmdPlugins
std::set< std::string > operator()()
virtual void writeParameterSetRegistry()
std::array< bool, NumBranchTypes > hasNewlyDroppedBranch_
virtual void endSubRun(SubRunPrincipal const &)
bool doEndRun(RunPrincipal const &rp, ModuleContext const &mc)
std::array< std::unique_ptr< GroupSelector const >, NumBranchTypes > groupSelector_
virtual void setRunAuxiliaryRangeSetID(RangeSet const &)
virtual void writeParentageRegistry()
virtual void write(EventPrincipal &e)=0
void doSetSubRunAuxiliaryRangeSetID(RangeSet const &)
SelectionsArray keptProducts_
ServiceHandle< CatalogInterface > ci_
virtual void writeProductDescriptionRegistry()
std::array< Selections, NumBranchTypes > SelectionsArray
virtual Granularity fileGranularity() const
OutputModule(fhicl::ParameterSet const &pset)
std::map< ProductID, std::set< ParentageID > > branchParents_
bool selected(BranchDescription const &) const
std::string configuredFileName_
virtual bool requestsToCloseFile() const
void fillDependencyGraph()
cet::BasicPluginFactory pluginFactory_
void doRespondToOpenOutputFiles(FileBlock const &fb)
virtual void postSelectProducts()
fhicl::Atom< std::string > streamName
PluginCollection_t makePlugins_(std::vector< fhicl::ParameterSet > const &psets)
fhicl::Atom< std::string > dataTier
virtual void openFile(FileBlock const &)
void doWriteRun(RunPrincipal &rp)
void registerProducts(ProductDescriptions &)
SelectionsArray const & keptProducts() const
virtual void writeProcessHistoryRegistry()
friend class OutputWorker
virtual void writeProductDependencies()
virtual void setFileStatus(OutputFileStatus)
std::map< ProductID, std::set< ParentageID >> BranchParents
virtual void doWriteFileCatalogMetadata(FileCatalogMetadata::collection_type const &md, FileCatalogMetadata::collection_type const &ssmd)
virtual void respondToCloseInputFile(FileBlock const &)
void doRespondToCloseOutputFiles(FileBlock const &fb)
std::unique_ptr< Worker > doMakeWorker(WorkerParams const &wp) final
BranchChildren const & branchChildren() const
virtual void beginSubRun(SubRunPrincipal const &)
void doRespondToOpenInputFile(FileBlock const &fb)
virtual void startEndFile()
void doSetRunAuxiliaryRangeSetID(RangeSet const &)
void configure(OutputModuleDescription const &desc)
bool doBeginRun(RunPrincipal const &rp, ModuleContext const &)