Skip to content

Commit

Permalink
do not count meta events in total event count in the DAT file
Browse files Browse the repository at this point in the history
  • Loading branch information
smorovic committed Jun 18, 2024
1 parent 7e7b449 commit 74706e1
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions EventFilter/Utilities/plugins/GlobalEvFOutputModule.cc
Original file line number Diff line number Diff line change
Expand Up @@ -76,10 +76,11 @@ namespace evf {
return (discarded_ || edm::Service<evf::EvFDaqDirector>()->lumisectionDiscarded(ls_));
}

void doOutputEvent(EventMsgBuilder const& msg) {
void doOutputEvent(EventMsgBuilder const& msg, bool inc) {
EventMsgView eview(msg.startAddress());
stream_writer_events_->write(eview);
incAccepted();
if (inc)
incAccepted();
}

void doOutputEventAsync(std::unique_ptr<EventMsgBuilder> msg, edm::WaitingTaskHolder iHolder) {
Expand All @@ -97,9 +98,9 @@ namespace evf {
if (meta_) {
auto m = std::move(meta_);
assert(m->builder_);
doOutputEvent(*m->builder_);
doOutputEvent(*m->builder_, false);
}
doOutputEvent(*msg); //msg is written and discarded at this point
doOutputEvent(*msg, true); //msg is written and discarded at this point
} catch (...) {
auto tmp = holder;
tmp.doneWaiting(std::current_exception());
Expand Down

0 comments on commit 74706e1

Please sign in to comment.