JNSimba commented on code in PR #382: URL: https://github.com/apache/doris-flink-connector/pull/382#discussion_r1596749154
########## flink-doris-connector/src/main/java/org/apache/doris/flink/tools/cdc/DatabaseSync.java: ########## @@ -177,11 +179,20 @@ public void build() throws Exception { int sinkParallel = sinkConfig.getInteger( DorisConfigOptions.SINK_PARALLELISM, sideOutput.getParallelism()); + String uidName; + // determine whether to proceed with multi-database + // synchronization; if yes, the UID is composed of `dbname_tablename`, otherwise it + // is composed of `tablename`. + if (targetDbSet.size() > 1) { + uidName = dbTbl.f0 + "_" + dbTbl.f1; + } else { + uidName = dbTbl.f1; + } Review Comment: Would it be better to write a separate method? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org