summaryrefslogtreecommitdiffstats
path: root/log_manager.hpp
diff options
context:
space:
mode:
authorAdriana Kobylak <anoo@us.ibm.com>2017-01-06 11:56:41 -0600
committerAdriana Kobylak <anoo@us.ibm.com>2017-01-30 12:57:25 -0600
commitf477fe2945bdbd24817bdc690c17242e30069f4f (patch)
treef93677ed96095e7f622400f75d41dd25778144a0 /log_manager.hpp
parent88d7cf8da4a7213e4f91d3eca35ec6a2fd8f9ca0 (diff)
downloadphosphor-logging-f477fe2945bdbd24817bdc690c17242e30069f4f.tar.gz
phosphor-logging-f477fe2945bdbd24817bdc690c17242e30069f4f.zip
log_manager: Cleanup main function
The design direction changed after the commit that added the log_manager main function, so updating it to the correct usage. Change-Id: I88459fb65ba6b8272f0f9f85b55f9f837487ffea Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
Diffstat (limited to 'log_manager.hpp')
-rw-r--r--log_manager.hpp33
1 files changed, 10 insertions, 23 deletions
diff --git a/log_manager.hpp b/log_manager.hpp
index 2b4281d..13e38d9 100644
--- a/log_manager.hpp
+++ b/log_manager.hpp
@@ -1,6 +1,6 @@
#pragma once
-#include <sdbusplus/server.hpp>
+#include <sdbusplus/bus.hpp>
#include "xyz/openbmc_project/Logging/Internal/Manager/server.hpp"
namespace phosphor
@@ -23,28 +23,22 @@ using ManagerIface =
* @details A concrete implementation for the
* xyz.openbmc_project.Logging.Internal.Manager DBus API.
*/
-class Manager final :
- public details::ServerObject<details::ManagerIface>
+class Manager : public details::ServerObject<details::ManagerIface>
{
public:
Manager() = delete;
Manager(const Manager&) = delete;
Manager& operator=(const Manager&) = delete;
- Manager(Manager&&) = default;
- Manager& operator=(Manager&&) = default;
- ~Manager() = default;
+ Manager(Manager&&) = delete;
+ Manager& operator=(Manager&&) = delete;
+ virtual ~Manager() = default;
- /** @brief Constructor for the Log Manager object
- * @param[in] bus - DBus bus to attach to.
- * @param[in] busname - Name of DBus bus to own.
- * @param[in] obj - Object path to attach to.
+ /** @brief Constructor to put object onto bus at a dbus path.
+ * @param[in] bus - Bus to attach to.
+ * @param[in] path - Path to attach at.
*/
- Manager(sdbusplus::bus::bus&& bus,
- const char* busname,
- const char* obj);
-
- /** @brief Start processing DBus messages. */
- void run() noexcept;
+ Manager(sdbusplus::bus::bus& bus, const char* path) :
+ details::ServerObject<details::ManagerIface>(bus, path) {};
/*
* @fn commit()
@@ -57,13 +51,6 @@ class Manager final :
* error log to be committed.
*/
void commit(uint64_t transactionId, std::string errMsg) override;
-
- private:
- /** @brief Persistent sdbusplus DBus bus connection. */
- sdbusplus::bus::bus _bus;
-
- /** @brief sdbusplus org.freedesktop.DBus.ObjectManager reference. */
- sdbusplus::server::manager::manager _manager;
};
} // namespace logging
OpenPOWER on IntegriCloud