pub struct Metrics {
pub live: u64,
pub idle: u64,
pub parked: u64,
pub created: u64,
pub closed: u64,
pub acquires: u64,
pub waits: u64,
pub timeouts: u64,
pub poisoned: u64,
pub recycle_failures: u64,
pub unparked: u64,
}Expand description
A point-in-time snapshot of pool activity, from Pool::metrics.
Gauges (live, idle, parked) are summed across threads without a lock,
so they can be momentarily inconsistent with each other. Counters are
monotonic.
Fields§
§live: u64Connections currently owned by a shard, idle or checked out.
idle: u64Connections sitting in a shard free list.
parked: u64Connections sitting in the cross-thread reservoir.
created: u64Connections opened since the pool was created.
closed: u64Connections closed since the pool was created.
acquires: u64Successful checkouts.
waits: u64Checkouts that had to wait for a connection to come back.
timeouts: u64Checkouts that gave up at the acquire timeout.
poisoned: u64Connections discarded because a checkout was cancelled mid-operation.
recycle_failures: u64Connections discarded because recycle rejected them.
unparked: u64Connections taken from the reservoir by a thread that did not open them.