For a very long part of its history, MySQL replication has been limited in terms of performance. Because there was no way of knowing if transactions or updates were independent, the updates had to be executed on a replica following the exact same sequence of operations as on the primary server. The only way to guarantee the same sequence of operations on the replica was to use a single thread. In this post, we’ll do a dive into the MySQL multi-threaded replication (MTR) implementation and explore the available tuning options.
MTR is the culmination of the evolution in the development of parallel replication which followed the path:
- Single-threaded replication
- Per-database replication
- Logical clock replication
We’ll leave aside, for now, the recent dependency tracking feature.
Context
Before we discuss the multi-threaded implementation, let’s review in …
[Read more]