1 #include "art/Framework/Core/FileBlock.h"
2 #include "art/Framework/Core/InputSourceMacros.h"
3 #include "art/Framework/Core/ProductRegistryHelper.h"
4 #include "art/Framework/IO/Sources/Source.h"
5 #include "art/Framework/IO/Sources/SourceHelper.h"
6 #include "art/Framework/IO/Sources/SourceTraits.h"
7 #include "art/Framework/Services/Registry/ServiceHandle.h"
9 #if ART_HEX_VERSION < 0x30000
10 #include "art/Persistency/Provenance/MasterProductRegistry.h"
11 #include "art/Persistency/Provenance/ProductMetaData.h"
13 #if ART_HEX_VERSION >= 0x30200
14 #include "art_root_io/setup.h"
16 #include "art/Persistency/Provenance/ProcessHistoryRegistry.h"
18 #include "canvas/Persistency/Common/EDProduct.h"
19 #include "canvas/Persistency/Common/Wrapper.h"
20 #include "canvas/Persistency/Provenance/BranchDescription.h"
21 #include "canvas/Persistency/Provenance/BranchKey.h"
22 #include "canvas/Persistency/Provenance/History.h"
23 #include "canvas/Persistency/Provenance/ParentageRegistry.h"
24 #include "canvas/Persistency/Provenance/ProcessConfiguration.h"
25 #include "canvas/Persistency/Provenance/ProcessHistory.h"
26 #include "canvas/Persistency/Provenance/ProcessHistoryID.h"
27 #include "canvas/Persistency/Provenance/ProductList.h"
28 #include "canvas/Persistency/Provenance/ProductProvenance.h"
29 #include "canvas/Persistency/Provenance/ProductTables.h"
30 #include "canvas/Utilities/DebugMacros.h"
32 #include "fhiclcpp/ParameterSet.h"
33 #include "fhiclcpp/ParameterSetID.h"
34 #include "fhiclcpp/ParameterSetRegistry.h"
35 #include "fhiclcpp/make_ParameterSet.h"
37 #include <TBufferFile.h>
40 #include <TStreamerInfo.h>
42 #include "artdaq-core/Data/detail/ParentageMap.hh"
43 #include "artdaq-core/Utilities/ExceptionHandler.hh"
44 #include "artdaq/ArtModules/InputUtilities.hh"
45 #include "artdaq/DAQdata/Globals.hh"
56 #if ART_HEX_VERSION < 0x30000
60 #define HISTORY_PTR_T std::shared_ptr<art::History>
62 #define EVENT_ID eventID
63 #define SUBRUN_ID subRunID
65 #define HISTORY_PTR_T std::unique_ptr<art::History>
113 ArtdaqInput(
const fhicl::ParameterSet& ps, art::ProductRegistryHelper& helper, art::SourceHelper
const& pm);
124 void readFile(
const std::string&, art::FileBlock*& fb);
141 bool readNext(art::RunPrincipal*
const inR, art::SubRunPrincipal*
const inSR, art::RunPrincipal*& outR,
142 art::SubRunPrincipal*& outSR, art::EventPrincipal*& outE);
145 void readAndConstructPrincipal(std::unique_ptr<TBufferFile>&,
unsigned long, art::RunPrincipal*
const,
146 art::SubRunPrincipal*
const, art::RunPrincipal*&, art::SubRunPrincipal*&,
147 art::EventPrincipal*&);
150 void readDataProducts(std::unique_ptr<TBufferFile>&, T*&);
152 void putInPrincipal(RunPrincipal*&, std::unique_ptr<EDProduct>&&,
const BranchDescription&,
153 std::unique_ptr<const ProductProvenance>&&);
155 void putInPrincipal(SubRunPrincipal*&, std::unique_ptr<EDProduct>&&,
const BranchDescription&,
156 std::unique_ptr<const ProductProvenance>&&);
158 void putInPrincipal(EventPrincipal*&, std::unique_ptr<EDProduct>&&,
const BranchDescription&,
159 std::unique_ptr<const ProductProvenance>&&);
162 bool shutdownMsgReceived_;
163 bool outputFileCloseNeeded_;
164 art::SourceHelper
const& pm_;
165 U communicationWrapper_;
166 ProductList* productList_;
167 HISTORY_PTR_T history_to_use_;
172 art::SourceHelper
const& pm)
173 : shutdownMsgReceived_(false), outputFileCloseNeeded_(false), pm_(pm), communicationWrapper_(ps), productList_()
175 artdaq::configureMessageFacility(
"artdaqart");
177 #if ART_HEX_VERSION >= 0x30200
182 volatile bool loop =
true;
195 TLOG_ARB(5,
"ArtdaqInput") <<
"Begin: ArtdaqInput::ArtdaqInput("
196 <<
"const fhicl::ParameterSet& ps, "
197 <<
"art::ProductRegistryHelper& helper, "
198 <<
"const art::SourceHelper& pm)";
200 TLOG_ARB(5,
"ArtdaqInput") <<
"Going to receive init message";
201 std::unique_ptr<TBufferFile> msg(
nullptr);
202 communicationWrapper_.receiveInitMessage(msg);
203 TLOG_ARB(5,
"ArtdaqInput") <<
"Init message received";
207 throw art::Exception(art::errors::DataCorruption) <<
"ArtdaqInput: Could not receive init message!";
211 unsigned long dummy = 0;
212 msg->ReadULong(dummy);
215 TList* list = (TList*)msg->ReadObject(TList::Class());
219 TObjLink* lnk = list->FirstLink();
223 info = (TStreamerInfo*)lnk->GetObject();
224 TObject* element = info->GetElements()->UncheckedAt(0);
225 Bool_t isstl = element && strcmp(
"This", element->GetName()) == 0;
229 TLOG_ARB(5,
"ArtdaqInput") <<
"ArtdaqInput: importing TStreamerInfo: " << info->GetName() <<
", version = " << info->GetClassVersion();
234 lnk = list->FirstLink();
237 info = (TStreamerInfo*)lnk->GetObject();
238 TObject* element = info->GetElements()->UncheckedAt(0);
239 Bool_t isstl = element && strcmp(
"This", element->GetName()) == 0;
243 TLOG_ARB(5,
"ArtdaqInput") <<
"ArtdaqInput: importing TStreamerInfo: " << info->GetName() <<
", version = " << info->GetClassVersion();
252 unsigned long ps_cnt = 0;
253 msg->ReadULong(ps_cnt);
254 TLOG_ARB(5,
"ArtdaqInput") <<
"ArtdaqInput: parameter set count: " << ps_cnt;
255 TLOG_ARB(5,
"ArtdaqInput") <<
"ArtdaqInput: reading parameter sets ...";
256 for (
unsigned long I = 0; I < ps_cnt; ++I)
258 std::string pset_str =
"";
259 msg->ReadStdString(pset_str);
261 TLOG_ARB(5,
"ArtdaqInput") <<
"ArtdaqInput: parameter set: " << pset_str;
263 fhicl::ParameterSet pset;
264 fhicl::make_ParameterSet(pset_str, pset);
267 fhicl::ParameterSetRegistry::put(pset);
269 TLOG_ARB(5,
"ArtdaqInput") <<
"ArtdaqInput: finished reading parameter sets.";
274 productList_ = ReadObjectAny<art::ProductList>(
275 msg,
"std::map<art::BranchKey,art::BranchDescription>",
"ArtdaqInput::ArtdaqInput");
276 TLOG_ARB(5,
"ArtdaqInput") <<
"ArtdaqInput: Product list sz=" << productList_->size();
279 for (
auto I = productList_->begin(), E = productList_->end(); I != E; ++I)
281 TLOG_ARB(50,
"ArtdaqInput") <<
"Branch key: class: '" << I->first.friendlyClassName_ <<
"' modlbl: '"
282 << I->first.moduleLabel_ <<
"' instnm: '" << I->first.productInstanceName_ <<
"' procnm: '"
283 << I->first.processName_ <<
"', branch description name: " << I->second.wrappedName()
284 <<
", TClass = " << (
void*)TClass::GetClass(I->second.wrappedName().c_str());
289 #if ART_HEX_VERSION < 0x30000
290 helper.productList(productList_);
292 helper.productList(std::unique_ptr<art::ProductList>(productList_));
294 TLOG_ARB(5,
"ArtdaqInput") <<
"ArtdaqInput: got product list";
296 TLOG_ARB(5,
"ArtdaqInput") <<
"ArtdaqInput: Reading ProcessHistory";
297 art::ProcessHistoryMap* phm = ReadObjectAny<art::ProcessHistoryMap>(
298 msg,
"std::map<const art::Hash<2>,art::ProcessHistory>",
"ArtdaqInput::ArtdaqInput");
301 ProcessHistoryRegistry::put(*phm);
302 printProcessMap(ProcessHistoryRegistry::get(),
"ArtdaqInput's ProcessHistoryRegistry");
307 TLOG_ARB(5,
"ArtdaqInput") <<
"ArtdaqInput: Reading ParentageMap";
308 ParentageMap* parentageMap = ReadObjectAny<ParentageMap>(msg,
"art::ParentageMap",
"ArtdaqInput::ArtdaqInput");
309 ParentageRegistry::put(*parentageMap);
314 TLOG_ARB(5,
"ArtdaqInput") <<
"ArtdaqInput: Reading History";
315 history_to_use_.reset(ReadObjectAny<History>(msg,
"art::History",
"ArtdaqInput::ArtdaqInput"));
316 if (!history_to_use_->processHistoryID().isValid())
318 TLOG_ARB(5,
"ArtdaqInput") <<
"ArtdaqInput: History from init message is INVALID!";
324 TLOG_ARB(5,
"ArtdaqInput") <<
"End: ArtdaqInput::ArtdaqInput("
325 <<
"const fhicl::ParameterSet& ps, "
326 <<
"art::ProductRegistryHelper& helper, "
327 <<
"const art::SourceHelper& pm)";
337 TLOG_ARB(6,
"ArtdaqInput") <<
"Begin/End: ArtdaqInput::closeCurrentFile()";
343 TLOG_ARB(7,
"ArtdaqInput") <<
"Begin: ArtdaqInput::"
344 "readFile(const std::string& name, art::FileBlock*& fb)";
345 fb =
new art::FileBlock(art::FileFormatVersion(1,
"ArtdaqInput2013"),
"nothing");
346 TLOG_ARB(7,
"ArtdaqInput") <<
"End: ArtdaqInput::"
347 "readFile(const std::string& name, art::FileBlock*& fb)";
353 TLOG_ARB(8,
"ArtdaqInput") <<
"Begin: ArtdaqInput::hasMoreData()";
354 if (shutdownMsgReceived_)
356 TLOG_ARB(8,
"ArtdaqInput") <<
"ArtdaqInput::hasMoreData(): "
357 "returning false on shutdownMsgReceived_.";
358 TLOG_ARB(8,
"ArtdaqInput") <<
"End: ArtdaqInput::hasMoreData()";
361 TLOG_ARB(8,
"ArtdaqInput") <<
"ArtdaqInput::hasMoreData(): "
362 "returning true on not shutdownMsgReceived_.";
363 TLOG_ARB(8,
"ArtdaqInput") <<
"End: ArtdaqInput::hasMoreData()";
369 art::RunPrincipal*
const inR, art::SubRunPrincipal*
const inSR,
370 art::RunPrincipal*& outR, art::SubRunPrincipal*& outSR,
371 art::EventPrincipal*& outE)
376 std::unique_ptr<art::RunAuxiliary> run_aux;
377 std::unique_ptr<art::SubRunAuxiliary> subrun_aux;
378 std::unique_ptr<art::EventAuxiliary> event_aux;
380 HISTORY_PTR_T history_from_event;
387 if (msg_type_code == 2)
390 TLOG_ARB(9,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
391 <<
"processing EndRun message ...";
393 run_aux.reset(ReadObjectAny<art::RunAuxiliary>(msg,
"art::RunAuxiliary",
"ArtdaqInput::readAndConstructPrincipal"));
396 TLOG_ARB(9,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
397 <<
"making flush RunPrincipal ...";
398 outR = pm_.makeRunPrincipal(RunID::flushRun(), run_aux->beginTime());
400 TLOG_ARB(9,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
401 <<
"making flush SubRunPrincipal ...";
402 outSR = pm_.makeSubRunPrincipal(SubRunID::flushSubRun(), run_aux->beginTime());
404 TLOG_ARB(9,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
405 <<
"making flush EventPrincipal ...";
406 outE = pm_.makeEventPrincipal(EventID::flushEvent(), run_aux->endTime(),
true, EventAuxiliary::Any);
408 TLOG_ARB(9,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
409 <<
"finished processing EndRun message.";
411 else if (msg_type_code == 3)
414 TLOG_ARB(10,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
415 <<
"processing EndSubRun message ...";
418 ReadObjectAny<art::SubRunAuxiliary>(msg,
"art::SubRunAuxiliary",
"ArtdaqInput::readAndConstructPrincipal"));
421 TLOG_ARB(10,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
422 <<
"making flush RunPrincipal ...";
423 outR = pm_.makeRunPrincipal(RunID::flushRun(), subrun_aux->beginTime());
440 art::Timestamp currentTime = time(0);
443 #if ART_HEX_VERSION < 0x30000
444 inR->setEndTime(currentTime);
446 inR->endTime(currentTime);
451 #if ART_HEX_VERSION < 0x30000
452 inSR->setEndTime(currentTime);
454 inSR->endTime(currentTime);
458 TLOG_ARB(10,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
459 <<
"making flush SubRunPrincipal ...";
460 outSR = pm_.makeSubRunPrincipal(SubRunID::flushSubRun(), subrun_aux->beginTime());
462 TLOG_ARB(10,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
463 <<
"making flush EventPrincipal ...";
464 outE = pm_.makeEventPrincipal(EventID::flushEvent(), subrun_aux->endTime(),
true, EventAuxiliary::Any);
466 TLOG_ARB(10,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
467 <<
"finished processing EndSubRun message.";
469 else if (msg_type_code == 4)
472 TLOG_ARB(11,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
473 <<
"processing Event message ...";
475 run_aux.reset(ReadObjectAny<art::RunAuxiliary>(msg,
"art::RunAuxiliary",
"ArtdaqInput::readAndConstructPrincipal"));
479 ReadObjectAny<art::SubRunAuxiliary>(msg,
"art::SubRunAuxiliary",
"ArtdaqInput::readAndConstructPrincipal"));
483 ReadObjectAny<art::EventAuxiliary>(msg,
"art::EventAuxiliary",
"ArtdaqInput::readAndConstructPrincipal"));
485 history_from_event.reset(ReadObjectAny<art::History>(msg,
"art::History",
"ArtdaqInput::readAndConstructPrincipal"));
489 if (!history_from_event->processHistoryID().isValid())
491 throw art::Exception(art::errors::Unknown)
492 <<
"readAndConstructPrincipal: processHistoryID of history in Event message is invalid!";
495 else if (!history_to_use_->processHistoryID().isValid())
497 history_to_use_.swap(history_from_event);
500 else if (!art::ProcessHistoryRegistry::get().count(history_to_use_->processHistoryID()) &&
501 art::ProcessHistoryRegistry::get().count(history_from_event->processHistoryID()))
503 history_to_use_.swap(history_from_event);
506 TLOG_ARB(11,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
507 <<
"inR: " << (
void*)inR <<
" run/expected "
508 << (inR ? std::to_string(inR->run()) :
"invalid") <<
"/" << event_aux->run();
509 TLOG_ARB(11,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
510 <<
"inSR: " << (
void*)inSR <<
" run/expected "
511 << (inSR ? std::to_string(inSR->run()) :
"invalid") <<
"/" << event_aux->run()
512 <<
", subrun/expected " << (inSR ? std::to_string(inSR->subRun()) :
"invalid") <<
"/"
513 << event_aux->subRun();
514 if ((inR ==
nullptr) || !inR->RUN_ID().isValid() || (inR->run() != event_aux->run()))
518 TLOG_ARB(11,
"ArtdaqInput") <<
"readAndConstructPrincipal: making RunPrincipal ...";
519 outR = pm_.makeRunPrincipal(*run_aux.get());
521 art::SubRunID subrun_check(event_aux->run(), event_aux->subRun());
522 if (inSR == 0 || subrun_check != inSR->SUBRUN_ID())
526 TLOG_ARB(11,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
527 <<
"making SubRunPrincipal ...";
528 outSR = pm_.makeSubRunPrincipal(*subrun_aux.get());
530 TLOG_ARB(11,
"ArtdaqInput") <<
"readAndConstructPrincipal: making EventPrincipal ...";
531 auto historyPtr = HISTORY_PTR_T(
new History(*(history_to_use_.get())));
532 if (!art::ProcessHistoryRegistry::get().count(history_to_use_->processHistoryID()))
534 TLOG_WARNING(
"ArtdaqInput") <<
"Stored history is not in ProcessHistoryRegistry, this event may have issues!";
536 outE = pm_.makeEventPrincipal(*event_aux.get(), std::move(historyPtr));
538 TLOG_ARB(11,
"ArtdaqInput") <<
"readAndConstructPrincipal: "
539 <<
"finished processing Event message.";
547 unsigned long prd_cnt = 0;
549 TLOG_ARB(12,
"ArtdaqInput") <<
"readDataProducts: reading data product count ...";
550 msg->ReadULong(prd_cnt);
551 TLOG_ARB(12,
"ArtdaqInput") <<
"readDataProducts: product count: " << prd_cnt;
556 for (
unsigned long I = 0; I < prd_cnt; ++I)
558 std::unique_ptr<BranchKey> bk;
560 TLOG_ARB(12,
"ArtdaqInput") <<
"readDataProducts: Reading branch key.";
561 bk.reset(ReadObjectAny<BranchKey>(msg,
"art::BranchKey",
"ArtdaqInput::readDataProducts"));
565 TLOG_ARB(13,
"ArtdaqInput") <<
"readDataProducts: got product class: '" << bk->friendlyClassName_ <<
"' modlbl: '"
566 << bk->moduleLabel_ <<
"' instnm: '" << bk->productInstanceName_ <<
"' procnm: '"
569 ProductList::const_iterator iter;
571 TLOG_ARB(12,
"ArtdaqInput") <<
"readDataProducts: looking up product ...";
572 iter = productList_->find(*bk);
573 if (iter == productList_->end())
575 throw art::Exception(art::errors::ProductNotFound)
576 <<
"No product is registered for\n"
577 <<
" process name: '" << bk->processName_ <<
"'\n"
578 <<
" module label: '" << bk->moduleLabel_ <<
"'\n"
579 <<
" product friendly class name: '" << bk->friendlyClassName_ <<
"'\n"
580 <<
" product instance name: '" << bk->productInstanceName_ <<
"'\n";
585 const BranchDescription& bd = iter->second;
586 std::unique_ptr<EDProduct> prd;
588 TLOG_ARB(12,
"ArtdaqInput") <<
"readDataProducts: Reading product with wrapped name: " << bd.wrappedName()
589 <<
", TClass = " << (
void*)TClass::GetClass(bd.wrappedName().c_str());
596 void* p = msg->ReadObjectAny(TClass::GetClass(bd.wrappedName().c_str()));
597 auto pp =
reinterpret_cast<EDProduct*
>(p);
599 TLOG_ARB(12,
"ArtdaqInput") <<
"readDataProducts: After ReadObjectAny(prd): p=" << p <<
", EDProduct::isPresent: " << pp->isPresent();
603 std::unique_ptr<const ProductProvenance> prdprov;
605 TLOG_ARB(12,
"ArtdaqInput") <<
"readDataProducts: Reading product provenance.";
606 prdprov.reset(ReadObjectAny<ProductProvenance>(msg,
"art::ProductProvenance",
"ArtdaqInput::readDataProducts"));
610 TLOG_ARB(12,
"ArtdaqInput") <<
"readDataProducts: inserting product: class: '" << bd.friendlyClassName()
611 <<
"' modlbl: '" << bd.moduleLabel() <<
"' instnm: '" << bd.productInstanceName()
612 <<
"' procnm: '" << bd.processName() <<
"' id: '" << bd.productID() <<
"'";
613 putInPrincipal(outPrincipal, std::move(prd), bd, std::move(prdprov));
620 const BranchDescription& bd,
621 std::unique_ptr<const ProductProvenance>&& prdprov)
623 #if ART_HEX_VERSION < 0x30000
624 rp->put(std::move(prd), bd, std::move(prdprov), RangeSet::forRun(rp->RUN_ID()));
626 rp->put(bd, std::move(prdprov), std::move(prd), std::make_unique<RangeSet>(RangeSet::forRun(rp->RUN_ID())));
632 const BranchDescription& bd,
633 std::unique_ptr<const ProductProvenance>&& prdprov)
635 #if ART_HEX_VERSION < 0x30000
636 srp->put(std::move(prd), bd, std::move(prdprov), RangeSet::forSubRun(srp->SUBRUN_ID()));
638 srp->put(bd, std::move(prdprov), std::move(prd), std::make_unique<RangeSet>(RangeSet::forSubRun(srp->SUBRUN_ID())));
644 const BranchDescription& bd,
645 std::unique_ptr<const ProductProvenance>&& prdprov)
647 TLOG_ARB(14,
"ArtdaqInput") <<
"EventPrincipal size before put: " << ep->size();
648 #if ART_HEX_VERSION < 0x30000
649 ep->put(std::move(prd), bd, std::move(prdprov));
651 ep->put(bd, std::move(prdprov), std::move(prd), std::make_unique<RangeSet>(RangeSet::invalid()));
653 TLOG_ARB(14,
"ArtdaqInput") <<
"EventPrincipal size after put: " << ep->size();
658 art::RunPrincipal*& outR, art::SubRunPrincipal*& outSR, art::EventPrincipal*& outE)
660 TLOG_ARB(15,
"ArtdaqInput") <<
"Begin: ArtdaqInput::readNext";
661 if (outputFileCloseNeeded_)
663 outputFileCloseNeeded_ =
false;
666 TLOG_ARB(15,
"ArtdaqInput") <<
"ArtdaqInput::readNext: "
667 <<
"returning false on outputFileCloseNeeded_";
668 TLOG_ARB(15,
"ArtdaqInput") <<
"End: ArtdaqInput::readNext";
672 std::unique_ptr<TBufferFile> msg;
673 communicationWrapper_.receiveMessage(msg);
677 TLOG_ARB(15,
"ArtdaqInput") <<
"ArtdaqInput::readNext got an empty message";
678 shutdownMsgReceived_ =
true;
685 unsigned long msg_type_code = 0;
687 TLOG_ARB(15,
"ArtdaqInput") <<
"ArtdaqInput::readNext: "
688 <<
"getting message type code ...";
689 msg->ReadULong(msg_type_code);
690 TLOG_ARB(15,
"ArtdaqInput") <<
"ArtdaqInput::readNext: "
691 <<
"message type: " << msg_type_code;
693 if (msg_type_code == 5)
696 shutdownMsgReceived_ =
true;
697 TLOG_ARB(16,
"ArtdaqInput") <<
"ArtdaqInput::readNext: "
698 <<
"returning false on Shutdown message.";
699 TLOG_ARB(16,
"ArtdaqInput") <<
"End: ArtdaqInput::readNext";
703 readAndConstructPrincipal(msg, msg_type_code, inR, inSR, outR, outSR, outE);
707 if (msg_type_code == 2)
711 readDataProducts(msg, outR);
713 TLOG_ARB(17,
"ArtdaqInput") <<
"ArtdaqInput::readNext: "
714 <<
"returning false on EndRun message.";
715 TLOG_ARB(17,
"ArtdaqInput") <<
"End: ArtdaqInput::readNext";
718 else if (msg_type_code == 3)
729 if (inR != 0 && inSR != 0 && outR != 0 && outSR != 0)
731 if (inR->RUN_ID().isFlush() && inSR->SUBRUN_ID().isFlush() && outR->RUN_ID().isFlush() &&
732 outSR->SUBRUN_ID().isFlush())
736 outputFileCloseNeeded_ =
true;
741 readDataProducts(msg, outSR);
744 outputFileCloseNeeded_ =
true;
745 TLOG_ARB(18,
"ArtdaqInput") <<
"readNext: returning true on EndSubRun message.";
746 TLOG_ARB(18,
"ArtdaqInput") <<
"End: ArtdaqInput::readNext";
749 else if (msg_type_code == 4)
752 readDataProducts(msg, outE);
753 TLOG_ARB(19,
"ArtdaqInput") <<
"readNext: returning true on Event message.";
754 TLOG_ARB(19,
"ArtdaqInput") <<
"End: ArtdaqInput::readNext";
759 TLOG_ARB(20,
"ArtdaqInput") <<
"readNext: returning false on unknown msg_type_code!";
760 TLOG_ARB(20,
"ArtdaqInput") <<
"End: ArtdaqInput::readNext";
void printProcessHistoryID(const std::string &label, const T &object)
Print the processHistoryID from the object.
void printProcessMap(const T &mappable, const std::string description)
Print data from a map-like class.