Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
ed8ee63
Initial plan
Copilot Apr 15, 2026
d9d2192
Implement DFO consensus algorithm with deterministic partitioning
Copilot Apr 15, 2026
2f51404
Refactor: DFOConsensusModule inherits DAQModule directly via DFOCore …
Copilot Apr 16, 2026
b280c75
style: use named copy + std::move for peer announcement sends
Copilot Apr 16, 2026
f28114c
Move source file to src directory
eflumerf Apr 16, 2026
812721a
test: add DFOCore unit tests (12 test cases)
Copilot Apr 16, 2026
0c800c1
fix: register triginh callback in CfgFixture to prevent DFOCore test …
Copilot Apr 16, 2026
f5e22e6
fix: add missing triginh callback to SendTrigDecFailed test in DFOMod…
Copilot Apr 16, 2026
a1e7656
Separate stop and flush so that any pending trigger decision callback…
eflumerf Apr 20, 2026
dde446a
Merge remote-tracking branch 'origin/develop' into copilot/revise-dfo…
eflumerf Apr 20, 2026
c719937
feat: DFODecision broadcast, remote-slot shadow, global busy, watchdo…
Copilot Apr 20, 2026
aaaee1d
fix: address code review comments (atomic snapshot races, clarifying …
Copilot Apr 20, 2026
b9d855c
fix: start watchdog unconditionally in do_start so late peer announce…
Copilot Apr 20, 2026
cb670b7
Merge remote-tracking branch 'origin/kbiery/integtest_verbosity_level…
eflumerf Apr 20, 2026
c6d966e
Merge remote-tracking branch 'origin/develop' into copilot/revise-dfo…
eflumerf Apr 24, 2026
067d302
chore: plan merge of DFO modules behind DFOConf consensus flag
Copilot Apr 24, 2026
dd38668
refactor: merge consensus logic into DFOModule and wrap DFOConsensusM…
Copilot Apr 24, 2026
635283a
Remove DFOConsensusModule, update DFOModule_test to use consensus for
eflumerf Apr 24, 2026
284f0ad
Merge remote-tracking branch 'origin/develop' into copilot/revise-dfo…
eflumerf May 1, 2026
b3a1e5a
chore: plan follow-up for DFO announcement/comment cleanup
Copilot May 1, 2026
6f1aeb6
fix: use DFODecision for peer announcements and update DFO comments
Copilot May 1, 2026
51fbbdf
Merge branch 'copilot/revise-dfo-protocol-resilience' of github.com:D…
eflumerf May 1, 2026
6db59e5
chore: plan reintegrate DFOCore into DFOModule with minimal develop d…
Copilot May 12, 2026
54d35de
refactor: reintegrate DFO core logic into DFOModule and drop standalo…
Copilot May 12, 2026
5b3864a
fix: address review findings and ignore ctest temporary artifacts
Copilot May 12, 2026
8bbb6a5
style: apply static_cast and prefix decrement cleanup
Copilot May 12, 2026
f26edac
fix: harden retry casting and tighten watchdog loop condition
Copilot May 12, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,6 @@ __pycache__

# clang formatting temporary files
.clang-format

# ctest generated artifacts
Testing/Temporary/
6 changes: 3 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@ daq_protobuf_codegen( opmon/*.proto )

##############################################################################
daq_add_library( TriggerInhibitAgent.cpp TriggerRecordBuilderData.cpp TPBundleHandler.cpp
LINK_LIBRARIES
LINK_LIBRARIES
opmonlib::opmonlib ers::ers HighFive appfwk::appfwk logging::logging stdc++fs dfmessages::dfmessages utilities::utilities trigger::trigger detdataformats::detdataformats trgdataformats::trgdataformats)


daq_add_plugin( HDF5DataStore duneDataStore LINK_LIBRARIES dfmodules hdf5libs::hdf5libs stdc++fs)

daq_add_plugin( FragmentAggregatorModule duneDAQModule LINK_LIBRARIES dfmodules iomanager::iomanager )
daq_add_plugin( DataWriterModule duneDAQModule LINK_LIBRARIES dfmodules hdf5libs::hdf5libs iomanager::iomanager )
daq_add_plugin( DFOModule duneDAQModule LINK_LIBRARIES dfmodules iomanager::iomanager )
daq_add_plugin( DFOModule duneDAQModule LINK_LIBRARIES dfmodules iomanager::iomanager )
daq_add_plugin( TRBModule duneDAQModule LINK_LIBRARIES dfmodules iomanager::iomanager )
daq_add_plugin( TRMonRequestorModule duneDAQModule LINK_LIBRARIES dfmodules iomanager::iomanager )
daq_add_plugin( FakeDataProdModule duneDAQModule LINK_LIBRARIES dfmodules iomanager::iomanager)
Expand Down
63 changes: 63 additions & 0 deletions include/dfmodules/DFODecision.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
/**
* @file DFODecision.hpp DFODecision message used by DFOConsensusModule.
*
* A DFODecision is broadcast by the responsible DFOConsensusModule to all
* peer DFOs after each TRBModule state change (trigger assignment or
* completion). This allows every DFO in the ensemble to maintain an accurate
* per-TRBModule slot-usage view and issue correct TriggerInhibit messages to
* the MLT.
*
* Fields
* ------
* run_number – run in which this decision was made
* trigger_number – the TriggerDecision that triggered the state change
* trb_connection_name– connection-ID of the TRBModule whose slot count changed
* trb_slot_count – absolute slot count for that TRB *after* the change
* source_dfo_name – name() of the DFO that generated this message
* is_completion – false = new assignment; true = TRB completed a trigger
*
* Serialisation
* -------------
* nlohmann/json (to_json / from_json) is provided via
* NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE. For in-process Queue transport this is
* not required; for network (ZMQ / kSendRecv) connections production
* deployments should additionally register a msgpack serialiser in dfmessages.
*
* This is part of the DUNE DAQ Software Suite, copyright 2020.
* Licensing/copyright details are in the COPYING file that you should have
* received with this code.
*/

#ifndef DFMODULES_INCLUDE_DFMODULES_DFODECISION_HPP_
#define DFMODULES_INCLUDE_DFMODULES_DFODECISION_HPP_

#include "daqdataformats/Types.hpp"
#include "nlohmann/json.hpp"

#include <string>

namespace dunedaq {
namespace dfmodules {

struct DFODecision
{
daqdataformats::run_number_t run_number{ 0 };
daqdataformats::trigger_number_t trigger_number{ 0 };
std::string trb_connection_name; ///< Connection-ID of the TRBModule involved
size_t trb_slot_count{ 0 }; ///< TRB slot count after this event
std::string source_dfo_name; ///< Name of the DFO that generated this message
bool is_completion{ false }; ///< true = completion; false = new assignment
};

NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE(DFODecision,
run_number,
trigger_number,
trb_connection_name,
trb_slot_count,
source_dfo_name,
is_completion)

} // namespace dfmodules
} // namespace dunedaq

#endif // DFMODULES_INCLUDE_DFMODULES_DFODECISION_HPP_
Loading