Struct redb::DatabaseStats
source · pub struct DatabaseStats { /* private fields */ }
Expand description
Informational storage stats about the database
Implementations§
source§impl DatabaseStats
impl DatabaseStats
sourcepub fn tree_height(&self) -> u32
pub fn tree_height(&self) -> u32
Maximum traversal distance to reach the deepest (key, value) pair, across all tables
sourcepub fn allocated_pages(&self) -> u64
pub fn allocated_pages(&self) -> u64
Number of pages allocated
sourcepub fn leaf_pages(&self) -> u64
pub fn leaf_pages(&self) -> u64
Number of leaf pages that store user data
sourcepub fn branch_pages(&self) -> u64
pub fn branch_pages(&self) -> u64
Number of branch pages in btrees that store user data
sourcepub fn stored_bytes(&self) -> u64
pub fn stored_bytes(&self) -> u64
Number of bytes consumed by keys and values that have been inserted. Does not include indexing overhead
sourcepub fn metadata_bytes(&self) -> u64
pub fn metadata_bytes(&self) -> u64
Number of bytes consumed by keys in internal branch pages, plus other metadata
sourcepub fn fragmented_bytes(&self) -> u64
pub fn fragmented_bytes(&self) -> u64
Number of bytes consumed by fragmentation, both in data pages and internal metadata tables
Trait Implementations§
Auto Trait Implementations§
impl Freeze for DatabaseStats
impl RefUnwindSafe for DatabaseStats
impl Send for DatabaseStats
impl Sync for DatabaseStats
impl Unpin for DatabaseStats
impl UnwindSafe for DatabaseStats
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