#[repr(u32)]pub enum StatsLevel {
DisableAll = 0,
ExceptHistogramOrTimers = 1,
ExceptTimers = 2,
ExceptDetailedTimers = 3,
ExceptTimeForMutex = 4,
All = 5,
}Expand description
How much statistics detail to collect, trading overhead for visibility.
The levels are ordered, and each one adds to the one before it. The discriminants come from the C API rather than being written out here, because the setter passes the value straight through and a mismatch would silently select a different level instead of failing.
RocksDB also defines kExceptTickers, which has the same value as
kDisableAll and so cannot be a separate variant here. DisableAll is that
value.
Variants§
DisableAll = 0
Collect nothing. Also what RocksDB reports when no statistics object has been installed, so this does not distinguish “turned off” from “never turned on”.
ExceptHistogramOrTimers = 1
Skip histograms and timers.
ExceptTimers = 2
Collect histograms, skip timers.
ExceptDetailedTimers = 3
Collect everything except time spent inside a mutex lock and time spent on compression.
ExceptTimeForMutex = 4
Collect everything except the counters that need the time from inside the mutex lock.
All = 5
Collect everything, including how long mutex operations take. Where reading the clock is expensive this can limit scalability across threads, especially for writes.
Trait Implementations§
Source§impl Clone for StatsLevel
impl Clone for StatsLevel
Source§fn clone(&self) -> StatsLevel
fn clone(&self) -> StatsLevel
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more