pub struct AuditStats {
pub total_appended: AtomicU64,
pub total_trimmed: AtomicU64,
pub total_queries_started: AtomicU64,
pub total_queries_completed: AtomicU64,
pub total_queries_failed: AtomicU64,
}Expand description
Atomic counters tracking aggregate log activity.
All fields are AtomicU64 so that snapshot() can be called without
taking any lock.
Fields§
§total_appended: AtomicU64Cumulative entries appended.
total_trimmed: AtomicU64Cumulative entries trimmed.
total_queries_started: AtomicU64Cumulative QueryStarted events.
total_queries_completed: AtomicU64Cumulative QueryCompleted events.
total_queries_failed: AtomicU64Cumulative QueryFailed events.
Implementations§
Source§impl AuditStats
impl AuditStats
Sourcepub fn snapshot(&self) -> AuditStatsSnapshot
pub fn snapshot(&self) -> AuditStatsSnapshot
Captures a consistent-enough snapshot of all counters.
Because each counter is updated atomically but independently, there is no cross-counter transaction guarantee; the snapshot is suitable for monitoring and reporting but not for distributed coordination.
Trait Implementations§
Source§impl Debug for AuditStats
impl Debug for AuditStats
Auto Trait Implementations§
impl !Freeze for AuditStats
impl RefUnwindSafe for AuditStats
impl Send for AuditStats
impl Sync for AuditStats
impl Unpin for AuditStats
impl UnsafeUnpin for AuditStats
impl UnwindSafe for AuditStats
Blanket Implementations§
impl<T> Allocation for T
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more