Files
Kirill Ilin f38012cc7a fix(postgres-operator): alert when a CNPG cluster is offline, not an instance
CNPGClusterOffline grouped cnpg_collector_up by pod, so it fired as soon as
any single instance stopped reporting up: a replica replaying WAL while the
primary kept serving paged as an offline cluster. With no cnpg_collector_up
series at all, the OR on() vector(0) fallback evaluated to a label-less 0 and
the alert fired for good on clusters that run no CNPG database.

Group per CNPG cluster instead, derived from the instance pod name
(<cluster>-<N>): a cluster label cannot be relied on, as an external label of
the same name on the scraper overwrites it. The fallback goes; the alert
names the cluster instead of a pod.

Assisted-By: LLM
Signed-off-by: Kirill Ilin <stitch14@yandex.ru>
2026-09-30 14:06:26 +05:00
..