8 #ifndef FAIR_MQ_SHMEM_MONITOR_H_ 9 #define FAIR_MQ_SHMEM_MONITOR_H_ 11 #include <boost/interprocess/managed_shared_memory.hpp> 17 #include <unordered_map> 29 Monitor(
const std::string& sessionName,
bool selfDestruct,
bool interactive,
unsigned int timeoutInMS,
bool runAsDaemon,
bool cleanOnExit);
39 static void Cleanup(
const std::string& sessionName);
40 static void RemoveObject(
const std::string&);
41 static void RemoveQueue(
const std::string&);
47 void MonitorHeartbeats();
57 unsigned int fTimeoutInMS;
58 std::string fSessionName;
59 std::string fSegmentName;
60 std::string fManagementSegmentName;
61 std::string fControlQueueName;
62 std::atomic<bool> fTerminating;
63 std::atomic<bool> fHeartbeatTriggered;
64 std::chrono::high_resolution_clock::time_point fLastHeartbeat;
65 std::thread fSignalThread;
66 boost::interprocess::managed_shared_memory fManagementSegment;
67 std::unordered_map<std::string, std::chrono::high_resolution_clock::time_point> fDeviceHeartbeats;
Definition: DeviceRunner.h:23