Pure Python Implementation of MySQL replication protocol build on top of PyMYSQL.
Actively maintained. Last release 4 months ago, commits in 5 of the last 26 weeks. A safe choice.
pip install mysql-replicationpython-mysql-replication
Use cases
- MySQL to NoSQL database replication
- MySQL to search engine replication
- Invalidate cache when something change in database
- Audit
- Real time analytics
Documentation
A work in progress documentation is available here: https://python-mysql-replication.readthedocs.org/en/latest/
Instruction about building documentation is available here: https://python-mysql-replication.readthedocs.org/en/latest/developement.html
Installation
pip install mysql-replication
Getting support
You can get support and discuss about new features on: https://github.com/julien-duponchelle/python-mysql-replication/discussions
Project status
The project is test with:
- MySQL 5.5, 5.6 and 5.7 (v0.1 ~ v0.45)
- MySQL 8.0.14 (v1.0 ~)
- MariaDB 10.6
- Python 3.10 - 3.14
- PyPy 3.7, 3.9 (really faster than the standard Python interpreter)
MySQL version 8.0.14 and later Set global variable binlog_row_metadata='FULL' and binlog_row_image='FULL'
The project is used in production for critical stuff in some medium internet corporations. But all use case as not been perfectly test in the real world.
Limitations
https://python-mysql-replication.readthedocs.org/en/latest/limitations.html
Featured
AWS blog
- Streaming Changes in a Database with Amazon Kinesis (by Emmanuel Espina, Amazon Web Services)