mirror of
https://github.com/alibaba/canal.git
synced 2026-11-04 00:30:15 +08:00
FlatMessage没有默认构造方法json反序列化的问题
Dml类增加isDdl属性
This commit is contained in:
@@ -56,7 +56,7 @@ public class RdbMirrorDbSyncService {
|
||||
if (mirrorDbConfig == null) {
|
||||
continue;
|
||||
}
|
||||
if (StringUtils.isNotEmpty(dml.getSql())) {
|
||||
if (dml.getIsDdl() != null && dml.getIsDdl() && StringUtils.isNotEmpty(dml.getSql())) {
|
||||
// DDL
|
||||
if (logger.isDebugEnabled()) {
|
||||
logger.debug("DDL: {}", JSON.toJSONString(dml, SerializerFeature.WriteMapNullValue));
|
||||
|
||||
@@ -135,7 +135,7 @@ public class RdbSyncService {
|
||||
public void sync(Map<String, Map<String, MappingConfig>> mappingConfig, List<Dml> dmls) {
|
||||
try {
|
||||
sync(dmls, dml -> {
|
||||
if (StringUtils.isNotEmpty(dml.getSql())) {
|
||||
if (dml.getIsDdl() != null && dml.getIsDdl() && StringUtils.isNotEmpty(dml.getSql())) {
|
||||
// DDL
|
||||
columnsTypeCache.remove(dml.getDestination() + "." + dml.getDatabase() + "." + dml.getTable());
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user