postgres-operator/pkg
Juhani Pelli 4c1bb1c0ea
Use maxUnavailable for the critical-op PDB to stop idle alert noise (#3141)
* Use maxUnavailable for the critical-op PDB to stop idle alert noise

The critical-op PDB is created with minAvailable equal to
numberOfInstances while its selector (critical-operation=true) matches
no pods during normal operation. This leaves status.desiredHealthy at N
and currentHealthy at 0 permanently, so monitoring stacks fire alerts
like kube-prometheus-stack's KubePdbNotEnoughHealthyPods for every idle
cluster (#3020).

maxUnavailable: 0 provides the same protection while a critical
operation is running - no voluntary evictions of labeled pods - but
keeps the budget satisfied (desiredHealthy 0) when nothing matches.
When PDBs are disabled or there are no instances, the budget relaxes to
maxUnavailable 100% instead of minAvailable 0.

Fixes #3020

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Update PDB docs for critical-op maxUnavailable semantics

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Clarify why the two PDBs use different budget fields

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
Co-authored-by: Felix Kunde <felix-kunde@gmx.de>
2026-07-27 17:36:42 +02:00
..
apis change volume specs to int32 and define max iops and throughput values (#3139) 2026-07-27 16:32:22 +02:00
apiserver Add operator deployment readiness probe (#1874) 2023-01-05 18:29:47 +01:00
cluster Use maxUnavailable for the critical-op PDB to stop idle alert noise (#3141) 2026-07-27 17:36:42 +02:00
controller remove gp3 migration flow (#3142) 2026-07-27 14:02:44 +02:00
generated Update to Go 1.26.4, build runners and go.mod depedencies (#3108) 2026-06-23 13:35:53 +02:00
spec Generate CRD for postgresteam resource (#3004) 2026-01-10 19:39:08 +01:00
teams Generate CRD for postgresteam resource (#3004) 2026-01-10 19:39:08 +01:00
util change volume specs to int32 and define max iops and throughput values (#3139) 2026-07-27 16:32:22 +02:00