You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hudi.apache.org by "codope (via GitHub)" <gi...@apache.org> on 2023/08/05 05:29:01 UTC

[GitHub] [hudi] codope commented on a diff in pull request #9370: [HUDI-6650] Do not set default preCombine field for Flink table config

codope commented on code in PR #9370:
URL: https://github.com/apache/hudi/pull/9370#discussion_r1284971137


##########
hudi-flink-datasource/hudi-flink/src/main/java/org/apache/hudi/configuration/OptionsResolver.java:
##########
@@ -126,6 +126,17 @@ public static String getPreCombineField(Configuration conf) {
     return preCombineField.equals(FlinkOptions.NO_PRE_COMBINE) ? null : preCombineField;
   }
 
+  /**
+   * Returns the preCombine field
+   * or null if the value is set as {@link FlinkOptions#NO_PRE_COMBINE} or the user does not config it explicitly.
+   */
+  public static String getPreCombineFieldNoDefaultValue(Configuration conf) {
+    if (!conf.contains(FlinkOptions.PRECOMBINE_FIELD)) {
+      return null;

Review Comment:
   Better to return Option<String>?



-- 
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