定时保存snapshot到DB的逻辑中,schema名称获取错误,在有配置canal.instance.filter.regex时,由于对应的table无法被匹配中,导致compareTableMetaDbAndMemory方法不被执行 (#3693)

* 避免重复订阅zk变更状态

* Update DatabaseTableMeta.java

获取schema的名称

* Update CanalController.java
This commit is contained in:
happyrita
2021-10-09 15:32:20 +08:00
committed by GitHub
parent d67bea8f3d
commit 9e11c3c018

View File

@@ -301,7 +301,7 @@ public class DatabaseTableMeta implements TableMetaTSDB {
boolean compareAll = true;
for (Schema schema : tmpMemoryTableMeta.getRepository().getSchemas()) {
for (String table : schema.showTables()) {
String fullName = schema + "." + table;
String fullName = schema.getName() + "." + table;
if (blackFilter == null || !blackFilter.filter(fullName)) {
if (filter == null || filter.filter(fullName)) {
// issue : https://github.com/alibaba/canal/issues/1168