plugin-barman-cloud/internal/cnpgi/instance
Gabriel Jose Mouallem Rodrigues eefb45ca5a fix: add retry logic to updateRecoveryWindow for concurrent status updates
When backup completion and retention policy enforcement run concurrently,
both call updateRecoveryWindow to update the ObjectStore status. This can
cause "object has been modified" errors due to Kubernetes optimistic
concurrency control.

This change wraps the status update in retry.RetryOnConflict, matching
the pattern already used in setLastFailedBackupTime in the same file.
The retry logic fetches a fresh copy of the ObjectStore before each
update attempt, ensuring the resourceVersion is current.

Fixes #758

Signed-off-by: Gabriel Mouallem <gabriel@latitude.sh>
2026-02-03 15:01:30 -03:00
..
internal/client feat(ip): assign copyright to the Linux Foundation (#571) 2025-10-07 18:06:06 +02:00
backup.go feat(ip): assign copyright to the Linux Foundation (#571) 2025-10-07 18:06:06 +02:00
doc.go feat(ip): assign copyright to the Linux Foundation (#571) 2025-10-07 18:06:06 +02:00
identity.go feat(ip): assign copyright to the Linux Foundation (#571) 2025-10-07 18:06:06 +02:00
manager.go fix(deps): update module sigs.k8s.io/controller-runtime to v0.23.1 (#748) 2026-01-29 19:39:06 +01:00
metrics_test.go feat(ip): assign copyright to the Linux Foundation (#571) 2025-10-07 18:06:06 +02:00
metrics.go feat(ip): assign copyright to the Linux Foundation (#571) 2025-10-07 18:06:06 +02:00
recovery_window.go fix: add retry logic to updateRecoveryWindow for concurrent status updates 2026-02-03 15:01:30 -03:00
retention.go feat(ip): assign copyright to the Linux Foundation (#571) 2025-10-07 18:06:06 +02:00
start.go feat(ip): assign copyright to the Linux Foundation (#571) 2025-10-07 18:06:06 +02:00
suite_test.go feat(ip): assign copyright to the Linux Foundation (#571) 2025-10-07 18:06:06 +02:00
types.go feat(ip): assign copyright to the Linux Foundation (#571) 2025-10-07 18:06:06 +02:00