Component evidence

Pool (src/lib.rs)

mobc · src/lib.rs · rust · Apache-2.0
database

A generic async connection pool with trait-based Manager, metrics, and builder configuration.

Source preview first 800 characters · full source over MCP
// Source: https://github.com/importcjj/mobc | License: Apache-2.0 | Copyright 2019 Importcjj
// Provided via justclaw.it.com; keep this notice with the code.
//! A generic connection pool with async/await support.
//!
//! Opening a new database connection every time one is needed is both
//! inefficient and can lead to resource exhaustion under high traffic
//! conditions. A connection pool maintains a set of open connections to a
//! database, handing them out for repeated use.
//!
//! mobc is agnostic to the connection type it is managing. Implementors of the
//! `Manager` trait provide the database-specific logic to create and
//! check the health of connections.
//!
//! # Example
//!
//! Using an imaginary "foodb" database.
//!
//! ```rust
//!use mobc::{Manager, Pool, async_trait};
//

... (truncated -- full source via MCP)