pub struct PipelineCacheMetrics {
pub lookups: u64,
pub hits: u64,
pub misses: u64,
pub puts: u64,
pub rejected_puts: u64,
pub evictions: u64,
pub evicted_bytes: u64,
pub flushes: u64,
pub flush_errors: u64,
pub cached_bytes: u64,
pub entries: u64,
}Expand description
Pipeline-cache instrumentation counters.
Fields§
§lookups: u64Lookup attempts.
hits: u64Successful lookups.
misses: u64Failed lookups.
puts: u64Accepted put attempts.
rejected_puts: u64Rejected put attempts, usually because a blob exceeds the byte budget.
evictions: u64Entries evicted by capacity or byte-budget pressure.
evicted_bytes: u64Bytes removed by eviction.
flushes: u64Explicit flush attempts.
flush_errors: u64Explicit flush failures.
cached_bytes: u64Current retained bytes when the backend can report them cheaply.
entries: u64Current retained entries when the backend can report them cheaply.
Implementations§
Source§impl PipelineCacheMetrics
impl PipelineCacheMetrics
Sourcepub fn hit_rate_ppm(&self) -> u32
pub fn hit_rate_ppm(&self) -> u32
Cache-hit rate in parts per million.
Sourcepub fn try_hit_rate_ppm(&self) -> Result<u32, PipelineCacheMetricError>
pub fn try_hit_rate_ppm(&self) -> Result<u32, PipelineCacheMetricError>
Fallibly compute cache-hit rate in parts per million.
§Errors
Returns PipelineCacheMetricError when the numerator or final value
cannot fit the public metric ABI.
Trait Implementations§
Source§impl Clone for PipelineCacheMetrics
impl Clone for PipelineCacheMetrics
Source§fn clone(&self) -> PipelineCacheMetrics
fn clone(&self) -> PipelineCacheMetrics
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for PipelineCacheMetrics
Source§impl Debug for PipelineCacheMetrics
impl Debug for PipelineCacheMetrics
Source§impl Default for PipelineCacheMetrics
impl Default for PipelineCacheMetrics
Source§fn default() -> PipelineCacheMetrics
fn default() -> PipelineCacheMetrics
Returns the “default value” for a type. Read more
impl Eq for PipelineCacheMetrics
Source§impl PartialEq for PipelineCacheMetrics
impl PartialEq for PipelineCacheMetrics
Source§fn eq(&self, other: &PipelineCacheMetrics) -> bool
fn eq(&self, other: &PipelineCacheMetrics) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for PipelineCacheMetrics
Auto Trait Implementations§
impl Freeze for PipelineCacheMetrics
impl RefUnwindSafe for PipelineCacheMetrics
impl Send for PipelineCacheMetrics
impl Sync for PipelineCacheMetrics
impl Unpin for PipelineCacheMetrics
impl UnsafeUnpin for PipelineCacheMetrics
impl UnwindSafe for PipelineCacheMetrics
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.