[!WARNING] This project is currently experimental. APIs are unstable, behaviour may change between releases, and it is not yet ready for production use.
đĻ Installation
Or in Cargo.toml:
[]
= "0.1"
đ Usage
Implement the StorageEngine trait in a cdylib crate, then INSTALL PLUGIN it into a running mysql:8.4 server.
Prerequisites
- Rust 1.85+
mysql:8.4(any install method â local, Homebrew, Docker, RDS)
1. New cdylib crate
[]
= "my-engine"
= "2024"
[]
= ["cdylib"]
[]
= "0.1"
2. Implement StorageEngine
use ;
use CStr;
;
Plugin manifest macro: copy from examples/engine/src/lib.rs.
3. Build
MYSQL_HANDLER_FROM_SOURCE=1
# or
MYSQL_HANDLER_ARCHIVE=/path/to/libha_rusty_shim.a.gz
4. Install
INSTALL PLUGIN my_engine SONAME 'libmy_engine.so';
(id INT) ENGINE=MY_ENGINE;
đ Performance
Per-callback FFI overhead, callback profile, and OLTP throughput live in tests/sysbench/RESULTS.md.
â Issue
If you have any questions or suggestions, please open an issue.