[pbs-devel] [PATCH proxmox-backup 0/3] add removed vanished stats to sync job log
Christian Ebner
c.ebner at proxmox.com
Fri Mar 8 14:01:47 CET 2024
Adds a global summary of the vanished and therefore removed snapshots,
backup groups and namespaces to the sync jobs task log.
Patch 1/3 introduces a BackupGroupDeleteStats object, used to count
the number of removed snapshots within a backup group as well as the
number of not removed snapshots, since protected.
Patch 2/3 adds an optional RemovedVanishedStats object to the PullStats,
counting also the removed backup groups and namespaces and utilizing the
returned counts of removed snapshots as introduced by the previous
patch.
Patch 3/3 finally adds the removed vanished entities output to the sync
jobs task log.
The series was tested by creating a local sync job and syncing a
datastore, containing nested namespaces with snapshots performing the
following actions:
The `remove vanished` flag was unset for the sync job and the absence
of the line in the sync jobs task log verified for that case; then the
flag was set once again.
Further, removed snapshots on the source store, set some of the removed
snapshots to be protected on the target store and compared the removed
entities of the sync job by the logged output.
Finally, removed the protected flag on the snapshots in the target
datastore and removed all namespaces and snapshots in the source
datastore. Checked once again the sync jobs log output as compared to
the actual removed entities.
Christian Ebner (3):
datastore: group: return basic stats on backup group destroy
server: sync job: include removed vanished stats
api: sync job: log stats for removed vanished entities
pbs-datastore/src/backup_info.rs | 44 ++++++++++++++---
pbs-datastore/src/datastore.rs | 11 +++--
src/api2/admin/datastore.rs | 3 +-
src/api2/pull.rs | 10 ++++
src/server/pull.rs | 85 ++++++++++++++++++++++++++------
5 files changed, 127 insertions(+), 26 deletions(-)
--
2.39.2
More information about the pbs-devel
mailing list