pub struct Observer { /* private fields */ }Expand description
Cache-side observer for runtime stats, debug traces, and optional cache tracing.
Implementations§
Source§impl Observer
impl Observer
Sourcepub fn runtime_snapshot(&self) -> RuntimeStatsSnapshotInner
pub fn runtime_snapshot(&self) -> RuntimeStatsSnapshotInner
Snapshot runtime counters and reset them to zero.
Sourcepub fn consume_event_trace(&self) -> EventTrace
pub fn consume_event_trace(&self) -> EventTrace
Consume and clear the in-memory debug event trace.
Sourcepub fn enable_cache_trace(&self)
pub fn enable_cache_trace(&self)
Enable recording cache trace events (for offline analysis).
Sourcepub fn disable_cache_trace(&self)
pub fn disable_cache_trace(&self)
Disable recording cache trace events.
Sourcepub fn flush_cache_trace(&self, to_file: impl AsRef<Path>)
pub fn flush_cache_trace(&self, to_file: impl AsRef<Path>)
Flush recorded cache trace events to a Parquet file.
Sourcepub fn cache_tracer(&self) -> &CacheTracer
pub fn cache_tracer(&self) -> &CacheTracer
Access the underlying cache tracer.
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for Observer
impl RefUnwindSafe for Observer
impl Send for Observer
impl Sync for Observer
impl Unpin for Observer
impl UnsafeUnpin for Observer
impl UnwindSafe for Observer
Blanket Implementations§
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
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 moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request