mirror of
https://github.com/rustfs/rustfs.git
synced 2026-09-01 17:58:22 +00:00
fix(logging): bound ECStore debug output (#6809)
Also replace deprecated Atomic::fetch_update calls with try_update so the current Rust toolchain keeps lint and CI jobs warning-clean. Co-authored-by: heihutu <heihutu@gmail.com>
This commit is contained in:
@@ -192,7 +192,7 @@ impl MemorySnapshotCell {
|
||||
}
|
||||
if self
|
||||
.pending_release
|
||||
.fetch_update(Ordering::AcqRel, Ordering::Acquire, |pending| pending.checked_add(bytes))
|
||||
.try_update(Ordering::AcqRel, Ordering::Acquire, |pending| pending.checked_add(bytes))
|
||||
.is_err()
|
||||
{
|
||||
self.release_accounting_failed.store(true, Ordering::Release);
|
||||
|
||||
@@ -590,7 +590,7 @@ impl MokaBackend {
|
||||
// the synchronization, so relaxed ordering is sufficient here.
|
||||
let generation = match self
|
||||
.next_generation
|
||||
.fetch_update(Ordering::Relaxed, Ordering::Relaxed, |current| current.checked_add(1))
|
||||
.try_update(Ordering::Relaxed, Ordering::Relaxed, |current| current.checked_add(1))
|
||||
{
|
||||
Ok(previous) => previous + 1,
|
||||
Err(_) => return leader.finish(ObjectDataCacheFillResult::SkippedIdentityOverflow),
|
||||
|
||||
Reference in New Issue
Block a user