A pure Rust MySQL client library with connection pooling, prepared statements, and TLS support.
mysql is a MySQL and MariaDB client library written entirely in Rust. It enables Rust applications to connect to, query, and manage MySQL databases with support for both text and binary protocols, connection pooling, and secure TLS connections. It solves the need for a safe, performant, and native database driver in the Rust ecosystem.
Rust developers building applications that require MySQL/MariaDB database connectivity, particularly those who need a pure Rust solution without C dependencies for safety and cross-compilation.
Developers choose mysql for its memory safety guarantees, comprehensive feature set (including connection pooling and prepared statements), and seamless integration with Rust's type system, offering a robust alternative to C-based bindings.
Mysql client library implemented in rust.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Implemented entirely in Rust with no C dependencies, ensuring memory safety and easy cross-compilation, as emphasized in the project's philosophy and key features.
Includes a connection pool for efficient management of database connections, reducing overhead for frequent queries, directly mentioned in the README's features.
Extensive conversions between MySQL data types and Rust types via FromValue and FromRow traits, enabling seamless deserialization of query results with examples in the documentation.
Supports both text and binary protocols, including prepared statements with named parameters and client-side caching, detailed in sections like Named Parameters and Statement Cache.
The library appears to lack native async/await support, which is a limitation for modern Rust applications built on async runtimes, not addressed in the README.
Requires careful selection of multiple features like TLS backends and buffer pooling, with options such as native-tls or rustls-tls, complicating setup and maintenance.
Statement cache only works under specific conditions and requires manual management if disabled, potentially leading to server resource exhaustion, as noted in the caveats section.