summaryrefslogtreecommitdiff
path: root/redfish-core/lib/log_services.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'redfish-core/lib/log_services.hpp')
-rw-r--r--redfish-core/lib/log_services.hpp24
1 files changed, 14 insertions, 10 deletions
diff --git a/redfish-core/lib/log_services.hpp b/redfish-core/lib/log_services.hpp
index 074c927d4a..d632552986 100644
--- a/redfish-core/lib/log_services.hpp
+++ b/redfish-core/lib/log_services.hpp
@@ -32,6 +32,7 @@
#include <boost/beast/http.hpp>
#include <boost/container/flat_map.hpp>
#include <boost/system/linux_error.hpp>
+#include <dbus_utility.hpp>
#include <error_messages.hpp>
#include <registries/privilege_registry.hpp>
@@ -102,9 +103,8 @@ static const Message* getMessage(const std::string_view& messageID)
namespace fs = std::filesystem;
-using GetManagedPropertyType = boost::container::flat_map<
- std::string, std::variant<std::string, bool, uint8_t, int16_t, uint16_t,
- int32_t, uint32_t, int64_t, uint64_t, double>>;
+using GetManagedPropertyType =
+ boost::container::flat_map<std::string, dbus::utility::DbusVariantType>;
using GetManagedObjectsType = boost::container::flat_map<
sdbusplus::message::object_path,
@@ -736,8 +736,8 @@ inline void
return task::completed;
}
std::vector<std::pair<
- std::string,
- std::vector<std::pair<std::string, std::variant<std::string>>>>>
+ std::string, std::vector<std::pair<
+ std::string, dbus::utility::DbusVariantType>>>>
interfacesList;
sdbusplus::message::object_path objPath;
@@ -900,7 +900,8 @@ inline void clearDump(const std::shared_ptr<bmcweb::AsyncResp>& asyncResp,
}
inline static void parseCrashdumpParameters(
- const std::vector<std::pair<std::string, VariantType>>& params,
+ const std::vector<std::pair<std::string, dbus::utility::DbusVariantType>>&
+ params,
std::string& filename, std::string& timestamp, std::string& logfile)
{
for (auto property : params)
@@ -1670,7 +1671,7 @@ inline void requestRoutesDBusEventLogEntry(App& app)
"/xyz/openbmc_project/logging/entry/" + entryId,
"org.freedesktop.DBus.Properties", "Set",
"xyz.openbmc_project.Logging.Entry", "Resolved",
- std::variant<bool>(*resolved));
+ dbus::utility::DbusVariantType(*resolved));
});
BMCWEB_ROUTE(
@@ -2638,7 +2639,9 @@ static void
auto getStoredLogCallback =
[asyncResp, logID, &logEntryJson](
const boost::system::error_code ec,
- const std::vector<std::pair<std::string, VariantType>>& params) {
+ const std::vector<
+ std::pair<std::string, dbus::utility::DbusVariantType>>&
+ params) {
if (ec)
{
BMCWEB_LOG_DEBUG << "failed to get log ec: " << ec.message();
@@ -2799,7 +2802,8 @@ inline void requestRoutesCrashdumpFile(App& app)
auto getStoredLogCallback =
[asyncResp, logID, fileName](
const boost::system::error_code ec,
- const std::vector<std::pair<std::string, VariantType>>&
+ const std::vector<std::pair<
+ std::string, dbus::utility::DbusVariantType>>&
resp) {
if (ec)
{
@@ -3318,7 +3322,7 @@ static void
crow::connections::systemBus->async_method_call(
[aResp, entryCount, skip,
top](const boost::system::error_code ec,
- const std::variant<uint16_t>& bootCount) {
+ const dbus::utility::DbusVariantType& bootCount) {
if (ec)
{
BMCWEB_LOG_DEBUG << "DBUS response error " << ec;