Implement Report persistency
Now Report properties are stored in non-volatile memory. It allows
to restore Report after system restart. Persistency of a report is
controlled by Persistency property in Report interface.
Tested:
- Passed unit tests
- Verified that report is stored in /var/lib/telemetry dir
- Verified that report is restored from storage after telemetry
service start
Signed-off-by: Wludzik, Jozef <jozef.wludzik@intel.com>
Change-Id: Iccfe21603eecffc4e174a4403f699b03de320db9
diff --git a/src/interfaces/types.hpp b/src/interfaces/types.hpp
index 0d5eeb2..1eca51a 100644
--- a/src/interfaces/types.hpp
+++ b/src/interfaces/types.hpp
@@ -1,5 +1,8 @@
#pragma once
+#include "utils/labeled_tuple.hpp"
+#include "utils/tstring.hpp"
+
#include <sdbusplus/message/types.hpp>
#include <string>
@@ -10,6 +13,12 @@
std::vector<std::tuple<std::vector<sdbusplus::message::object_path>,
std::string, std::string, std::string>>;
+using LabeledReadingParameter =
+ utils::LabeledTuple<ReadingParameters::value_type,
+ utils::tstring::SensorPaths,
+ utils::tstring::OperationType, utils::tstring::Id,
+ utils::tstring::MetricMetadata>;
+
using Readings = std::tuple<
uint64_t,
std::vector<std::tuple<std::string, std::string, double, uint64_t>>>;