evict_conns

Function evict_conns 

Source
pub fn evict_conns<T>(
    cutoff: Instant,
    conns: &mut HashMap<Box<str>, Mutex<VecDeque<PooledConn<T>>>>,
)
Expand description

Evicts connections from the pool that have been idle for longer than the cutoff time.

ยงArguments

  • cutoff - Connections with a last_seen timestamp before this will be evicted
  • conns - The connection pool to evict from