A Rust-based MySQL proxy framework for intercepting, analyzing, and manipulating database traffic with custom logic.
mysql-proxy-rs is a MySQL proxy server framework written in Rust that allows developers to intercept, analyze, and manipulate database traffic between applications and MySQL servers. It solves the need for custom database middleware by providing a programmable layer to implement logging, security monitoring, performance profiling, and query manipulation without altering the underlying database or application code.
Database administrators, DevOps engineers, and backend developers who need to monitor, secure, or test MySQL database interactions in production or development environments.
Developers choose mysql-proxy-rs for its high performance due to Rust and Tokio, its extensible design via a clean packet-handling trait, and its ability to enable advanced database operations like query logging, threat detection, and traffic replay without invasive changes.
A highly scalable MySQL Proxy framework written 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.
Built on Tokio for asynchronous I/O, enabling efficient, low-latency handling of database traffic, as emphasized in the README's focus on extensibility and performance.
Provides a clean PacketHandler trait that allows developers to define custom logic for inspecting, mutating, or dropping packets, making it flexible for use cases like logging and threat detection.
Supports actions like dropping, mutating, or responding to packets, enabling features such as query filtering, as shown in the example that blocks 'avocado'-related queries.
Requires Rust knowledge and compilation; the README notes testing with an outdated rustc version (1.13.0-nightly from 2016), which may lead to compatibility issues or a steep learning curve.
It's a framework, not a complete solution; users must write custom handlers for functionalities like logging or security, unlike pre-built proxies that offer these immediately.
Focuses solely on MySQL protocol, making it unsuitable for projects using other databases like PostgreSQL or MongoDB without significant modification.