From 7d4906a59e1175ff0c0ba0745c7a089aadc2ab06 Mon Sep 17 00:00:00 2001 From: Till Prochaska <1512805+tillprochaska@users.noreply.github.com> Date: Thu, 7 Nov 2024 15:27:05 +0100 Subject: [PATCH] Update Prometheus exporter probes so they do not actually generate all metrics (#3996) * Update Prometheus exporter probes so they do not actually generate all metrics Generating all metrics can take multiple seconds for large Aleph instances, which can make the liveness/readiness probe fail. The `name[]` query parameter can be used to select a subset of metrics the exporter should return (or no metrics as all in this case). That way, we can check that the exporter is up and running without actually generating any metrics. * Slightly increase exporter default resources This should be a little closer to real-world usage --- helm/charts/aleph/templates/exporter.yaml | 6 ++++-- helm/charts/aleph/values.yaml | 6 +++--- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/helm/charts/aleph/templates/exporter.yaml b/helm/charts/aleph/templates/exporter.yaml index 6f13872c43..84615909da 100644 --- a/helm/charts/aleph/templates/exporter.yaml +++ b/helm/charts/aleph/templates/exporter.yaml @@ -65,12 +65,14 @@ spec: key: SENTRY_DSN readinessProbe: httpGet: - path: /metrics + # Unselect all metrics as generating them can take multiple seconds + path: /metrics?name[]=None port: 9100 initialDelaySeconds: 5 livenessProbe: httpGet: - path: /metrics + # Unselect all metrics as generating them can take multiple seconds + path: /metrics?name[]=None port: 9100 initialDelaySeconds: 5 volumes: diff --git a/helm/charts/aleph/values.yaml b/helm/charts/aleph/values.yaml index f28d71ad23..5ac52aac66 100644 --- a/helm/charts/aleph/values.yaml +++ b/helm/charts/aleph/values.yaml @@ -332,7 +332,7 @@ exporter: containerResources: requests: - memory: 250Mi - cpu: 10m + memory: 300Mi + cpu: 150m limits: - memory: 500Mi + memory: 1Gi