artdaq
v3_12_02
|
A RoutingManagerPolicy which simply assigns Sequence IDs to tokens in the order they were received. More...
Public Member Functions | |
NoOpPolicy (fhicl::ParameterSet const &ps) | |
NoOpPolicy Constructor. More... | |
~NoOpPolicy () override=default | |
Default virtual Destructor. | |
void | CreateRoutingTable (detail::RoutingPacket &table) override |
Add entries to the given RoutingPacket using currently-held tokens. More... | |
detail::RoutingPacketEntry | CreateRouteForSequenceID (artdaq::Fragment::sequence_id_t seq, int requesting_rank) override |
Get an artdaq::detail::RoutingPacketEntry for a given sequence ID and rank. Used by RequestBasedEventBuilder and DataFlow RoutingManagerMode. More... | |
![]() | |
RoutingManagerPolicy (const fhicl::ParameterSet &ps) | |
RoutingManagerPolicy Constructor. More... | |
virtual | ~RoutingManagerPolicy ()=default |
Default virtual Destructor. | |
size_t | GetReceiverCount () const |
Get the number of configured receivers. More... | |
size_t | GetMaxNumberOfTokens () const |
Get the largest number of tokens that the RoutingManagerPolicy has seen at any one time. More... | |
size_t | GetTokensUsedSinceLastUpdate () const |
Get the number of tokens that have been used since the last update. More... | |
void | ResetTokensUsedSinceLastUpdate () |
Reset the number of tokens used. | |
void | AddReceiverToken (int rank, unsigned new_slots_free) |
Add a token to the token list. More... | |
void | Reset () |
Reset the policy, setting the next sequence ID to be used to 1, and removing any tokens. | |
Fragment::sequence_id_t | GetNextSequenceID () const |
Get the next sequence ID to be routed. More... | |
size_t | GetHeldTokenCount () const |
Get the number of tokens that are waiting to be used. More... | |
detail::RoutingPacket | GetCurrentTable () |
Create a RoutingPacket from currently-owned tokens. Used by EventBuilder and RequestBasedEventBuilder RoutingManagerMode. More... | |
detail::RoutingPacketEntry | GetRouteForSequenceID (artdaq::Fragment::sequence_id_t seq, int requesting_rank) |
Get an artdaq::detail::RoutingPacketEntry for a given sequence ID and rank. Used by RequestBasedEventBuilder and DataFlow RoutingManagerMode. More... | |
detail::RoutingManagerMode | GetRoutingMode () const |
Get the current RoutingManagerMode of this RoutingManager. More... | |
size_t | GetCacheSize () const |
Get the size of the routing cache. For testing. More... | |
bool | CacheHasRoute (artdaq::Fragment::sequence_id_t seq) const |
Determine whether the routing cache has a route for the given sequence ID. For testing. More... | |
Additional Inherited Members | |
![]() | |
std::deque< int > | tokens_ |
The list of tokens which are available for use. | |
std::atomic< size_t > | tokens_used_since_last_update_ |
Number of tokens consumed since last metric update. | |
Fragment::sequence_id_t | next_sequence_id_ |
The next sequence ID to be assigned. | |
std::unordered_set< int > | receiver_ranks_ |
Configured receiver (e.g. EventBuilder for BR->EB routing) ranks. | |
detail::RoutingManagerMode | routing_mode_ |
Current routing mode. | |
A RoutingManagerPolicy which simply assigns Sequence IDs to tokens in the order they were received.
Definition at line 15 of file NoOp_policy.cc.
|
inlineexplicit |
NoOpPolicy Constructor.
ps | ParameterSet used to configure the NoOpPolicy |
NoOpPolicy takes no additional Parameters at this time
Definition at line 24 of file NoOp_policy.cc.
|
overridevirtual |
Get an artdaq::detail::RoutingPacketEntry for a given sequence ID and rank. Used by RequestBasedEventBuilder and DataFlow RoutingManagerMode.
seq | Sequence Number to get route for |
requesting_rank | Rank to route for |
Implements artdaq::RoutingManagerPolicy.
Definition at line 67 of file NoOp_policy.cc.
|
overridevirtual |
Add entries to the given RoutingPacket using currently-held tokens.
table | RoutingPacket to add entries to |
NoOp_policy will add entries for all tokens in the order that they were received
Implements artdaq::RoutingManagerPolicy.
Definition at line 56 of file NoOp_policy.cc.