From c9e6f11515bc64fd63de204fa6665e91eb5d6951 Mon Sep 17 00:00:00 2001 From: bluewolf Date: Sun, 27 Aug 2023 21:20:14 -0400 Subject: [PATCH] fix: readded check for primary to prevent providing erroneous metrix for replicas. see #1814 --- charts/cloudnative-pg/values.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/charts/cloudnative-pg/values.yaml b/charts/cloudnative-pg/values.yaml index 9faf8ec0c..8b7fb4e73 100644 --- a/charts/cloudnative-pg/values.yaml +++ b/charts/cloudnative-pg/values.yaml @@ -244,6 +244,7 @@ monitoringQueriesConfigMap: description: "Time at which postgres started (based on epoch)" pg_replication: + primary: true query: "SELECT CASE WHEN NOT pg_catalog.pg_is_in_recovery() THEN 0 ELSE GREATEST (0,