Krzysztof Grobelny | 64b75a5 | 2020-09-18 10:17:16 +0200 | [diff] [blame] | 1 | #include "report_manager.hpp" |
| 2 | |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 3 | #include "report.hpp" |
Krzysztof Grobelny | dcc4e19 | 2021-03-08 09:09:34 +0000 | [diff] [blame] | 4 | #include "types/report_types.hpp" |
Krzysztof Grobelny | e8fc575 | 2021-02-05 14:30:45 +0000 | [diff] [blame] | 5 | #include "utils/conversion.hpp" |
Szymon Dompke | 32305f1 | 2022-07-05 15:37:21 +0200 | [diff] [blame] | 6 | #include "utils/dbus_path_utils.hpp" |
| 7 | #include "utils/make_id_name.hpp" |
Krzysztof Grobelny | d223819 | 2020-12-02 09:27:28 +0000 | [diff] [blame] | 8 | #include "utils/transform.hpp" |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 9 | |
| 10 | #include <phosphor-logging/log.hpp> |
Wludzik, Jozef | cb88cfd | 2020-09-28 16:38:57 +0200 | [diff] [blame] | 11 | #include <sdbusplus/exception.hpp> |
Krzysztof Grobelny | a8182be | 2022-07-04 11:26:20 +0200 | [diff] [blame] | 12 | #include <sdbusplus/unpack_properties.hpp> |
Wludzik, Jozef | cb88cfd | 2020-09-28 16:38:57 +0200 | [diff] [blame] | 13 | |
Krzysztof Grobelny | a8182be | 2022-07-04 11:26:20 +0200 | [diff] [blame] | 14 | #include <optional> |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 15 | #include <stdexcept> |
Krzysztof Grobelny | 64b75a5 | 2020-09-18 10:17:16 +0200 | [diff] [blame] | 16 | #include <system_error> |
| 17 | |
Krzysztof Grobelny | 64b75a5 | 2020-09-18 10:17:16 +0200 | [diff] [blame] | 18 | ReportManager::ReportManager( |
Wludzik, Jozef | 2f9f9b8 | 2020-10-13 09:07:45 +0200 | [diff] [blame] | 19 | std::unique_ptr<interfaces::ReportFactory> reportFactoryIn, |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 20 | std::unique_ptr<interfaces::JsonStorage> reportStorageIn, |
Krzysztof Grobelny | e6d4887 | 2022-02-08 13:41:30 +0100 | [diff] [blame] | 21 | const std::shared_ptr<sdbusplus::asio::object_server>& objServerIn) : |
Wludzik, Jozef | 2f9f9b8 | 2020-10-13 09:07:45 +0200 | [diff] [blame] | 22 | reportFactory(std::move(reportFactoryIn)), |
Krzysztof Grobelny | e6d4887 | 2022-02-08 13:41:30 +0100 | [diff] [blame] | 23 | reportStorage(std::move(reportStorageIn)), objServer(objServerIn) |
Krzysztof Grobelny | 64b75a5 | 2020-09-18 10:17:16 +0200 | [diff] [blame] | 24 | { |
Wludzik, Jozef | cb88cfd | 2020-09-28 16:38:57 +0200 | [diff] [blame] | 25 | reports.reserve(maxReports); |
Krzysztof Grobelny | 6ccfcbf | 2020-11-04 09:31:36 +0100 | [diff] [blame] | 26 | |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 27 | loadFromPersistent(); |
Krzysztof Grobelny | 64b75a5 | 2020-09-18 10:17:16 +0200 | [diff] [blame] | 28 | |
Wludzik, Jozef | cb88cfd | 2020-09-28 16:38:57 +0200 | [diff] [blame] | 29 | reportManagerIface = objServer->add_unique_interface( |
Patrick Williams | c7935fa | 2023-10-20 11:19:30 -0500 | [diff] [blame^] | 30 | reportManagerPath, reportManagerIfaceName, [this](auto& dbusIface) { |
Patrick Williams | 3a1c297 | 2023-05-10 07:51:04 -0500 | [diff] [blame] | 31 | dbusIface.register_property_r("MaxReports", size_t{}, |
| 32 | sdbusplus::vtable::property_::const_, |
| 33 | [](const auto&) { return maxReports; }); |
| 34 | dbusIface.register_property_r( |
| 35 | "MinInterval", uint64_t{}, sdbusplus::vtable::property_::const_, |
| 36 | [](const auto&) -> uint64_t { return minInterval.count(); }); |
| 37 | dbusIface.register_property_r( |
| 38 | "SupportedOperationTypes", std::vector<std::string>{}, |
| 39 | sdbusplus::vtable::property_::const_, |
| 40 | [](const auto&) -> std::vector<std::string> { |
Patrick Williams | c7935fa | 2023-10-20 11:19:30 -0500 | [diff] [blame^] | 41 | return utils::transform<std::vector>( |
| 42 | utils::convDataOperationType, |
| 43 | [](const auto& item) { return std::string(item.first); }); |
| 44 | }); |
Patrick Williams | 3a1c297 | 2023-05-10 07:51:04 -0500 | [diff] [blame] | 45 | dbusIface.register_method( |
| 46 | "AddReport", |
Krzysztof Grobelny | cff70c1 | 2022-10-27 07:16:08 +0000 | [diff] [blame] | 47 | [this](boost::asio::yield_context& yield, std::string reportId, |
| 48 | std::string reportName, std::string reportingType, |
| 49 | std::string reportUpdates, uint64_t appendLimit, |
| 50 | std::vector<std::string> reportActions, uint64_t interval, |
| 51 | ReadingParameters readingParameters, bool enabled) { |
| 52 | if (reportingType.empty()) |
Patrick Williams | 3a1c297 | 2023-05-10 07:51:04 -0500 | [diff] [blame] | 53 | { |
Krzysztof Grobelny | cff70c1 | 2022-10-27 07:16:08 +0000 | [diff] [blame] | 54 | reportingType = utils::enumToString(ReportingType::onRequest); |
Patrick Williams | 3a1c297 | 2023-05-10 07:51:04 -0500 | [diff] [blame] | 55 | } |
Krzysztof Grobelny | 51497a0 | 2021-11-09 14:56:22 +0100 | [diff] [blame] | 56 | |
Krzysztof Grobelny | cff70c1 | 2022-10-27 07:16:08 +0000 | [diff] [blame] | 57 | if (reportUpdates.empty()) |
Patrick Williams | 3a1c297 | 2023-05-10 07:51:04 -0500 | [diff] [blame] | 58 | { |
Krzysztof Grobelny | cff70c1 | 2022-10-27 07:16:08 +0000 | [diff] [blame] | 59 | reportUpdates = utils::enumToString(ReportUpdates::overwrite); |
Patrick Williams | 3a1c297 | 2023-05-10 07:51:04 -0500 | [diff] [blame] | 60 | } |
Krzysztof Grobelny | 62c08e9 | 2022-09-16 10:28:53 +0200 | [diff] [blame] | 61 | |
Krzysztof Grobelny | cff70c1 | 2022-10-27 07:16:08 +0000 | [diff] [blame] | 62 | if (appendLimit == std::numeric_limits<uint64_t>::max()) |
Patrick Williams | 3a1c297 | 2023-05-10 07:51:04 -0500 | [diff] [blame] | 63 | { |
Krzysztof Grobelny | cff70c1 | 2022-10-27 07:16:08 +0000 | [diff] [blame] | 64 | appendLimit = maxAppendLimit; |
Patrick Williams | 3a1c297 | 2023-05-10 07:51:04 -0500 | [diff] [blame] | 65 | } |
Krzysztof Grobelny | a8182be | 2022-07-04 11:26:20 +0200 | [diff] [blame] | 66 | |
Krzysztof Grobelny | cff70c1 | 2022-10-27 07:16:08 +0000 | [diff] [blame] | 67 | if (interval == std::numeric_limits<uint64_t>::max()) |
| 68 | { |
| 69 | interval = 0; |
| 70 | } |
| 71 | |
| 72 | return addReport(yield, reportId, reportName, |
| 73 | utils::toReportingType(reportingType), |
Patrick Williams | c7935fa | 2023-10-20 11:19:30 -0500 | [diff] [blame^] | 74 | utils::transform(reportActions, |
| 75 | [](const auto& reportAction) { |
Patrick Williams | 3a1c297 | 2023-05-10 07:51:04 -0500 | [diff] [blame] | 76 | return utils::toReportAction(reportAction); |
Patrick Williams | c7935fa | 2023-10-20 11:19:30 -0500 | [diff] [blame^] | 77 | }), |
Krzysztof Grobelny | cff70c1 | 2022-10-27 07:16:08 +0000 | [diff] [blame] | 78 | Milliseconds(interval), appendLimit, |
| 79 | utils::toReportUpdates(reportUpdates), |
| 80 | readingParameters, enabled) |
Patrick Williams | 3a1c297 | 2023-05-10 07:51:04 -0500 | [diff] [blame] | 81 | .getPath(); |
Wludzik, Jozef | cb88cfd | 2020-09-28 16:38:57 +0200 | [diff] [blame] | 82 | }); |
Patrick Williams | c7935fa | 2023-10-20 11:19:30 -0500 | [diff] [blame^] | 83 | }); |
Krzysztof Grobelny | 64b75a5 | 2020-09-18 10:17:16 +0200 | [diff] [blame] | 84 | } |
| 85 | |
Wludzik, Jozef | 2f9f9b8 | 2020-10-13 09:07:45 +0200 | [diff] [blame] | 86 | void ReportManager::removeReport(const interfaces::Report* report) |
Krzysztof Grobelny | 64b75a5 | 2020-09-18 10:17:16 +0200 | [diff] [blame] | 87 | { |
Wludzik, Jozef | cb88cfd | 2020-09-28 16:38:57 +0200 | [diff] [blame] | 88 | reports.erase( |
| 89 | std::remove_if(reports.begin(), reports.end(), |
| 90 | [report](const auto& x) { return report == x.get(); }), |
| 91 | reports.end()); |
Krzysztof Grobelny | 64b75a5 | 2020-09-18 10:17:16 +0200 | [diff] [blame] | 92 | } |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 93 | |
Krzysztof Grobelny | dcc4e19 | 2021-03-08 09:09:34 +0000 | [diff] [blame] | 94 | void ReportManager::verifyAddReport( |
Krzysztof Grobelny | b8cc78d | 2021-11-29 15:54:53 +0100 | [diff] [blame] | 95 | const std::string& reportId, const std::string& reportName, |
| 96 | const ReportingType reportingType, Milliseconds interval, |
Ankita Vilas Gawade | cd5b0b7 | 2022-01-20 20:55:04 +0000 | [diff] [blame] | 97 | const ReportUpdates reportUpdates, const uint64_t appendLimit, |
Krzysztof Grobelny | dcc4e19 | 2021-03-08 09:09:34 +0000 | [diff] [blame] | 98 | const std::vector<LabeledMetricParameters>& readingParams) |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 99 | { |
Szymon Dompke | 32305f1 | 2022-07-05 15:37:21 +0200 | [diff] [blame] | 100 | namespace ts = utils::tstring; |
| 101 | |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 102 | if (reports.size() >= maxReports) |
| 103 | { |
| 104 | throw sdbusplus::exception::SdBusError( |
| 105 | static_cast<int>(std::errc::too_many_files_open), |
| 106 | "Reached maximal report count"); |
| 107 | } |
| 108 | |
Krzysztof Grobelny | e6c417c | 2022-02-02 17:25:53 +0100 | [diff] [blame] | 109 | if (appendLimit > maxAppendLimit && |
| 110 | appendLimit != std::numeric_limits<uint64_t>::max()) |
Ankita Vilas Gawade | cd5b0b7 | 2022-01-20 20:55:04 +0000 | [diff] [blame] | 111 | { |
Krzysztof Grobelny | 62c08e9 | 2022-09-16 10:28:53 +0200 | [diff] [blame] | 112 | throw errors::InvalidArgument("AppendLimit", "Out of range."); |
Ankita Vilas Gawade | cd5b0b7 | 2022-01-20 20:55:04 +0000 | [diff] [blame] | 113 | } |
| 114 | |
Krzysztof Grobelny | 973b4bb | 2022-04-25 17:07:27 +0200 | [diff] [blame] | 115 | if ((reportingType == ReportingType::periodic && interval < minInterval) || |
| 116 | (reportingType != ReportingType::periodic && |
| 117 | interval != Milliseconds{0})) |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 118 | { |
Krzysztof Grobelny | 62c08e9 | 2022-09-16 10:28:53 +0200 | [diff] [blame] | 119 | throw errors::InvalidArgument("Interval"); |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 120 | } |
Wludzik, Jozef | bc766b4 | 2020-12-08 16:06:22 +0100 | [diff] [blame] | 121 | |
Ankita Vilas Gawade | cd5b0b7 | 2022-01-20 20:55:04 +0000 | [diff] [blame] | 122 | size_t metricCount = 0; |
| 123 | for (auto metricParam : readingParams) |
| 124 | { |
| 125 | auto metricParamsVec = |
| 126 | metricParam.at_label<utils::tstring::SensorPath>(); |
| 127 | metricCount += metricParamsVec.size(); |
| 128 | } |
Krzysztof Grobelny | e8fc575 | 2021-02-05 14:30:45 +0000 | [diff] [blame] | 129 | |
Ankita Vilas Gawade | cd5b0b7 | 2022-01-20 20:55:04 +0000 | [diff] [blame] | 130 | if (readingParams.size() > maxNumberMetrics || |
| 131 | metricCount > maxNumberMetrics) |
Wludzik, Jozef | bc766b4 | 2020-12-08 16:06:22 +0100 | [diff] [blame] | 132 | { |
Krzysztof Grobelny | 62c08e9 | 2022-09-16 10:28:53 +0200 | [diff] [blame] | 133 | throw errors::InvalidArgument("MetricParams", "Too many."); |
Wludzik, Jozef | bc766b4 | 2020-12-08 16:06:22 +0100 | [diff] [blame] | 134 | } |
Krzysztof Grobelny | e8fc575 | 2021-02-05 14:30:45 +0000 | [diff] [blame] | 135 | |
Krzysztof Grobelny | 62c08e9 | 2022-09-16 10:28:53 +0200 | [diff] [blame] | 136 | for (const LabeledMetricParameters& item : readingParams) |
Krzysztof Grobelny | e8fc575 | 2021-02-05 14:30:45 +0000 | [diff] [blame] | 137 | { |
Krzysztof Grobelny | 62c08e9 | 2022-09-16 10:28:53 +0200 | [diff] [blame] | 138 | utils::toOperationType( |
| 139 | utils::toUnderlying(item.at_label<ts::OperationType>())); |
Krzysztof Grobelny | e8fc575 | 2021-02-05 14:30:45 +0000 | [diff] [blame] | 140 | } |
Krzysztof Grobelny | d223819 | 2020-12-02 09:27:28 +0000 | [diff] [blame] | 141 | } |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 142 | |
Krzysztof Grobelny | d223819 | 2020-12-02 09:27:28 +0000 | [diff] [blame] | 143 | interfaces::Report& ReportManager::addReport( |
Krzysztof Grobelny | b8cc78d | 2021-11-29 15:54:53 +0100 | [diff] [blame] | 144 | boost::asio::yield_context& yield, const std::string& reportId, |
| 145 | const std::string& reportName, const ReportingType reportingType, |
Krzysztof Grobelny | 51497a0 | 2021-11-09 14:56:22 +0100 | [diff] [blame] | 146 | const std::vector<ReportAction>& reportActions, Milliseconds interval, |
| 147 | const uint64_t appendLimit, const ReportUpdates reportUpdates, |
Lukasz Kazmierczak | 7e098e9 | 2021-09-16 15:59:56 +0200 | [diff] [blame] | 148 | ReadingParameters metricParams, const bool enabled) |
Krzysztof Grobelny | d223819 | 2020-12-02 09:27:28 +0000 | [diff] [blame] | 149 | { |
Patrick Williams | 3a1c297 | 2023-05-10 07:51:04 -0500 | [diff] [blame] | 150 | auto labeledMetricParams = reportFactory->convertMetricParams(yield, |
| 151 | metricParams); |
Krzysztof Grobelny | d223819 | 2020-12-02 09:27:28 +0000 | [diff] [blame] | 152 | |
Krzysztof Grobelny | b8cc78d | 2021-11-29 15:54:53 +0100 | [diff] [blame] | 153 | return addReport(reportId, reportName, reportingType, reportActions, |
| 154 | interval, appendLimit, reportUpdates, |
Krzysztof Grobelny | 493e62e | 2022-02-14 10:55:50 +0100 | [diff] [blame] | 155 | std::move(labeledMetricParams), enabled, Readings{}); |
Krzysztof Grobelny | d223819 | 2020-12-02 09:27:28 +0000 | [diff] [blame] | 156 | } |
| 157 | |
| 158 | interfaces::Report& ReportManager::addReport( |
Krzysztof Grobelny | b8cc78d | 2021-11-29 15:54:53 +0100 | [diff] [blame] | 159 | const std::string& reportId, const std::string& reportName, |
| 160 | const ReportingType reportingType, |
Krzysztof Grobelny | 51497a0 | 2021-11-09 14:56:22 +0100 | [diff] [blame] | 161 | const std::vector<ReportAction>& reportActions, Milliseconds interval, |
| 162 | const uint64_t appendLimit, const ReportUpdates reportUpdates, |
Lukasz Kazmierczak | 7e098e9 | 2021-09-16 15:59:56 +0200 | [diff] [blame] | 163 | std::vector<LabeledMetricParameters> labeledMetricParams, |
Krzysztof Grobelny | 493e62e | 2022-02-14 10:55:50 +0100 | [diff] [blame] | 164 | const bool enabled, Readings readings) |
Krzysztof Grobelny | d223819 | 2020-12-02 09:27:28 +0000 | [diff] [blame] | 165 | { |
Krzysztof Grobelny | b8cc78d | 2021-11-29 15:54:53 +0100 | [diff] [blame] | 166 | const auto existingReportIds = utils::transform( |
| 167 | reports, [](const auto& report) { return report->getId(); }); |
| 168 | |
Szymon Dompke | 32305f1 | 2022-07-05 15:37:21 +0200 | [diff] [blame] | 169 | auto [id, name] = utils::makeIdName(reportId, reportName, reportNameDefault, |
| 170 | existingReportIds); |
Krzysztof Grobelny | b8cc78d | 2021-11-29 15:54:53 +0100 | [diff] [blame] | 171 | |
| 172 | verifyAddReport(id, name, reportingType, interval, reportUpdates, |
Ankita Vilas Gawade | cd5b0b7 | 2022-01-20 20:55:04 +0000 | [diff] [blame] | 173 | appendLimit, labeledMetricParams); |
Krzysztof Grobelny | d223819 | 2020-12-02 09:27:28 +0000 | [diff] [blame] | 174 | |
Krzysztof Grobelny | 493e62e | 2022-02-14 10:55:50 +0100 | [diff] [blame] | 175 | reports.emplace_back( |
| 176 | reportFactory->make(id, name, reportingType, reportActions, interval, |
| 177 | appendLimit, reportUpdates, *this, *reportStorage, |
| 178 | labeledMetricParams, enabled, std::move(readings))); |
Krzysztof Grobelny | d223819 | 2020-12-02 09:27:28 +0000 | [diff] [blame] | 179 | return *reports.back(); |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 180 | } |
| 181 | |
| 182 | void ReportManager::loadFromPersistent() |
| 183 | { |
| 184 | std::vector<interfaces::JsonStorage::FilePath> paths = |
| 185 | reportStorage->list(); |
| 186 | |
| 187 | for (const auto& path : paths) |
| 188 | { |
| 189 | std::optional<nlohmann::json> data = reportStorage->load(path); |
| 190 | try |
| 191 | { |
| 192 | size_t version = data->at("Version").get<size_t>(); |
| 193 | if (version != Report::reportVersion) |
| 194 | { |
| 195 | throw std::logic_error("Invalid version"); |
| 196 | } |
Krzysztof Grobelny | b8cc78d | 2021-11-29 15:54:53 +0100 | [diff] [blame] | 197 | bool enabled = data->at("Enabled").get<bool>(); |
| 198 | std::string& id = data->at("Id").get_ref<std::string&>(); |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 199 | std::string& name = data->at("Name").get_ref<std::string&>(); |
Krzysztof Grobelny | 51497a0 | 2021-11-09 14:56:22 +0100 | [diff] [blame] | 200 | |
| 201 | uint32_t reportingType = data->at("ReportingType").get<uint32_t>(); |
| 202 | std::vector<ReportAction> reportActions = utils::transform( |
| 203 | data->at("ReportActions").get<std::vector<uint32_t>>(), |
| 204 | [](const auto reportAction) { |
Patrick Williams | 3a1c297 | 2023-05-10 07:51:04 -0500 | [diff] [blame] | 205 | return utils::toReportAction(reportAction); |
Patrick Williams | c7935fa | 2023-10-20 11:19:30 -0500 | [diff] [blame^] | 206 | }); |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 207 | uint64_t interval = data->at("Interval").get<uint64_t>(); |
Szymon Dompke | 3eb5686 | 2021-09-20 15:32:04 +0200 | [diff] [blame] | 208 | uint64_t appendLimit = data->at("AppendLimit").get<uint64_t>(); |
Krzysztof Grobelny | 51497a0 | 2021-11-09 14:56:22 +0100 | [diff] [blame] | 209 | uint32_t reportUpdates = data->at("ReportUpdates").get<uint32_t>(); |
Krzysztof Grobelny | d223819 | 2020-12-02 09:27:28 +0000 | [diff] [blame] | 210 | auto readingParameters = |
| 211 | data->at("ReadingParameters") |
| 212 | .get<std::vector<LabeledMetricParameters>>(); |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 213 | |
Krzysztof Grobelny | 493e62e | 2022-02-14 10:55:50 +0100 | [diff] [blame] | 214 | Readings readings = {}; |
| 215 | |
| 216 | if (auto it = data->find("MetricValues"); it != data->end()) |
| 217 | { |
| 218 | const auto labeledReadings = it->get<LabeledReadings>(); |
| 219 | readings = utils::toReadings(labeledReadings); |
| 220 | } |
| 221 | |
Krzysztof Grobelny | b8cc78d | 2021-11-29 15:54:53 +0100 | [diff] [blame] | 222 | addReport(id, name, utils::toReportingType(reportingType), |
Krzysztof Grobelny | 51497a0 | 2021-11-09 14:56:22 +0100 | [diff] [blame] | 223 | reportActions, Milliseconds(interval), appendLimit, |
| 224 | utils::toReportUpdates(reportUpdates), |
Krzysztof Grobelny | 493e62e | 2022-02-14 10:55:50 +0100 | [diff] [blame] | 225 | std::move(readingParameters), enabled, |
| 226 | std::move(readings)); |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 227 | } |
| 228 | catch (const std::exception& e) |
| 229 | { |
| 230 | phosphor::logging::log<phosphor::logging::level::ERR>( |
| 231 | "Failed to load report from storage", |
| 232 | phosphor::logging::entry( |
Wludzik, Jozef | 982c5b5 | 2021-01-02 12:05:21 +0100 | [diff] [blame] | 233 | "FILENAME=%s", |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 234 | static_cast<std::filesystem::path>(path).c_str()), |
Wludzik, Jozef | 982c5b5 | 2021-01-02 12:05:21 +0100 | [diff] [blame] | 235 | phosphor::logging::entry("EXCEPTION_MSG=%s", e.what())); |
Wludzik, Jozef | e236279 | 2020-10-27 17:23:55 +0100 | [diff] [blame] | 236 | reportStorage->remove(path); |
| 237 | } |
| 238 | } |
| 239 | } |