yanghua commented on a change in pull request #2640:
URL: https://github.com/apache/hudi/pull/2640#discussion_r590455667



##########
File path: hudi-flink/src/main/java/org/apache/hudi/util/StreamerUtil.java
##########
@@ -332,7 +331,7 @@ public static String getTablePath(FileSystem fs, Path[] 
userProvidedPaths) throw
   public static boolean needsScheduleCompaction(Configuration conf) {
     return conf.getString(FlinkOptions.TABLE_TYPE)
         .toUpperCase(Locale.ROOT)
-        .equals(HoodieTableType.MERGE_ON_READ.name())
+        .equals(FlinkOptions.TABLE_TYPE_MERGE_ON_READ)

Review comment:
       IMO, it's different. Spark referenced the 
`HoodieTableType.COPY_ON_WRITE.name`, but you used a string literal. What I 
mean about the word `define`, is to use a literal directly. In the future, if 
we change the value of `HoodieTableType `, in `DataSourceOptions ` we do not 
need to search the string literal, and we can control all the change points.




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

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


Reply via email to