@@ -514,13 +514,13 @@ func TestMySQLBatchNoTableConfig(t *testing.T) {
514
514
InputPlugin : config.InputConfig {
515
515
Type : "mysql" ,
516
516
Mode : config .Batch ,
517
- Config : utils .Struct2Map (mysqlstream.MySQLBinlogInputPluginConfig {
517
+ Config : utils .MustAny2Map (mysqlstream.MySQLBinlogInputPluginConfig {
518
518
Source : sourceDBConfig ,
519
519
}),
520
520
},
521
- OutputPlugin : config.GenericConfig {
521
+ OutputPlugin : config.GenericPluginConfig {
522
522
Type : "mysql" ,
523
- Config : utils .Struct2Map (mysql.MySQLPluginConfig {
523
+ Config : utils .MustAny2Map (mysql.MySQLPluginConfig {
524
524
DBConfig : targetDBConfig ,
525
525
EnableDDL : true ,
526
526
Routes : []map [string ]interface {}{
@@ -572,13 +572,13 @@ func TestZeroTime(t *testing.T) {
572
572
InputPlugin : config.InputConfig {
573
573
Type : "mysql" ,
574
574
Mode : config .Replication ,
575
- Config : utils .Struct2Map (mysqlstream.MySQLBinlogInputPluginConfig {
575
+ Config : utils .MustAny2Map (mysqlstream.MySQLBinlogInputPluginConfig {
576
576
Source : sourceDBConfig ,
577
577
}),
578
578
},
579
- OutputPlugin : config.GenericConfig {
579
+ OutputPlugin : config.GenericPluginConfig {
580
580
Type : "mysql" ,
581
- Config : utils .Struct2Map (mysql.MySQLPluginConfig {
581
+ Config : utils .MustAny2Map (mysql.MySQLPluginConfig {
582
582
DBConfig : targetDBConfig ,
583
583
EnableDDL : true ,
584
584
Routes : []map [string ]interface {}{
@@ -667,7 +667,7 @@ func TestMySQLBatchWithInsertIgnore(t *testing.T) {
667
667
"mode" : "batch" ,
668
668
},
669
669
},
670
- OutputPlugin : config.GenericConfig {
670
+ OutputPlugin : config.GenericPluginConfig {
671
671
Type : "mysql" ,
672
672
Config : map [string ]interface {}{
673
673
"target" : map [string ]interface {}{
@@ -677,7 +677,7 @@ func TestMySQLBatchWithInsertIgnore(t *testing.T) {
677
677
"port" : targetDBConfig .Port ,
678
678
},
679
679
"enable-ddl" : true ,
680
- "sql-engine-config" : & config.GenericConfig {
680
+ "sql-engine-config" : & config.GenericPluginConfig {
681
681
Type : "mysql-insert-ignore" ,
682
682
},
683
683
"routes" : []map [string ]interface {}{
@@ -960,14 +960,14 @@ func TestMySQLToMyBidirection(t *testing.T) {
960
960
InputPlugin : config.InputConfig {
961
961
Type : "mysql" ,
962
962
Mode : config .Stream ,
963
- Config : utils .Struct2Map (mysqlstream.MySQLBinlogInputPluginConfig {
963
+ Config : utils .MustAny2Map (mysqlstream.MySQLBinlogInputPluginConfig {
964
964
IgnoreBiDirectionalData : true ,
965
965
Source : sourceDBConfig ,
966
966
}),
967
967
},
968
- OutputPlugin : config.GenericConfig {
968
+ OutputPlugin : config.GenericPluginConfig {
969
969
Type : "mysql" ,
970
- Config : utils .Struct2Map (mysql.MySQLPluginConfig {
970
+ Config : utils .MustAny2Map (mysql.MySQLPluginConfig {
971
971
DBConfig : targetDBConfig ,
972
972
EnableDDL : true ,
973
973
Routes : []map [string ]interface {}{
@@ -977,9 +977,9 @@ func TestMySQLToMyBidirection(t *testing.T) {
977
977
"target-schema" : targetDBName ,
978
978
},
979
979
},
980
- EngineConfig : & config.GenericConfig {
980
+ EngineConfig : & config.GenericPluginConfig {
981
981
Type : sql_execution_engine .MySQLReplaceEngine ,
982
- Config : utils .Struct2Map (sql_execution_engine.MysqlReplaceEngineConfig {
982
+ Config : utils .MustAny2Map (sql_execution_engine.MysqlReplaceEngineConfig {
983
983
TagInternalTxn : true ,
984
984
}),
985
985
},
@@ -1050,12 +1050,12 @@ func TestMySQLTagDDL(t *testing.T) {
1050
1050
InputPlugin : config.InputConfig {
1051
1051
Type : "mysql" ,
1052
1052
Mode : config .Stream ,
1053
- Config : utils .Struct2Map (mysqlstream.MySQLBinlogInputPluginConfig {
1053
+ Config : utils .MustAny2Map (mysqlstream.MySQLBinlogInputPluginConfig {
1054
1054
Source : sourceDBConfig ,
1055
1055
IgnoreBiDirectionalData : true ,
1056
1056
}),
1057
1057
},
1058
- OutputPlugin : config.GenericConfig {
1058
+ OutputPlugin : config.GenericPluginConfig {
1059
1059
Type : "mysql" ,
1060
1060
Config : map [string ]interface {}{
1061
1061
"target" : map [string ]interface {}{
@@ -1127,7 +1127,7 @@ func TestMySQLDDL(t *testing.T) {
1127
1127
},
1128
1128
},
1129
1129
},
1130
- OutputPlugin : config.GenericConfig {
1130
+ OutputPlugin : config.GenericPluginConfig {
1131
1131
Type : "mysql" ,
1132
1132
Config : map [string ]interface {}{
1133
1133
"target" : map [string ]interface {}{
@@ -1220,7 +1220,7 @@ func TestMySQLDDLNoRoute(t *testing.T) {
1220
1220
},
1221
1221
},
1222
1222
},
1223
- OutputPlugin : config.GenericConfig {
1223
+ OutputPlugin : config.GenericPluginConfig {
1224
1224
Type : "mysql" ,
1225
1225
Config : map [string ]interface {}{
1226
1226
"target" : map [string ]interface {}{
0 commit comments