mirror of
https://github.com/pavel-odintsov/fastnetmon
synced 2024-06-08 16:46:06 +02:00
Added conf option to control how often we export traffic to Graphite
This commit is contained in:
parent
419f23200b
commit
79ed5e3548
|
@ -261,6 +261,9 @@ graphite_port = 2003
|
|||
# Default namespace for Graphite data
|
||||
graphite_prefix = fastnetmon
|
||||
|
||||
# How often we export metrics to Graphite
|
||||
graphite_push_period = 1
|
||||
|
||||
# Before using InfluxDB you need to create database using influx tool:
|
||||
# create database fastnetmon
|
||||
|
||||
|
|
|
@ -843,6 +843,10 @@ bool load_configuration_file() {
|
|||
graphite_port = convert_string_to_integer(configuration_map["graphite_port"]);
|
||||
}
|
||||
|
||||
if (configuration_map.count("graphite_push_period") != 0) {
|
||||
graphite_push_period = convert_string_to_integer(configuration_map["graphite_push_period"]);
|
||||
}
|
||||
|
||||
// InfluxDB
|
||||
if (configuration_map.count("influxdb") != 0) {
|
||||
influxdb_enabled = configuration_map["influxdb"] == "on" ? true : false;
|
||||
|
|
Loading…
Reference in New Issue