Skip to content

Commit ce9b4ea

Browse files
committed
DPL: Take runNumber and timeSlice for CCDB message from timingInfo, instead of first random message
1 parent 1e23267 commit ce9b4ea

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

Framework/Core/src/CommonServices.cxx

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -407,9 +407,7 @@ o2::framework::ServiceSpec CommonServices::ccdbSupportSpec()
407407
LOGP(debug, "We are w/o outputs, do not automatically add DISTSUBTIMEFRAME to outgoing messages");
408408
return;
409409
}
410-
const auto ref = pc.inputs().getFirstValid(true);
411-
const auto* dh = DataRefUtils::getHeader<o2::header::DataHeader*>(ref);
412-
const auto* dph = DataRefUtils::getHeader<DataProcessingHeader*>(ref);
410+
auto& timingInfo = pc.services().get<TimingInfo>();
413411

414412
// For any output that is a FLP/DISTSUBTIMEFRAME with subspec != 0,
415413
// we create a new message.
@@ -424,9 +422,9 @@ o2::framework::ServiceSpec CommonServices::ccdbSupportSpec()
424422
continue;
425423
}
426424
auto& stfDist = pc.outputs().make<o2::header::STFHeader>(Output{concrete.origin, concrete.description, concrete.subSpec, output.matcher.lifetime});
427-
stfDist.id = dph->startTime;
428-
stfDist.firstOrbit = dh->firstTForbit;
429-
stfDist.runNumber = dh->runNumber;
425+
stfDist.id = timingInfo.timeslice;
426+
stfDist.firstOrbit = timingInfo.firstTForbit;
427+
stfDist.runNumber = timingInfo.runNumber;
430428
}
431429
} },
432430
.kind = ServiceKind::Global};

0 commit comments

Comments
 (0)