mgmt: added FaceManager to create and destroy faces
Change-Id: I5a7ca67faed1bfd850943fe4c93675d84c79ac39
Refs: #1195
diff --git a/daemon/main.cpp b/daemon/main.cpp
index bd511bb..d9867fe 100644
--- a/daemon/main.cpp
+++ b/daemon/main.cpp
@@ -9,6 +9,7 @@
#include "fw/forwarder.hpp"
#include "mgmt/internal-face.hpp"
#include "mgmt/fib-manager.hpp"
+#include "mgmt/face-manager.hpp"
#include "mgmt/local-control-header-manager.hpp"
#include "face/tcp-factory.hpp"
@@ -42,6 +43,7 @@
static ProgramOptions g_options;
static Forwarder* g_forwarder;
static FibManager* g_fibManager;
+static FaceManager* g_faceManager;
static LocalControlHeaderManager* g_localControlHeaderManager;
static TcpFactory* g_tcpFactory;
static shared_ptr<TcpChannel> g_tcpChannel;
@@ -209,6 +211,8 @@
bind(&Forwarder::getFace, g_forwarder, _1),
g_internalFace);
+ g_faceManager = new FaceManager(g_forwarder->getFaceTable(), g_internalFace);
+
g_localControlHeaderManager =
new LocalControlHeaderManager(bind(&Forwarder::getFace, g_forwarder, _1),
g_internalFace);