LinMingQiang commented on code in PR #8338:
URL: https://github.com/apache/hudi/pull/8338#discussion_r1155123399


##########
hudi-flink-datasource/hudi-flink/src/main/java/org/apache/hudi/util/StreamerUtil.java:
##########
@@ -217,18 +218,52 @@ public static HoodieTableMetaClient initTableIfNotExists(
           .setCDCEnabled(conf.getBoolean(FlinkOptions.CDC_ENABLED))
           
.setCDCSupplementalLoggingMode(conf.getString(FlinkOptions.SUPPLEMENTAL_LOGGING_MODE))
           .setTimelineLayoutVersion(1)
+          .setHoodieIndexConf(OptionsResolver.getHoodieIndexConf(conf))
           .initTable(hadoopConf, basePath);
       LOG.info("Table initialized under base path {}", basePath);
       return metaClient;
     } else {
       LOG.info("Table [{}/{}] already exists, no need to initialize the table",
           basePath, conf.getString(FlinkOptions.TABLE_NAME));
-      return StreamerUtil.createMetaClient(basePath, hadoopConf);
+      HoodieTableMetaClient client = StreamerUtil.createMetaClient(basePath, 
hadoopConf);
+      validateTableConfig(conf, client.getTableConfig());

Review Comment:
   We just need to verify when the StreamWriteOperatorCoordinator#start or 
HoodieTableFactory#setupTableOptions. Just ensure that the job cannot be 
started if the validation fails.



-- 
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...@hudi.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to