You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hudi.apache.org by "danny0405 (via GitHub)" <gi...@apache.org> on 2023/02/27 03:44:31 UTC
[GitHub] [hudi] danny0405 commented on a diff in pull request #8050: [MINOR] Fix oom caused by addResource in flink jm building HiveSyncCo…
danny0405 commented on code in PR #8050:
URL: https://github.com/apache/hudi/pull/8050#discussion_r1118251389
##########
hudi-flink-datasource/hudi-flink/src/main/java/org/apache/hudi/sink/utils/HiveSyncContext.java:
##########
@@ -90,7 +97,27 @@ public static HiveSyncContext create(Configuration conf, SerializableConfigurati
hadoopConf.set(HiveConf.ConfVars.METASTOREURIS.varname, conf.getString(FlinkOptions.HIVE_SYNC_METASTORE_URIS));
}
hiveConf.addResource(hadoopConf);
- return new HiveSyncContext(props, hiveConf);
+
+ HiveSyncTool hiveSyncTool = buildHiveSyncTool(props, hiveConf);
+ return new HiveSyncContext(props, hiveConf, hiveSyncTool);
+ }
+
+ private static HiveSyncTool buildHiveSyncTool(Properties props, HiveConf hiveConf) {
+ HiveSyncTool hiveSyncTool;
+ HiveSyncMode syncMode = HiveSyncMode.of(props.getProperty(HIVE_SYNC_MODE.key()));
+ if (syncMode == HiveSyncMode.GLUE) {
Review Comment:
Revert this change.
--
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-unsubscribe@hudi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org