Skip to content

Revise DFO protocol to enhance resilience and consensus#486

Draft
Copilot wants to merge 13 commits intodevelopfrom
copilot/revise-dfo-protocol-resilience
Draft

Revise DFO protocol to enhance resilience and consensus#486
Copilot wants to merge 13 commits intodevelopfrom
copilot/revise-dfo-protocol-resilience

Conversation

Copy link
Copy Markdown

Copilot AI commented Apr 15, 2026

  • Create include/dfmodules/DFODecision.hpp
  • Extend src/dfmodules/DFOCore.hpp and src/DFOCore.cpp
  • Rewrite plugins/DFOConsensusModule.hpp and .cpp
  • Update test/config/dfo_consensus_test.data.xml
  • Update unittest/DFOConsensusModule_test.cxx
  • Fix atomic snapshot races and clarifying comments
  • Fix WatchdogFailover test: start watchdog unconditionally in do_start so peers announcing after do_start are covered

Copilot AI linked an issue Apr 15, 2026 that may be closed by this pull request
@eflumerf eflumerf closed this Apr 15, 2026
@eflumerf eflumerf reopened this Apr 15, 2026
Copilot stopped work on behalf of eflumerf due to an error April 15, 2026 15:01
Copilot AI requested a review from eflumerf April 15, 2026 15:27
@eflumerf
Copy link
Copy Markdown
Member

@copilot The new module should only inherit from DAQModule. Common DFO code can be moved to library functions in either src or plugins/detail

Copy link
Copy Markdown
Author

Copilot AI commented Apr 16, 2026

@copilot The new module should only inherit from DAQModule. Common DFO code can be moved to library functions in either src or plugins/detail

Done in commit b280c75. DFOConsensusModule now inherits DAQModule directly, with no dependency on DFOModule. All common DFO processing logic (TRB management, slot selection, dispatching, token handling, busy notification, opmon counters) has been extracted into src/dfmodules/DFOCore.hpp/.cpp and added to the library. Both DFOModule and DFOConsensusModule use DFOCore via unique_ptr composition.

Copilot AI changed the title [WIP] Revise DFO protocol to enhance resilience and consensus Revise DFO protocol to enhance resilience and consensus Apr 16, 2026
@eflumerf
Copy link
Copy Markdown
Member

@copilot Add unit tests for DFOCore

Agent-Logs-Url: https://github.com/DUNE-DAQ/dfmodules/sessions/a1889c64-61e1-42b6-9525-fb129d8e5168

Co-authored-by: eflumerf <61473357+eflumerf@users.noreply.github.com>
Copy link
Copy Markdown
Author

Copilot AI commented Apr 16, 2026

@copilot Add unit tests for DFOCore

Done in commit 812721a. Added unittest/DFOCore_test.cxx with 12 test cases covering: copy/move semantics, constructor state, configure/start/stop/scrap lifecycle, TRB registration (new_trb_fn callback), TRB reconnect, run-number mismatch handling in tokens and TDs, successful TD dispatch with opmon counters, stop() returning in-flight TDs as remnants, and round-robin/fallback slot selection.

Copilot AI and others added 2 commits April 20, 2026 14:48
…comments, watchdog logs)

Agent-Logs-Url: https://github.com/DUNE-DAQ/dfmodules/sessions/8cfa3196-9570-48f5-a552-ad88bae3d298

Co-authored-by: eflumerf <61473357+eflumerf@users.noreply.github.com>
…ments are handled

Agent-Logs-Url: https://github.com/DUNE-DAQ/dfmodules/sessions/ad5ee7fa-bbd5-49fc-8323-82e234ed90b9

Co-authored-by: eflumerf <61473357+eflumerf@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants