#[non_exhaustive]pub struct PoolSnapshot {
pub read_cache_entries: usize,
pub read_cache_tombstones: usize,
pub read_cache_hits: usize,
pub read_cache_misses: usize,
pub read_cache_capped: usize,
pub read_cache_evictions: usize,
pub read_cache_open_fails: usize,
pub read_cache_max_entries: usize,
pub ledger_writer_inits: usize,
}Expand description
Read-cache + ledger-writer snapshot.
Returned by crate::Engine::pool. All counters are monotonic since
process start.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.read_cache_entries: usizeActive read-cache entries (open SQLite connections currently parked).
read_cache_tombstones: usizeTombstoned entries waiting on in-flight reads to drain.
read_cache_hits: usizeCache hits since process start.
A hit means a Phase 1 cached slot returned a definitive answer:
Some from a Ready slot, or None from Tombstone. Opening and
Evicted retry signals are not hits.
read_cache_misses: usizeCache misses since process start.
Counted at most once per external read, even if internal retry loops run more than once. Under races, one external read may independently count a miss and later a hit if another reader installs the target slot first.
read_cache_capped: usizeTimes a read saw the cache at cap after a miss.
Counted at most once per external read. The read may still evict a sampled cold slot instead of falling back to a transient slot.
read_cache_evictions: usizeSuccessful cap-full read-cache evictions since process start. Failed eviction attempts fall back to transient reads and are not counted.
read_cache_open_fails: usizeRead-cache slot open failures (SQLite open errors).
read_cache_max_entries: usizeConfigured maximum cache entries.
ledger_writer_inits: usizeLedger writer (re)initializations since process start.