agent: allow configuration of in-memory telemetry sink. (#20166)

This change adds configuration options for setting the in-memory
telemetry sink collection and retention durations. This sink backs
the metrics JSON API and previously had hard-coded default values.

The new options are particularly useful when running development or
debug environments, where metrics collection is desired at a fast
and granular rate.
This commit is contained in:
James Rasell
2024-03-25 16:00:18 +01:00
committed by GitHub
parent 02d98b9357
commit facc3e8013
9 changed files with 193 additions and 34 deletions

View File

@@ -170,7 +170,6 @@
"server_service_name": "nomad",
"service_auth_method": "nomad-services",
"task_auth_method": "nomad-tasks",
"service_identity": {
"aud": [
"consul.io",
@@ -361,6 +360,8 @@
"syslog_facility": "LOCAL1",
"telemetry": [
{
"in_memory_collection_interval": "1m",
"in_memory_retention_period": "24h",
"collection_interval": "3s",
"disable_hostname": true,
"prometheus_metrics": true,
@@ -394,7 +395,10 @@
"cert_file": "/path/to/cert/file",
"create_from_role": "test_role",
"default_identity": {
"aud": ["vault.io", "nomad.io"],
"aud": [
"vault.io",
"nomad.io"
],
"env": false,
"file": true,
"ttl": "3h"
@@ -408,9 +412,9 @@
"token": "12345"
}
],
"reporting":{
"license":{
"enabled":"true"
"reporting": {
"license": {
"enabled": "true"
}
}
}