pub struct PoolStats {
pub reuses: u64,
pub opens: u64,
pub expirations: u64,
pub in_use: usize,
}Expand description
Statistics about pool usage.
Fields§
§reuses: u64Number of connection reuses.
opens: u64Number of new connections opened.
expirations: u64Number of connections closed due to expiration.
in_use: usizeTotal number of connection checkouts since the pool was created
(or since the last SqlitePool::reset_stats call).
This counter is cumulative: it is incremented on every
SqlitePool::get but never decremented, because
SqliteConnection holds no handle back to the pool’s stats to
decrement on drop. Read it as total checkouts, not as the number
of connections currently checked out.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PoolStats
impl RefUnwindSafe for PoolStats
impl Send for PoolStats
impl Sync for PoolStats
impl Unpin for PoolStats
impl UnsafeUnpin for PoolStats
impl UnwindSafe for PoolStats
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