summaryrefslogtreecommitdiff
path: root/include/persistent_data.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'include/persistent_data.hpp')
-rw-r--r--include/persistent_data.hpp39
1 files changed, 18 insertions, 21 deletions
diff --git a/include/persistent_data.hpp b/include/persistent_data.hpp
index a08ca7e086..5079a8c151 100644
--- a/include/persistent_data.hpp
+++ b/include/persistent_data.hpp
@@ -57,8 +57,7 @@ class ConfigFile
auto data = nlohmann::json::parse(persistentFile, nullptr, false);
if (data.is_discarded())
{
- BMCWEB_LOG_ERROR
- << "Error parsing persistent data in json file.";
+ BMCWEB_LOG_ERROR("Error parsing persistent data in json file.");
}
else
{
@@ -72,7 +71,7 @@ class ConfigFile
item.value().get_ptr<const uint64_t*>();
if (uintPtr == nullptr)
{
- BMCWEB_LOG_ERROR << "Failed to read revision flag";
+ BMCWEB_LOG_ERROR("Failed to read revision flag");
}
else
{
@@ -103,15 +102,15 @@ class ConfigFile
if (newSession == nullptr)
{
- BMCWEB_LOG_ERROR << "Problem reading session "
- "from persistent store";
+ BMCWEB_LOG_ERROR("Problem reading session "
+ "from persistent store");
continue;
}
- BMCWEB_LOG_DEBUG
- << "Restored session: " << newSession->csrfToken
- << " " << newSession->uniqueId << " "
- << newSession->sessionToken;
+ BMCWEB_LOG_DEBUG("Restored session: {} {} {}",
+ newSession->csrfToken,
+ newSession->uniqueId,
+ newSession->sessionToken);
SessionStore::getInstance().authTokens.emplace(
newSession->sessionToken, newSession);
}
@@ -122,13 +121,13 @@ class ConfigFile
item.value().get_ptr<int64_t*>();
if (jTimeout == nullptr)
{
- BMCWEB_LOG_DEBUG
- << "Problem reading session timeout value";
+ BMCWEB_LOG_DEBUG(
+ "Problem reading session timeout value");
continue;
}
std::chrono::seconds sessionTimeoutInseconds(*jTimeout);
- BMCWEB_LOG_DEBUG << "Restored Session Timeout: "
- << sessionTimeoutInseconds.count();
+ BMCWEB_LOG_DEBUG("Restored Session Timeout: {}",
+ sessionTimeoutInseconds.count());
SessionStore::getInstance().updateSessionTimeout(
sessionTimeoutInseconds);
}
@@ -147,15 +146,14 @@ class ConfigFile
if (newSubscription == nullptr)
{
- BMCWEB_LOG_ERROR
- << "Problem reading subscription "
- "from persistent store";
+ BMCWEB_LOG_ERROR("Problem reading subscription "
+ "from persistent store");
continue;
}
- BMCWEB_LOG_DEBUG << "Restored subscription: "
- << newSubscription->id << " "
- << newSubscription->customText;
+ BMCWEB_LOG_DEBUG("Restored subscription: {} {}",
+ newSubscription->id,
+ newSubscription->customText);
EventServiceStore::getInstance()
.subscriptionsConfigMap.emplace(
newSubscription->id, newSubscription);
@@ -251,8 +249,7 @@ class ConfigFile
std::shared_ptr<UserSubscription> subValue = it.second;
if (subValue->subscriptionType == "SSE")
{
- BMCWEB_LOG_DEBUG
- << "The subscription type is SSE, so skipping.";
+ BMCWEB_LOG_DEBUG("The subscription type is SSE, so skipping.");
continue;
}
nlohmann::json::object_t headers;