plugin-barman-cloud/web/versioned_docs/version-0.6.0/retention.md
Jonathan Gonzalez V. ac1c7ace1f
docs(release): documentation for release 0.6.0 (#493)
Signed-off-by: Jonathan Gonzalez V. <jonathan.gonzalez@enterprisedb.com>
2025-08-21 13:56:40 +02:00

1023 B

sidebar_position
60

Retention Policies

The Barman Cloud Plugin supports automated cleanup of obsolete backups via retention policies, configured in the .spec.retentionPolicy field of the ObjectStore resource.

:::note This feature uses the barman-cloud-backup-delete command with the --retention-policy "RECOVERY WINDOW OF {{ value }} {{ unit }}" syntax. :::

Example: 30-Day Retention Policy

apiVersion: barmancloud.cnpg.io/v1
kind: ObjectStore
metadata:
  name: my-store
spec:
  [...]
  retentionPolicy: "30d"

:::note A recovery window retention policy ensures the cluster can be restored to any point in time between the calculated Point of Recoverability (PoR) and the latest WAL archive. The PoR is defined as current time - recovery window. The first valid backup is the most recent backup completed before the PoR. Backups older than that are marked as obsolete and deleted after the next backup completes. :::