renamed configuration flag

This commit is contained in:
Annika Hannig 2024-11-20 14:13:01 +01:00
parent bca0f75c46
commit c33bf96597
2 changed files with 6 additions and 6 deletions

View File

@ -53,11 +53,11 @@ routes_store_query_limit = 200000
# parsing a master4 table will take about 2.5 instead of 1.25 minutes.
stream_parser_throttle = 10000
# Enable prometheus metrics endpoint
# When `enable_prometheus` is set to `true`, Alice will export metrics
# on `/metrics` in Prometheus format.
# Enable metrics endpoint
# When `enable_metrics` is set to `true`, Alice will export metrics
# on `/metrics` in Prometheus (openmetrics) format.
# Default: false
enable_prometheus = false
enable_metrics = false
# [postgres]
# url = "postgres://postgres:postgres@localhost:5432/alice"

View File

@ -96,7 +96,7 @@ type ServerConfig struct {
DefaultAsn int `ini:"asn"`
EnableNeighborsStatusRefresh bool `ini:"enable_neighbors_status_refresh"`
StreamParserThrottle int `ini:"stream_parser_throttle"`
EnablePrometheus bool `ini:"enable_prometheus"`
EnableMetrics bool `ini:"enable_metrics"`
}
// PostgresConfig is the configuration for the database
@ -945,7 +945,7 @@ func LoadConfig(file string) (*Config, error) {
RoutesStoreRefreshParallelism: 1,
NeighborsStoreRefreshParallelism: 1,
RoutesStoreQueryLimit: DefaultRoutesStoreQueryLimit,
EnablePrometheus: true,
EnableMetrics: true,
}
if err := parsedConfig.Section("server").MapTo(&server); err != nil {
return nil, err