|
ATLAS Offline Software
|
Go to the documentation of this file.
4 #ifndef TRIGSERVICES_HLTROBDATAPROVIDERSVC_H
5 #define TRIGSERVICES_HLTROBDATAPROVIDERSVC_H
15 #include "eformat/SourceIdentifier.h"
26 #include <string_view>
32 #include "tbb/concurrent_unordered_map.h"
49 virtual void addROBData(
const EventContext& ,
const std::vector<uint32_t>& ,
50 const std::string_view callerName=
"UNKNOWN")
override;
53 virtual void setNextEvent(
const EventContext& ,
const std::vector<ROBF>& )
override;
60 const std::vector<uint32_t>& , std::vector<const ROBF*>& ,
61 const std::string_view callerName=
"UNKNOWN")
override;
73 virtual void processCachedROBs(
const EventContext& ,
const std::function<
void(
const ROBF* )>& )
const override;
80 const std::string_view callerName=
"UNKNOWN")
override;
88 typedef tbb::concurrent_unordered_map<uint32_t, ROBF>
ROBMAP;
113 this,
"filterRobWithStatus", {} ,
"List of ROBs with status code to remove"};
115 this,
"filterSubDetWithStatus", {} ,
"List of SubDets with status code to remove"};
126 this,
"filterEmptyROB", false ,
"Filter out empty ROB fragments"};
134 this,
"readROBfromOKS", true ,
"Read enabled ROBs from OKS"};
138 this,
"enabledROBs", {} ,
"Enabled ROBs for retrieval"};
142 this,
"prefetchAllROBsfromROS", false ,
"When ROBs from a ROS are requested then prefetch all ROBs in this ROS"};
150 this,
"prefetchSubDetROS", {} ,
"List of sub-detectors for which whole ROS prefetching is used"};
155 this,
"doCostMonitoring",
false,
"Enables start-of-event cost monitoring behavior."};
158 this,
"TrigCostSvc",
"TrigCostSvc",
"The trigger cost service" };
192 std::vector<const ROBF*>&, std::vector<uint32_t>&,
193 std::optional<std::reference_wrapper<std::set<uint32_t>>> robIds_disabled = std::nullopt);
202 std::optional<std::reference_wrapper<std::set<uint32_t>>> robIds_ignored = std::nullopt) ;
205 ToolHandle<GenericMonitoringTool>
m_monTool{
this,
"MonTool",
"",
"Monitoring tool"};
208 #endif // TRIGSERVICES_HLTROBDATAPROVIDERSVC_H
virtual StatusCode finalize() override
virtual void setNextEvent(const EventContext &, const std::vector< ROBF > &) override
Start a new event with a set of ROB fragments, e.g. from LVL1 result, in online and add the fragments...
virtual uint32_t getEventStatus(const EventContext &) override
Retrieve the status for the event.
A structure with data about ROB properties.
ROBHistory
A structure with data about ROB properties.
virtual void getROBData(const EventContext &, const std::vector< uint32_t > &, std::vector< const ROBF * > &, const std::string_view callerName="UNKNOWN") override
Retrieve ROB fragments for given ROB ids from the ROB cache.
SG::SlotSpecificObj< EventCache > m_eventsCache
An event cache for each slot.
FilterSubDetMap m_filterSubDetMap
Gaudi::Property< bool > m_prefetchAllROBsfromROS
OFFLINE_FRAGMENTS_NAMESPACE::FullEventFragment RawEvent
data type for reading raw event
struct which provides the event cache for each slot
Gaudi::Property< bool > m_filterEmptyROB
Filter out empty ROB fragments which are send by the ROS.
robmonitor::ROBDataStruct robmap_getRobData(const ROBF &, robmonitor::ROBHistory)
method to get ROB fragment from ROBF input: context ROB fragment to be parsed ROB history status
OFFLINE_FRAGMENTS_NAMESPACE_WRITE::ROBFragment ROBF
Maintain a set of objects, one per slot.
virtual void processCachedROBs(const EventContext &, const std::function< void(const ROBF *)> &) const override
Apply a function to all ROBs in the cache.
virtual StatusCode initialize() override
std::vector< std::pair< int, int > > ArrayPairIntType
vector of Source ids and status words to be ignored for the ROB map
::StatusCode StatusCode
StatusCode definition for legacy code.
ToolHandle< GenericMonitoringTool > m_monTool
Monitoring tool.
void eventCache_clear(EventCache *)
method to clear an event cache in a slot input: pointer to cache
bool m_maskL2EFModuleID
For Run 1 the module ID for the Lvl2/EF result contained the machine ID and needed to be filtered out...
Gaudi::Property< std::vector< uint8_t > > m_prefetchSubDetROS
Header file to be included by clients of the Monitored infrastructure.
Gaudi::Property< bool > m_readROBfromOKS
ROBDataProvider service for retrieving and serving ROB data in HLT online.
FilterRobMap m_filterRobMap
Gaudi::Property< ArrayPairIntType > m_filterSubDetWithStatus
Gaudi::Property< bool > m_doCostMonitoring
virtual void setEventStatus(const EventContext &, uint32_t) override
Store the status for the event.
ServiceHandle< ITrigCostSvc > m_trigCostSvcHandle
OFFLINE_FRAGMENTS_NAMESPACE::ROBFragment ROBF
ROB Fragment class.
void eventCache_addRobData(EventCache *, std::vector< ROBF > &&, std::optional< std::reference_wrapper< std::set< uint32_t >>> robIds_ignored=std::nullopt)
method to add ROB fragments to an event cache in a slot input: pointer to cache vector of ROB fragmen...
virtual void addROBData(const EventContext &, const std::vector< uint32_t > &, const std::string_view callerName="UNKNOWN") override
Signal ROB fragments which should be considered for prefetching in online running.
uint64_t globalEventNumber
HltROBDataProviderSvc(const std::string &name, ISvcLocator *pSvcLocator)
virtual bool isEventComplete(const EventContext &) const override
Flag to check if all event data have been retrieved.
virtual int collectCompleteEventData(const EventContext &, const std::string_view callerName="UNKNOWN") override
retrieve in online running all ROBs for the event from the readout system. Only those ROBs are retrie...
std::mutex eventCache_mtx
mutex for ROB cache updates
tbb::concurrent_unordered_map< uint32_t, ROBF > ROBMAP
map for all the ROB fragments
Maintain a set of objects, one per slot.
std::map< eformat::SubDetector, std::vector< uint32_t > > FilterSubDetMap
map of Sub Det Source ids and status words to be ignored for the ROB map
virtual const RawEvent * getEvent(const EventContext &) override
Retrieve the full event fragment.
std::map< uint32_t, std::vector< uint32_t > > FilterRobMap
map of full ROB Source ids and status words to be ignored for the ROB map
Gaudi::Property< std::vector< uint32_t > > m_enabledROBs
Gaudi::Property< ArrayPairIntType > m_filterRobWithStatus
std::vector< uint32_t > m_prefetchWholeROSList
bool robmap_filterRobWithStatus(const ROBF *)
method to filter ROBs with given Status code
void eventCache_checkRobListToCache(EventCache *, const std::vector< uint32_t > &, std::vector< const ROBF * > &, std::vector< uint32_t > &, std::optional< std::reference_wrapper< std::set< uint32_t >>> robIds_disabled=std::nullopt)
method to compare a list of ROB Ids to the ones in an event cache in a slot input: pointer to cache v...