
There are two common ways to implement the read replica pattern:
We focus on option 2 here. The middleware provides transparent routing between the application and database servers. We can customize the routing logic based on difficult rules such as user, schema, statement, etc.
The diagram above illustrates the setup:
The database middleware acts as a proxy between the application and databases. It uses standard MySQL network protocol for communication.
There are two common ways to implement the read replica pattern:
We focus on option 2 here. The middleware provides transparent routing between the application and database servers. We can customize the routing logic based on difficult rules such as user, schema, statement, etc.
The diagram above illustrates the setup:
The database middleware acts as a proxy between the application and databases. It uses standard MySQL network protocol for communication.