Commit 2c84b7a8 authored by Alessio Netti's avatar Alessio Netti
Browse files

Grafana: minor changes to configuration, verbosity and termination

parent 531b0a54
......@@ -79,15 +79,14 @@ void sigHandler(int sig) {
//Stop io service by killing keepAliveWork
keepAliveWork.reset();
//Stop the Cassandra connection.
LOG(info) << "Closing Cassandra connection...";
_cassandraConnection->disconnect();
//Stop https server
LOG(info) << "Stopping REST API Server...";
_httpsServer->stop();
//Stop the Cassandra connection.
LOG(info) << "Closing Cassandra connection...";
_cassandraConnection->disconnect();
}
......@@ -216,15 +215,22 @@ int main(int argc, char *argv[])
LOG(info) << " Write-Dir: " << globalSettings.tempdir;
LOG(info) << "Grafana Settings:";
LOG(info) << " Grafana Server: " << restAPISettings.host << ":" << restAPISettings.port;
LOG(info) << " Certificate: " << restAPISettings.certificate;
LOG(info) << " Private key file: " << restAPISettings.privateKey;
LOG(info) << " Grafana Server: " << restAPISettings.host << ":" << restAPISettings.port;
LOG(info) << " Certificate: " << restAPISettings.certificate;
LOG(info) << " Private key file: " << restAPISettings.privateKey;
LOG(info) << "Cassandra Settings:";
LOG(info) << " Cassandra Server: " << cassandraSettings.host << ":" << cassandraSettings.port;
LOG(info) << " Address: " << cassandraSettings.host << ":" << cassandraSettings.port;
LOG(info) << " NumThreadsIO: " << cassandraSettings.numThreadsIo;
LOG(info) << " QueueSizeIO: " << cassandraSettings.queueSizeIo;
LOG(info) << " CoreConnPerHost: " << cassandraSettings.coreConnPerHost;
LOG(info) << " DebugLog: " << (cassandraSettings.debugLog ? "Enabled" : "Disabled");
LOG(info) << "Hierarchy Settings:";
LOG(info) << " Regex: " << (hierarchySettings.regex != "" ? hierarchySettings.regex : "none");
LOG(info) << " Separator: " << (hierarchySettings.separator != "" ? hierarchySettings.separator : "none");
LOG(info) << " Regex: " << (hierarchySettings.regex != "" ? hierarchySettings.regex : "none");
LOG(info) << " Separator: " << (hierarchySettings.separator != "" ? hierarchySettings.separator : "none");
LOG(info) << " Filter: " << (hierarchySettings.filter!="" ? hierarchySettings.filter : "none");
LOG(info) << " Smoother Regex: " << (hierarchySettings.smootherRegex!="" ? hierarchySettings.smootherRegex : "none");
LOG_VAR(vLogLevel) << "----- End Configuration -----";
......@@ -295,7 +301,6 @@ int main(int argc, char *argv[])
threads.join_all();
//will only continue if interrupted by SIGINT and threads were stopped
LOG(info) << "Tearing down objects...";
delete _cassandraConnection;
delete _httpsServer;
......
......@@ -240,6 +240,7 @@ void RestAPI::POST_query(endpointArgs) {
}
}
}
//LOG(debug) << "Picking smoother " << bestSmoother << " for sensor " << sensorName << ".";
}
}
......
global {
threads 1
threads 10
verbosity 3
daemonize false
tempdir .
......@@ -10,9 +10,9 @@ cassandra {
}
hierarchy {
smootherRegex "-avg"
}
restAPI {
address 127.0.0.1:8081
certificate ../../deps/openssl-1.1.1c/test/certs/ca-cert.pem
......@@ -20,8 +20,8 @@ restAPI {
dhFile ../../deps/openssl-1.1.1c/crypto/dh/dh2048.pem
user user1 {
password f0578f1e7174b1a41c4ea8c6e17f7a8a3b88c92a
user admin {
password d033e22ae348aeb5660fc2140aec35850c4da997
POST
GET
PUT
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment