MySQL target
TwinCommit applies changes to MySQL with multi-row INSERT ... ON DUPLICATE KEY UPDATE and keyed DELETE statements. It runs on InnoDB transactions, and the checkpoint commits together with the data.
Supported: MySQL 8.0, 8.4 LTS and 9.x · Amazon RDS and Aurora MySQL · Azure Database for MySQL · Cloud SQL for MySQL.
Configuration
Section titled “Configuration”target: type: mysql host: mysql-replica.internal port: 3306 user: twincommit password: ${MYSQL_TARGET_PASSWORD} database: replicaHow apply works
Section titled “How apply works”- Inserts and updates are batched into multi-row
INSERT ... ON DUPLICATE KEY UPDATE. - Deletes are batched
DELETE ... WHERE (pk) IN (...). - The checkpoint table is InnoDB and is updated in the same transaction.
Grants
Section titled “Grants”CREATE USER 'twincommit'@'%' IDENTIFIED BY '********';GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, ALTER, INDEX ON replica.* TO 'twincommit'@'%';