From: Wolfgang Bumiller <w.bumiller@proxmox.com>
To: Shan Shaji <s.shaji@proxmox.com>
Cc: pbs-devel@lists.proxmox.com
Subject: [pbs-devel] applied: [PATCH proxmox-backup v2] fix #6624: ui: improve task log output for protected entry
Date: Wed, 27 Aug 2025 13:57:58 +0200 [thread overview]
Message-ID: <hpjgwzj2nj5lmzdhltsgibszmxdqiarjspwp6drdg6s32bdoe2@pinwxnvvi3g3> (raw)
In-Reply-To: <20250825132103.225192-1-s.shaji@proxmox.com>
applied, thanks
On Mon, Aug 25, 2025 at 03:21:03PM +0200, Shan Shaji wrote:
> Using 'Prune All' gives incomplete task-log output for a
> 'protected' entry. To fix this, add match expression to
> convert `PruneMark` variants into strings.
>
> Signed-off-by: Shan Shaji <s.shaji@proxmox.com>
> ---
>
> changes since v1:
> - Removed nested if condition check.
> - Added match expression to convert the `PruneMark` variants to strings.
> - Updated commit message.
>
> src/server/prune_job.rs | 10 ++++++++--
> 1 file changed, 8 insertions(+), 2 deletions(-)
>
> diff --git a/src/server/prune_job.rs b/src/server/prune_job.rs
> index 1c86647a..9d07558d 100644
> --- a/src/server/prune_job.rs
> +++ b/src/server/prune_job.rs
> @@ -7,7 +7,7 @@ use pbs_api_types::{
> print_store_and_ns, Authid, KeepOptions, Operation, PruneJobOptions, MAX_NAMESPACE_DEPTH,
> PRIV_DATASTORE_MODIFY, PRIV_DATASTORE_PRUNE,
> };
> -use pbs_datastore::prune::compute_prune_info;
> +use pbs_datastore::prune::{compute_prune_info, PruneMark};
> use pbs_datastore::DataStore;
> use proxmox_rest_server::WorkerTask;
>
> @@ -72,7 +72,13 @@ pub fn prune_datastore(
> if dry_run { "would " } else { "" },
> group.backup_type(),
> group.backup_id(),
> - info.backup_dir.backup_time_string()
> + info.backup_dir.backup_time_string(),
> + mark = match mark {
> + PruneMark::Protected => "keep protected",
> + PruneMark::Keep => "keep",
> + PruneMark::KeepPartial => "keep partial",
> + PruneMark::Remove => "remove",
> + }
> );
> if !keep && !dry_run {
> if let Err(err) = datastore.remove_backup_dir(ns, info.backup_dir.as_ref(), false) {
> --
> 2.47.2
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
prev parent reply other threads:[~2025-08-27 11:58 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-25 13:21 [pbs-devel] " Shan Shaji
2025-08-26 9:26 ` Michael Köppl
2025-08-27 11:57 ` Wolfgang Bumiller [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=hpjgwzj2nj5lmzdhltsgibszmxdqiarjspwp6drdg6s32bdoe2@pinwxnvvi3g3 \
--to=w.bumiller@proxmox.com \
--cc=pbs-devel@lists.proxmox.com \
--cc=s.shaji@proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox