From 4303ee0e0b88bfdbe26d1a99360ee7f791a6ff3a Mon Sep 17 00:00:00 2001 From: Paolo Chila Date: Wed, 11 Oct 2023 08:32:42 +0200 Subject: [PATCH] fixup! fixup! Increase metrics interval to 60s --- internal/pkg/agent/application/monitoring/v1_monitor.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/internal/pkg/agent/application/monitoring/v1_monitor.go b/internal/pkg/agent/application/monitoring/v1_monitor.go index a161bf679f2..3bbfb2b4fef 100644 --- a/internal/pkg/agent/application/monitoring/v1_monitor.go +++ b/internal/pkg/agent/application/monitoring/v1_monitor.go @@ -52,6 +52,9 @@ const ( agentName = "elastic-agent" windowsOS = "windows" + + // metricset execution period used for the monitoring metrics inputs + metricsCollectionInterval = 60 * time.Second ) var ( @@ -518,7 +521,7 @@ func (b *BeatsMonitor) monitoringNamespace() string { } func (b *BeatsMonitor) injectMetricsInput(cfg map[string]interface{}, componentIDToBinary map[string]string, monitoringOutputName string, componentList []component.Component) error { - metricsCollectionInterval := 60 * time.Second + metricsCollectionIntervalString := metricsCollectionInterval.String() monitoringNamespace := b.monitoringNamespace() fixedAgentName := strings.ReplaceAll(agentName, "-", "_")