Commit abf6af19 authored by Alessio Netti's avatar Alessio Netti
Browse files

Minor refinements

- Boolean configuration options now all accept "true" and "on" keywords
- Cache interval and thread count parameters removed from the command-line
interface for consistency; these can still be set in the config files
like all other parameters
- global.conf file renamed to dcdbpusher.conf for consistency
parent 38bfdf30
...@@ -24,7 +24,7 @@ bool AnalyticsManager::load(const string& path, const string& globalFile, const ...@@ -24,7 +24,7 @@ bool AnalyticsManager::load(const string& path, const string& globalFile, const
try { try {
boost::property_tree::read_info(_configPath + globalFile, cfg); boost::property_tree::read_info(_configPath + globalFile, cfg);
} catch (boost::property_tree::info_parser_error& e) { } catch (boost::property_tree::info_parser_error& e) {
LOG(error) << "Error when reading analyzer plugins from global.conf: " << e.what(); LOG(error) << "Error when reading analyzer plugins from " << globalFile << ": " << e.what();
return false; return false;
} }
...@@ -58,7 +58,7 @@ bool AnalyticsManager::load(const string& path, const string& globalFile, const ...@@ -58,7 +58,7 @@ bool AnalyticsManager::load(const string& path, const string& globalFile, const
} }
} else if (boost::iequals(val.first, "config")) { } else if (boost::iequals(val.first, "config")) {
pluginConfig = val.second.data(); pluginConfig = val.second.data();
// If config-path not specified we will look for pluginName.conf in the global.conf directory // If config-path not specified we will look for pluginName.conf in the global conf directory
if (pluginConfig == "") if (pluginConfig == "")
pluginConfig = _configPath + plugin.second.data() + ".conf"; pluginConfig = _configPath + plugin.second.data() + ".conf";
} else { } else {
......
...@@ -318,13 +318,13 @@ protected: ...@@ -318,13 +318,13 @@ protected:
} else if (boost::iequals(val.first, "mqttPart")) { } else if (boost::iequals(val.first, "mqttPart")) {
an.setMqttPart(val.second.data()); an.setMqttPart(val.second.data());
} else if (boost::iequals(val.first, "sync")) { } else if (boost::iequals(val.first, "sync")) {
an.setSync(val.second.data() == "true"); an.setSync(to_bool(val.second.data()));
} else if (boost::iequals(val.first, "delay")) { } else if (boost::iequals(val.first, "delay")) {
an.setDelayInterval(stoull(val.second.data()) / 1000); an.setDelayInterval(stoull(val.second.data()) / 1000);
} else if (boost::iequals(val.first, "duplicate")) { } else if (boost::iequals(val.first, "duplicate")) {
an.setDuplicate(val.second.data() == "true"); an.setDuplicate(to_bool(val.second.data()));
} else if (boost::iequals(val.first, "streaming")) { } else if (boost::iequals(val.first, "streaming")) {
an.setStreaming(val.second.data() == "true"); an.setStreaming(to_bool(val.second.data()));
} else if (boost::iequals(val.first, INPUT_BLOCK) || boost::iequals(val.first, OUTPUT_BLOCK)) { } else if (boost::iequals(val.first, INPUT_BLOCK) || boost::iequals(val.first, OUTPUT_BLOCK)) {
// Instantiating all sensors contained within the "input" or "output" block // Instantiating all sensors contained within the "input" or "output" block
BOOST_FOREACH(boost::property_tree::iptree::value_type &valInner, val.second) BOOST_FOREACH(boost::property_tree::iptree::value_type &valInner, val.second)
...@@ -416,9 +416,9 @@ protected: ...@@ -416,9 +416,9 @@ protected:
if (boost::iequals(val.first, "mqttsuffix")) { if (boost::iequals(val.first, "mqttsuffix")) {
sBase.setMqtt(val.second.data()); sBase.setMqtt(val.second.data());
} else if (boost::iequals(val.first, "skipConstVal")) { } else if (boost::iequals(val.first, "skipConstVal")) {
sBase.setSkipConstVal( val.second.data() == "true" ); sBase.setSkipConstVal(to_bool(val.second.data()));
} else if (boost::iequals(val.first, "delta")) { } else if (boost::iequals(val.first, "delta")) {
sBase.setDelta( val.second.data() == "true" ); sBase.setDelta(to_bool(val.second.data()));
} else if (boost::iequals(val.first, "sink")) { } else if (boost::iequals(val.first, "sink")) {
sBase.setSinkPath( val.second.data() ); sBase.setSinkPath( val.second.data() );
} else if (boost::iequals(val.first, "subSampling")) { } else if (boost::iequals(val.first, "subSampling")) {
......
...@@ -244,7 +244,7 @@ void usage() { ...@@ -244,7 +244,7 @@ void usage() {
012345678901234567890123456789012345678901234567890123456789012345678901234567890 012345678901234567890123456789012345678901234567890123456789012345678901234567890
*/ */
cout << "Usage:" << endl; cout << "Usage:" << endl;
cout << " collectagent [-m<host>] [-r<host>] [-c<host>] [-C<interval>] [-u<username>] [-p<password>] [-t<ttl>] [-v<verbosity>] [-d] [-s] <path/to/configfiles/>" << endl; cout << " collectagent [-d] [-s] [-m<host>] [-r<host>] [-c<host>] [-u<username>] [-p<password>] [-t<ttl>] [-v<verbosity>] <path/to/configfiles/>" << endl;
cout << " collectagent -h" << endl; cout << " collectagent -h" << endl;
cout << endl; cout << endl;
...@@ -252,7 +252,6 @@ void usage() { ...@@ -252,7 +252,6 @@ void usage() {
cout << " -m<host> MQTT listen address [default: " << defaults.mqttListenAddress << "]" << endl; cout << " -m<host> MQTT listen address [default: " << defaults.mqttListenAddress << "]" << endl;
cout << " -r<host> REST API listen address [default: " << defaults.restListenAddress << "]" << endl; cout << " -r<host> REST API listen address [default: " << defaults.restListenAddress << "]" << endl;
cout << " -c<host> Cassandra host [default: " << defaults.cassandraSettings.address << "]" << endl; cout << " -c<host> Cassandra host [default: " << defaults.cassandraSettings.address << "]" << endl;
cout << " -C<interval> Cache interval in [s] [default: " << defaults.cacheInterval << "]" << endl;
cout << " -u<username> Cassandra username [default: none]" << endl; cout << " -u<username> Cassandra username [default: none]" << endl;
cout << " -p<password> Cassandra password [default: none]" << endl; cout << " -p<password> Cassandra password [default: none]" << endl;
cout << " -t<ttl> Cassandra insert TTL [default: " << defaults.cassandraSettings.ttl << "]" << endl; cout << " -t<ttl> Cassandra insert TTL [default: " << defaults.cassandraSettings.ttl << "]" << endl;
...@@ -322,9 +321,6 @@ int main(int argc, char* const argv[]) { ...@@ -322,9 +321,6 @@ int main(int argc, char* const argv[]) {
case 'c': case 'c':
settings.cassandraSettings.address = optarg; settings.cassandraSettings.address = optarg;
break; break;
case 'C':
settings.cacheInterval = stoul(optarg);
break;
case 'u': case 'u':
settings.cassandraSettings.username = optarg; settings.cassandraSettings.username = optarg;
break; break;
......
...@@ -73,9 +73,9 @@ bool Configuration::readGlobal() { ...@@ -73,9 +73,9 @@ bool Configuration::readGlobal() {
_global.tempDir.append("/"); _global.tempDir.append("/");
} }
} else if (boost::iequals(global.first, "daemonize")) { } else if (boost::iequals(global.first, "daemonize")) {
_global.daemonize = global.second.data() == "true"; _global.daemonize = to_bool(global.second.data());
} else if (boost::iequals(global.first, "statistics")) { } else if (boost::iequals(global.first, "statistics")) {
_global.statistics = global.second.data() == "true"; _global.statistics = to_bool(global.second.data());
} else { } else {
LOG(warning) << " Value \"" << global.first << "\" not recognized. Omitting"; LOG(warning) << " Value \"" << global.first << "\" not recognized. Omitting";
} }
...@@ -102,7 +102,7 @@ bool Configuration::readGlobal() { ...@@ -102,7 +102,7 @@ bool Configuration::readGlobal() {
} else if (boost::iequals(global.first, "maxConcRequests")) { } else if (boost::iequals(global.first, "maxConcRequests")) {
_global.cassandraSettings.maxConcRequests = stoul(global.second.data()); _global.cassandraSettings.maxConcRequests = stoul(global.second.data());
} else if (boost::iequals(global.first, "debugLog")) { } else if (boost::iequals(global.first, "debugLog")) {
_global.cassandraSettings.debugLog = global.second.data() == "true"; _global.cassandraSettings.debugLog = to_bool(global.second.data());
} else { } else {
LOG(warning) << " Value \"" << global.first << "\" not recognized. Omitting"; LOG(warning) << " Value \"" << global.first << "\" not recognized. Omitting";
} }
......
...@@ -14,6 +14,7 @@ ...@@ -14,6 +14,7 @@
#include <boost/algorithm/string.hpp> #include <boost/algorithm/string.hpp>
#include "logging.h" #include "logging.h"
#include "pluginsettings.h"
#define LISTENHOST "localhost" #define LISTENHOST "localhost"
#define LISTENPORT "1883" #define LISTENPORT "1883"
......
...@@ -12,4 +12,6 @@ typedef struct { ...@@ -12,4 +12,6 @@ typedef struct {
unsigned int cacheInterval; unsigned int cacheInterval;
} pluginSettings_t; } pluginSettings_t;
static bool to_bool(const std::string& s) { return s=="true" || s=="on"; }
#endif //PROJECT_PLUGINSETTINGS_H #endif //PROJECT_PLUGINSETTINGS_H
...@@ -26,7 +26,7 @@ Configuration::Configuration(const std::string& cfgFilePath) : ...@@ -26,7 +26,7 @@ Configuration::Configuration(const std::string& cfgFilePath) :
//set default values for global variables //set default values for global variables
_global.validateConfig = false; _global.validateConfig = false;
_global.qosLevel = 1; _global.qosLevel = 1;
_global.daemonize = 0; _global.daemonize = false;
_global.hierarchy = ""; _global.hierarchy = "";
_global.brokerHost = ""; _global.brokerHost = "";
_global.brokerPort = 1883; _global.brokerPort = 1883;
...@@ -61,14 +61,14 @@ Configuration::~Configuration() { ...@@ -61,14 +61,14 @@ Configuration::~Configuration() {
bool Configuration::readGlobal() { bool Configuration::readGlobal() {
//open file //open file
std::string globalConfig = _cfgFilePath; std::string globalConfig = _cfgFilePath;
globalConfig.append("global.conf"); globalConfig.append("dcdbpusher.conf");
boost::property_tree::iptree cfg; boost::property_tree::iptree cfg;
//parse to property_tree //parse to property_tree
try { try {
boost::property_tree::read_info(globalConfig, cfg); boost::property_tree::read_info(globalConfig, cfg);
} catch (boost::property_tree::info_parser_error& e) { } catch (boost::property_tree::info_parser_error& e) {
LOG(error) << "Error when reading global.conf: " << e.what(); LOG(error) << "Error when reading dcdbpusher.conf: " << e.what();
return false; return false;
} }
...@@ -108,13 +108,9 @@ bool Configuration::readGlobal() { ...@@ -108,13 +108,9 @@ bool Configuration::readGlobal() {
} else if (boost::iequals(global.first, "maxMsgNum")) { } else if (boost::iequals(global.first, "maxMsgNum")) {
_global.maxMsgNum = stoi(global.second.data()); _global.maxMsgNum = stoi(global.second.data());
} else if (boost::iequals(global.first, "daemonize")) { } else if (boost::iequals(global.first, "daemonize")) {
if (global.second.data() == "true") { _global.daemonize = to_bool(global.second.data());
_global.daemonize = 1;
}
} else if (boost::iequals(global.first, "validateConfig")) { } else if (boost::iequals(global.first, "validateConfig")) {
if (global.second.data() == "true") { _global.validateConfig = to_bool(global.second.data());
_global.validateConfig = true;
}
} else if (boost::iequals(global.first, "verbosity")) { } else if (boost::iequals(global.first, "verbosity")) {
_global.logLevelFile = translateLogLevel(stoi(global.second.data())); _global.logLevelFile = translateLogLevel(stoi(global.second.data()));
} else if (boost::iequals(global.first, "cacheInterval")) { } else if (boost::iequals(global.first, "cacheInterval")) {
...@@ -153,14 +149,14 @@ bool Configuration::readGlobal() { ...@@ -153,14 +149,14 @@ bool Configuration::readGlobal() {
bool Configuration::readAuthkeys(HttpsServer* server) { bool Configuration::readAuthkeys(HttpsServer* server) {
//open file //open file
std::string globalConfig = _cfgFilePath; std::string globalConfig = _cfgFilePath;
globalConfig.append("global.conf"); globalConfig.append("dcdbpusher.conf");
boost::property_tree::iptree cfg; boost::property_tree::iptree cfg;
//parse to property_tree //parse to property_tree
try { try {
boost::property_tree::read_info(globalConfig, cfg); boost::property_tree::read_info(globalConfig, cfg);
} catch (boost::property_tree::info_parser_error& e) { } catch (boost::property_tree::info_parser_error& e) {
LOG(error) << "Error when reading authkeys from global.conf: " << e.what(); LOG(error) << "Error when reading authkeys from dcdbpusher.conf: " << e.what();
return false; return false;
} }
...@@ -202,13 +198,13 @@ bool Configuration::readAuthkeys(HttpsServer* server) { ...@@ -202,13 +198,13 @@ bool Configuration::readAuthkeys(HttpsServer* server) {
bool Configuration::readPlugins() { bool Configuration::readPlugins() {
std::string globalConfig = _cfgFilePath; std::string globalConfig = _cfgFilePath;
globalConfig.append("global.conf"); globalConfig.append("dcdbpusher.conf");
boost::property_tree::iptree cfg; boost::property_tree::iptree cfg;
try { try {
boost::property_tree::read_info(globalConfig, cfg); boost::property_tree::read_info(globalConfig, cfg);
} catch (boost::property_tree::info_parser_error& e) { } catch (boost::property_tree::info_parser_error& e) {
LOG(error) << "Error when reading plugins from global.conf: " << e.what(); LOG(error) << "Error when reading plugins from dcdbpusher.conf: " << e.what();
return false; return false;
} }
...@@ -238,7 +234,7 @@ bool Configuration::readPlugins() { ...@@ -238,7 +234,7 @@ bool Configuration::readPlugins() {
} }
} else if (boost::iequals(val.first, "config")) { } else if (boost::iequals(val.first, "config")) {
pluginConfig = val.second.data(); pluginConfig = val.second.data();
//if config-path not specified we will look for pluginName.conf in the global.conf directory //if config-path not specified we will look for pluginName.conf in the dcdbpusher.conf directory
if (pluginConfig == "") { if (pluginConfig == "") {
pluginConfig = _cfgFilePath + plugin.second.data() + ".conf"; pluginConfig = _cfgFilePath + plugin.second.data() + ".conf";
} }
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
typedef struct { typedef struct {
bool validateConfig; bool validateConfig;
int daemonize; bool daemonize;
int brokerPort; int brokerPort;
int qosLevel; int qosLevel;
unsigned int maxInflightMsgNum; unsigned int maxInflightMsgNum;
......
...@@ -19,19 +19,19 @@ mqttStart 00 ...@@ -19,19 +19,19 @@ mqttStart 00
metric MemFree { metric MemFree {
type MemFree type MemFree
mqttsuffix 36 mqttsuffix 36
skipConstVal on skipConstVal true
} }
metric AnonPages { metric AnonPages {
type AnonPages type AnonPages
mqttsuffix AA mqttsuffix AA
skipConstVal on skipConstVal true
} }
metric Hugepagesize { metric Hugepagesize {
type Hugepagesize type Hugepagesize
mqttsuffix BB mqttsuffix BB
skipConstVal on skipConstVal true
} }
} }
...@@ -46,19 +46,19 @@ mqttStart 00 ...@@ -46,19 +46,19 @@ mqttStart 00
metric nr_dirty_threshold { metric nr_dirty_threshold {
type nr_dirty_threshold type nr_dirty_threshold
mqttsuffix F0 mqttsuffix F0
skipConstVal on skipConstVal true
} }
metric nr_file_pages { metric nr_file_pages {
type nr_file_pages type nr_file_pages
mqttsuffix F1 mqttsuffix F1
skipConstVal on skipConstVal true
} }
metric nr_alloc_batch { metric nr_alloc_batch {
type nr_alloc_batch type nr_alloc_batch
mqttsuffix F2 mqttsuffix F2
skipConstVal on skipConstVal true
} }
} }
...@@ -74,29 +74,29 @@ cpus 250,36 ...@@ -74,29 +74,29 @@ cpus 250,36
metric col_idle { metric col_idle {
type col_idle type col_idle
mqttsuffix 36 mqttsuffix 36
skipConstVal on skipConstVal true
perCpu on perCpu true
} }
metric col_user { metric col_user {
type col_user type col_user
mqttsuffix 37 mqttsuffix 37
skipConstVal on skipConstVal true
perCpu on perCpu true
} }
metric col_nice { metric col_nice {
type col_nice type col_nice
mqttsuffix 38 mqttsuffix 38
skipConstVal on skipConstVal true
perCpu off perCpu false
} }
metric ctxt { metric ctxt {
type ctxt type ctxt
mqttsuffix 40 mqttsuffix 40
skipConstVal on skipConstVal true
perCpu off perCpu false
} }
} }
...@@ -29,7 +29,7 @@ group temp { ...@@ -29,7 +29,7 @@ group temp {
path /sys/devices/virtual/thermal/thermal_zone1/temp path /sys/devices/virtual/thermal/thermal_zone1/temp
sensor temp1 { sensor temp1 {
skipConstVal on skipConstVal true
mqttsuffix 01 mqttsuffix 01
} }
} }
......
...@@ -121,7 +121,7 @@ void printSyntax() ...@@ -121,7 +121,7 @@ void printSyntax()
_configuration = new Configuration(""); _configuration = new Configuration("");
global_t& globalSettings = _configuration->getGlobal(); global_t& globalSettings = _configuration->getGlobal();
cout << "Usage:" << endl; cout << "Usage:" << endl;
cout << " dcdbpusher [-d] [-x] [-a<string>] [-b<host>] [-p<port>] [-m<string>] [-t<number>] <path/to/configfiles/>" << endl; cout << " dcdbpusher [-d] [-x] [-a<string>] [-b<host>] [-p<port>] [-m<string>] [-w<path>] [-v<level>] <path/to/configfiles/>" << endl;
cout << " dcdbpusher -h" << endl; cout << " dcdbpusher -h" << endl;
cout << endl; cout << endl;
...@@ -130,9 +130,7 @@ void printSyntax() ...@@ -130,9 +130,7 @@ void printSyntax()
cout << " -b <host> MQTT broker [default: none]" << endl; cout << " -b <host> MQTT broker [default: none]" << endl;
cout << " -p <port> MQTT broker port [default: " << globalSettings.brokerPort << "]" << endl; cout << " -p <port> MQTT broker port [default: " << globalSettings.brokerPort << "]" << endl;
cout << " -m <string> MQTT topic prefix [default: none]" << endl; cout << " -m <string> MQTT topic prefix [default: none]" << endl;
cout << " -t <number> Thread count [default: " << globalSettings.threads << "]" << endl;
cout << " -w <path> Writable temp dir [default: .]" << endl; cout << " -w <path> Writable temp dir [default: .]" << endl;
cout << " -c <sec> Cache interval in [s] [default: " << globalSettings.pluginSettings.cacheInterval / 1000 << "]" << endl;
cout << " -v <level> Set verbosity of output [default: " << globalSettings.logLevelCmd << "]" << endl cout << " -v <level> Set verbosity of output [default: " << globalSettings.logLevelCmd << "]" << endl
<< " Can be a number between 5 (all) and 0 (fatal)." << endl; << " Can be a number between 5 (all) and 0 (fatal)." << endl;
cout << endl; cout << endl;
...@@ -157,7 +155,7 @@ int main(int argc, char** argv) { ...@@ -157,7 +155,7 @@ int main(int argc, char** argv) {
} }
//define allowed command-line options once //define allowed command-line options once
const char opts[] = "a:b:p:m:t:v:w:c:dxh"; const char opts[] = "a:b:p:m:v:w:dxh";
//check if help flag specified //check if help flag specified
char c; char c;
...@@ -199,7 +197,7 @@ int main(int argc, char** argv) { ...@@ -199,7 +197,7 @@ int main(int argc, char** argv) {
//reset getopt() //reset getopt()
optind = 1; optind = 1;
//read in options (overwrite global.conf settings if necessary) //read in options (overwrite dcdbpusher.conf settings if necessary)
while ((c = getopt(argc, argv, opts)) != -1) { while ((c = getopt(argc, argv, opts)) != -1) {
switch (c) switch (c)
{ {
...@@ -215,9 +213,6 @@ int main(int argc, char** argv) { ...@@ -215,9 +213,6 @@ int main(int argc, char** argv) {
case 'm': case 'm':
pluginSettings.mqttPrefix = optarg; pluginSettings.mqttPrefix = optarg;
break; break;
case 't':
globalSettings.threads = stoul(optarg);
break;
case 'v': case 'v':
globalSettings.logLevelCmd = _configuration->translateLogLevel(stoi(optarg)); globalSettings.logLevelCmd = _configuration->translateLogLevel(stoi(optarg));
break; break;
...@@ -233,9 +228,6 @@ int main(int argc, char** argv) { ...@@ -233,9 +228,6 @@ int main(int argc, char** argv) {
pluginSettings.tempdir.append("/"); pluginSettings.tempdir.append("/");
} }
break; break;
case 'c':
pluginSettings.cacheInterval = stoul(optarg) * 1000;
break;
case 'h': case 'h':
printSyntax(); printSyntax();
return 1; return 1;
...@@ -274,11 +266,7 @@ int main(int argc, char** argv) { ...@@ -274,11 +266,7 @@ int main(int argc, char** argv) {
LOG(info) << "Global Settings:"; LOG(info) << "Global Settings:";
LOG(info) << " Broker: " << globalSettings.brokerHost << ":" << globalSettings.brokerPort; LOG(info) << " Broker: " << globalSettings.brokerHost << ":" << globalSettings.brokerPort;
LOG(info) << " Threads: " << globalSettings.threads; LOG(info) << " Threads: " << globalSettings.threads;
if(globalSettings.daemonize) { LOG(info) << " Daemonize: " << (globalSettings.daemonize ? "Enabled" : "Disabled");
LOG(info) << " Daemonize: Enabled";
} else {
LOG(info) << " Daemonize: Disabled";
}
LOG(info) << " MaxMsgNum: " << globalSettings.maxMsgNum; LOG(info) << " MaxMsgNum: " << globalSettings.maxMsgNum;
LOG(info) << " MaxInflightMsgNum: " << globalSettings.maxInflightMsgNum; LOG(info) << " MaxInflightMsgNum: " << globalSettings.maxInflightMsgNum;
LOG(info) << " MaxQueuedMsgNum: " << globalSettings.maxQueuedMsgNum; LOG(info) << " MaxQueuedMsgNum: " << globalSettings.maxQueuedMsgNum;
...@@ -363,7 +351,7 @@ int main(int argc, char** argv) { ...@@ -363,7 +351,7 @@ int main(int argc, char** argv) {
_queryEngine.triggerUpdate(); _queryEngine.triggerUpdate();
_queryEngine.setQueryCallback(sensorQueryCallback); _queryEngine.setQueryCallback(sensorQueryCallback);
if(!_analyticsManager->load(argv[argc-1], "global.conf", pluginSettings)) { if(!_analyticsManager->load(argv[argc-1], "dcdbpusher.conf", pluginSettings)) {
LOG(fatal) << "Failed to load data analytics manager!"; LOG(fatal) << "Failed to load data analytics manager!";
return 1; return 1;
} }
......
...@@ -405,17 +405,13 @@ protected: ...@@ -405,17 +405,13 @@ protected:
if (boost::iequals(val.first, "mqttsuffix")) { if (boost::iequals(val.first, "mqttsuffix")) {
sBase.setMqtt(val.second.data()); sBase.setMqtt(val.second.data());
} else if (boost::iequals(val.first, "skipConstVal")) { } else if (boost::iequals(val.first, "skipConstVal")) {
if (val.second.data() == "on") { sBase.setSkipConstVal(to_bool(val.second.data()));
sBase.setSkipConstVal(true);
} else {
sBase.setSkipConstVal(false);
}
} else if (boost::iequals(val.first, "delta")) { } else if (boost::iequals(val.first, "delta")) {
sBase.setDelta( val.second.data() == "on" ); sBase.setDelta(to_bool(val.second.data()));
} else if (boost::iequals(val.first, "sink")) { } else if (boost::iequals(val.first, "sink")) {
sBase.setSinkPath( val.second.data() ); sBase.setSinkPath( val.second.data() );
} else if (boost::iequals(val.first, "subSampling")) { } else if (boost::iequals(val.first, "subSampling")) {
sBase.setSubsampling( std::stoul(val.second.data()) ); sBase.setSubsampling(std::stoul(val.second.data()));
} }
} }
sensorBase(sBase, config); sensorBase(sBase, config);
......
...@@ -75,9 +75,6 @@ bool ProcfsConfigurator::readConfig(std::string cfgPath) { ...@@ -75,9 +75,6 @@ bool ProcfsConfigurator::readConfig(std::string cfgPath) {
}