feat: mysql replication enhancements #336
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Ref #329
Support for Database/Table Filtering in MySQL Replication
Added the ability to filter databases and tables during MySQL replication using a source DSN, e.g.,
-e SOURCE_DSN=mysql://root:[email protected]:3306/db01?schemas=db02,db03&skip-tables=t0,t1
. This configuration replicates data only fromdb01
,db02
, anddb03
, while skipping changes to tablest0
andt1
.Handling Virtual Primary Keys in the Slow Path of
LOAD DATA
Addressed issues with MySQL Shell copy utilities generating advanced
LOAD DATA ... (@id, ...) SET id = FROM_BASE64(@id)
statements for tables containing UUID columns. These statements were previously processed through the slower code path of thego-mysql-server
framework, which did not correctly handle virtual primary keys. This resulted in errors like:Binder Error: There are no UNIQUE/PRIMARY KEY Indexes that refer to this table, ON CONFLICT is a no-op
.The slow path now properly handles virtual primary keys.
Test Case for Replicating MySQL JSON Columns
Added a test case for MySQL JSON column replication. Currently, JSON columns containing string values with escaped double quotes (e.g.,
{"v2": "bcd\\"efg"}
) cannot be read by either DuckDB v1.1.x orgo-mysql-server
. This limitation will be resolved with the release of DuckDB v1.2.0.