pub struct LevelStats {
pub level: usize,
pub segment_count: usize,
pub used_bytes: u64,
pub item_count: u64,
pub reads: u64,
pub last_access_secs: u64,
pub segments: Vec<SegmentStats>,
}Expand description
Per-LSM-level size + entry aggregates with the contributing segments, for tiering and erasure-coding placement (which level / segment is large enough to demote, EC-encode, or migrate).
Cheap to read: derived from version metadata plus one file-size stat per
segment, never a data-block scan. The per-level totals reconcile with the
tree-level StorageStats: summed across levels they equal the SST portion
of StorageStats::used_bytes and StorageStats::item_count (blob files
are tracked separately).
Fields§
§level: usizeLSM level index (0 is the newest / smallest level).
segment_count: usizeNumber of segments (SSTs) in the level.
used_bytes: u64Physical on-disk bytes summed across the level’s segments.
item_count: u64Entry versions summed across the level’s segments.
reads: u64Cumulative point-read probes summed across the level’s segments.
last_access_secs: u64Most recent point-read probe across the level’s segments, in unix
seconds, or 0 if none was ever read.
segments: Vec<SegmentStats>Per-segment breakdown, in level (run / table) order.
Trait Implementations§
Source§impl Clone for LevelStats
impl Clone for LevelStats
Source§fn clone(&self) -> LevelStats
fn clone(&self) -> LevelStats
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for LevelStats
impl Debug for LevelStats
impl Eq for LevelStats
Source§impl PartialEq for LevelStats
impl PartialEq for LevelStats
Source§fn eq(&self, other: &LevelStats) -> bool
fn eq(&self, other: &LevelStats) -> bool
self and other values to be equal, and is used by ==.impl StructuralPartialEq for LevelStats
Auto Trait Implementations§
impl Freeze for LevelStats
impl RefUnwindSafe for LevelStats
impl Send for LevelStats
impl Sync for LevelStats
impl Unpin for LevelStats
impl UnsafeUnpin for LevelStats
impl UnwindSafe for LevelStats
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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<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>
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>
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