Added MetricsServer code, still needs a WinMain.cpp for windows

This commit is contained in:
Anonymous
2014-01-17 06:29:50 -07:00
parent 58b76dd538
commit 7759ffd3c0
11 changed files with 970 additions and 0 deletions
@@ -0,0 +1,45 @@
// ConfigMetricsServer.cpp
// copyright 2000 Verant Interactive
// Author: Justin Randall
//-----------------------------------------------------------------------
#include "FirstMetricsServer.h"
#include "sharedFoundation/ConfigFile.h"
#include "ConfigMetricsServer.h"
//-----------------------------------------------------------------------
ConfigMetricsServer::Data * ConfigMetricsServer::data = 0;
#define KEY_INT(a,b) (data->a = ConfigFile::getKeyInt("MetricsServer", #a, b))
#define KEY_BOOL(a,b) (data->a = ConfigFile::getKeyBool("MetricsServer", #a, b))
#define KEY_REAL(a,b) (data->a = ConfigFile::getKeyReal("MetricsServer", #a, b))
#define KEY_STRING(a,b) (data->a = ConfigFile::getKeyString("MetricsServer", #a, b))
//-----------------------------------------------------------------------
void ConfigMetricsServer::install(void)
{
data = new ConfigMetricsServer::Data;
KEY_STRING(authenticationFileName, "../../exe/shared/metricsAuthentication.cfg");
KEY_STRING(clusterName, "DevCluster");
KEY_INT(metricsListenerPort, 2200);
KEY_INT(metricsServicePort, 44480);
KEY_BOOL(runTestStats, false);
KEY_INT(taskManagerPort, 60001);
KEY_STRING(metricsServiceBindInterface, "");
}
//-----------------------------------------------------------------------
void ConfigMetricsServer::remove(void)
{
delete data;
data = 0;
}
//-----------------------------------------------------------------------