RTC Toolkit 5.1.0
Loading...
Searching...
No Matches
alertAggregator.hpp
Go to the documentation of this file.
1
13#ifndef RTCTK_RTCSUPERVISOR_ALERTAGGREGATOR_HPP
14#define RTCTK_RTCSUPERVISOR_ALERTAGGREGATOR_HPP
15
18
19#include <map>
20#include <mutex>
21#include <string>
22
23namespace rtctk::rtcSupervisor {
24
29public:
33 using ObjectList = std::vector<std::string>;
34
36 virtual ~AlertAggregator();
37
38private:
39 void OnAlertStatusChanged(const std::string& id, bool status);
40
41 struct ObjectInfo {
43 AlertSource alert_source;
44 };
45
46 AlertServiceIf& m_alerts;
47 OldbIf& m_oldb;
48 std::mutex m_mutex;
49 std::map<std::string, ObjectInfo> m_objects;
50};
51
52} // namespace rtctk::rtcSupervisor
53
54#endif // RTCTK_RTCSUPERVISOR_STATUSESTIMATOR_HPP
Declares AlertService.
Alert Service interface.
Definition alertServiceIf.hpp:138
Models a single alert source that can be set or cleared.
Definition alertServiceIf.hpp:47
Base interface for all OLDB adapters.
Definition oldbIf.hpp:25
size_t SubscriptionId
Definition repositorySubscriberIf.hpp:51
Class for system status estimation.
Definition alertAggregator.hpp:28
std::vector< std::string > ObjectList
Definition alertAggregator.hpp:33
virtual ~AlertAggregator()
Definition alertAggregator.cpp:55
AlertAggregator(AlertServiceIf &alerts, OldbIf &oldb, const ObjectList &objects)
Definition alertAggregator.cpp:23
elt::mal::future< std::string > InjectReqRepEvent(StateMachineEngine &engine)
Definition malEventInjector.hpp:23
Definition rtcSupervisor.cpp:24
Header file for OldbIf, which defines the API for OldbAdapters.