summaryrefslogtreecommitdiffstats
path: root/src/Core/ConnectionManager.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/Core/ConnectionManager.h')
-rw-r--r--src/Core/ConnectionManager.h13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/Core/ConnectionManager.h b/src/Core/ConnectionManager.h
index fdc8a46..4623ab6 100644
--- a/src/Core/ConnectionManager.h
+++ b/src/Core/ConnectionManager.h
@@ -29,7 +29,6 @@
#include <Common/HostInfo.h>
#include <Common/Initializable.h>
#include <Common/RequestManager.h>
-#include <Common/SingletonPtr.h>
#include <Net/IPAddress.h>
@@ -46,7 +45,7 @@ namespace Core {
class ConnectionManager : public Common::Configurable, public Common::Initializable {
private:
- static Common::SingletonPtr<ConnectionManager> connectionManager;
+ static ConnectionManager connectionManager;
std::string x509TrustFile, x509CrlFile, x509CertFile, x509KeyFile;
@@ -67,16 +66,18 @@ class ConnectionManager : public Common::Configurable, public Common::Initializa
void updateState(const std::string &name, Common::HostInfo::State state);
+ ConnectionManager() {}
+
protected:
virtual bool handleConfigEntry(const Common::ConfigEntry &entry, bool handled);
virtual void configFinished();
- public:
- ConnectionManager();
- virtual ~ConnectionManager();
+ virtual void doInit();
+ virtual void doDeinit();
+ public:
static ConnectionManager* get() {
- return connectionManager.get();
+ return &connectionManager;
}
void run();