Details
-
New Feature
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
None
-
None
-
MXS-SPRINT-93, MXS-SPRINT-100
Description
Using master_wait_gitd(MXS-199) to achieve causal read is not work so well when replication lag cannot ignore (such as > 100ms); We tested it with 5.7 and turn on logical clock, and set innodb_flush_log_at_trx_commit = 1000 on replica, read write ratio is 5:1, the performance is no better than route to single node; Maybe Mysql 8.0's Writeset-based replication will improve this, or Polardb's physical replication.
Because replication lag has many influence factors,so we need another way to achieve causal read;
Our proposal:
1. Find a way to get latest gtid info of every replica;
a. Regularly get it from monitor
b. Update it when ok packet is received, if it is newer than recorded one, update it using CAS;
2. Compare backend's gtid in proxy side;