Repository navigation
fix(metrics): report sync replicas min/max with the new synchronous API - #11979
Conversation
|
❗ By default, the pull request is configured to backport to all release branches.
|
|
Verified on a kind cluster with 3 instances,
|
|
@gbartolini, here's the link to the E2E on CNPG workflow run: https://github.com/cloudnative-pg/cloudnative-pg/actions/runs/45007149140 |
|
/test |
|
@gbartolini, here's the link to the E2E on CNPG workflow run: https://github.com/cloudnative-pg/cloudnative-pg/actions/runs/45007386502 |
c78b296 to
d02de51
Compare
d02de51 to
6884866
Compare
6884866 to
bd8bbe4
Compare
|
/test |
|
@leonardoce, here's the link to the E2E on CNPG workflow run: https://github.com/cloudnative-pg/cloudnative-pg/actions/runs/45352803519 |
The `min` and `max` values of `cnpg_collector_sync_replicas` were always read from the legacy `.spec.minSyncReplicas` and `.spec.maxSyncReplicas` fields, so they were reported as 0 for clusters configured through `.spec.postgresql.synchronous`. Derive them from the configured `number` instead when the new API is in use: both bounds equal `number` when data durability is required, while the minimum is 0 when it is preferred, as the number of synchronous replicas can then be lowered to what is available. The legacy configuration keeps reporting the legacy fields. Part of #11309 Assisted-by: Claude Signed-off-by: Gabriele Bartolini <[email protected]>
bd8bbe4 to
ca0e396
Compare
…PI (#11979) The `min` and `max` values of `cnpg_collector_sync_replicas` were always read from the legacy `.spec.minSyncReplicas` and `.spec.maxSyncReplicas` fields, so they were reported as 0 for clusters configured through `.spec.postgresql.synchronous`. Derive them from the configured `number` instead when the new API is in use: both bounds equal `number` when data durability is required, while the minimum is 0 when it is preferred, as the number of synchronous replicas can then be lowered to what is available. The legacy configuration keeps reporting the legacy fields. Refs #11309 Assisted-by: Claude Signed-off-by: Gabriele Bartolini <[email protected]> (cherry picked from commit 20eae4e)
…PI (#11979) The `min` and `max` values of `cnpg_collector_sync_replicas` were always read from the legacy `.spec.minSyncReplicas` and `.spec.maxSyncReplicas` fields, so they were reported as 0 for clusters configured through `.spec.postgresql.synchronous`. Derive them from the configured `number` instead when the new API is in use: both bounds equal `number` when data durability is required, while the minimum is 0 when it is preferred, as the number of synchronous replicas can then be lowered to what is available. The legacy configuration keeps reporting the legacy fields. Refs #11309 Assisted-by: Claude Signed-off-by: Gabriele Bartolini <[email protected]> (cherry picked from commit 20eae4e)
Move the observed metric change to Important changes and point to the upgrade section once. Drop the internal status-port flag and the date of PostgreSQL 19, explain the deprecated role password fields, and cut repeated text. Mark #11979 as backported to 1.28. Signed-off-by: Marco Nenciarini <[email protected]>
The
minandmaxvalues ofcnpg_collector_sync_replicaswere always read from the legacy.spec.minSyncReplicasand.spec.maxSyncReplicasfields, so they were reported as 0 for clusters configured through.spec.postgresql.synchronous.Derive them from the configured
numberinstead when the new API is in use: both bounds equalnumberwhen data durability is required, while the minimum is 0 when it is preferred, as the number of synchronous replicas can then be lowered to what is available. The legacy configuration keeps reporting the legacy fields.Refs #11309
Assisted-by: Claude