Skip to content
Snippets Groups Projects

Add optional extension of EventProcessor for asynchronous processing

Merged Marco Clemencic requested to merge clemenci/Gaudi:async-main-loop into master

Added a new interface (Gaudi::Interfaces::IAsyncEventProcessor) to allow writing applications running event loops in threads independent from the main thread.

The key point is that instead of nextEvent(N) or executeEvent() one can call asyncExecuteEvent(), which returns a std:future carrying the final StatusCode of the event loop and the EventContext that was passed to the method.

The main thread would then be able to control when and how to enqueue new events (e.g. for asynchronous I/O from the network), and, at the same time, know which events have been processed.

For backward compatibility, the event processor required to work in async mode must be specifically adapted to the new interface.

:warning: Includes !838 (merged)

CC @frankm, @nnolte

Edited by Marco Clemencic

Merge request reports

Pipeline #862021 passed

Pipeline passed for e88d7c3f on clemenci:async-main-loop

Merged by Marco ClemencicMarco Clemencic 5 years ago (May 16, 2019 12:15pm UTC)

Loading

Pipeline #863962 passed

Pipeline passed for 19e9e78d on master

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading