Connect a database

MySQL

MySQL 8.0+ with GTID replication. Nothing is created on the source — anybranch dumps once, then follows the binlog.

Requirements

$ anybranch preflight mysql 'mysql://user:pass@host:3306/'

How sync works

User databases are dumped once with mysqldump --single-transaction --set-gtid-purged=ON, then the replica follows the source’s binlog by GTID auto-position. System schemas (mysql, sys, information_schema, performance_schema) are never mirrored. DDL replicates natively through the binlog, so migrations on production appear on branches with no extra setup.

When replication breaks

A transaction the replica cannot apply — for example a row you inserted on the replica that production later inserts too — pauses the SQL thread instead of retrying forever. status shows the error; repair skips that one transaction with an empty commit under its GTID and resumes.