From 993e1fc878dfb1e2e54928da464f046540516d34 Mon Sep 17 00:00:00 2001 From: Thomas Lamprecht Date: Mon, 25 Nov 2024 17:46:42 +0100 Subject: [PATCH] rrd: selective code style clean-up Selective because there are quite a few more such old-style format strings, but I had those already adapted and currently do not have time do clean-up tree-wide, but it's fine to change this incrementally. Signed-off-by: Thomas Lamprecht --- proxmox-rrd/src/cache.rs | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/proxmox-rrd/src/cache.rs b/proxmox-rrd/src/cache.rs index 602b8227..9dd85a16 100644 --- a/proxmox-rrd/src/cache.rs +++ b/proxmox-rrd/src/cache.rs @@ -285,13 +285,9 @@ fn apply_and_commit_journal_thread( match apply_journal_impl(Arc::clone(&state), Arc::clone(&rrd_map)) { Ok(entries) => { let elapsed = start_time.elapsed().unwrap().as_secs_f64(); - log::info!( - "applied rrd journal ({} entries in {:.3} seconds)", - entries, - elapsed - ); + log::info!("applied rrd journal ({entries} entries in {elapsed:.3} seconds)"); } - Err(err) => bail!("apply rrd journal failed - {}", err), + Err(err) => bail!("apply rrd journal failed - {err}"), } } @@ -302,12 +298,10 @@ fn apply_and_commit_journal_thread( Ok(rrd_file_count) => { let elapsed = start_time.elapsed().unwrap().as_secs_f64(); log::info!( - "rrd journal successfully committed ({} files in {:.3} seconds)", - rrd_file_count, - elapsed + "rrd journal successfully committed ({rrd_file_count} files in {elapsed:.3} seconds)" ); } - Err(err) => bail!("rrd journal commit failed: {}", err), + Err(err) => bail!("rrd journal commit failed: {err}"), } Ok(()) }