entry: use map for metadata in ctor
Transition the entry constructor to use the `map<string,string>`
rather than the `vector<string>`.
Tested: UTs pass and daemon still creates logs.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: Icf3ead163cc99a1498734d33335fb6da52e6c98c
diff --git a/elog_entry.hpp b/elog_entry.hpp
index 4290a50..ccb69a3 100644
--- a/elog_entry.hpp
+++ b/elog_entry.hpp
@@ -65,7 +65,7 @@
*/
Entry(sdbusplus::bus_t& bus, const std::string& objectPath, uint32_t idErr,
uint64_t timestampErr, Level severityErr, std::string&& msgErr,
- std::vector<std::string>&& additionalDataErr,
+ std::map<std::string, std::string>&& additionalDataErr,
AssociationList&& objects, const std::string& fwVersion,
const std::string& filePath, internal::Manager& parent) :
EntryIfaces(bus, objectPath.c_str(), EntryIfaces::action::defer_emit),
@@ -76,8 +76,8 @@
timestamp(timestampErr, true);
updateTimestamp(timestampErr, true);
message(std::move(msgErr), true);
- additionalData(std::move(additionalDataErr), true);
- additionalData2(util::additional_data::parse(additionalData()), true);
+ additionalData2(std::move(additionalDataErr), true);
+ additionalData(util::additional_data::combine(additionalData2()), true);
associations(std::move(objects), true);
// Store a copy of associations in case we need to recreate
assocs = associations();