danny0405 commented on code in PR #9871:
URL: https://github.com/apache/hudi/pull/9871#discussion_r1361415820


##########
hudi-common/src/main/java/org/apache/hudi/common/table/timeline/CompletionTimeQueryView.java:
##########
@@ -126,14 +127,18 @@ public Option<String> getCompletionTime(String 
baseInstant, String instantTime)
     if (completionTimeOpt.isPresent()) {
       String completionTime = completionTimeOpt.get();
       if (completionTime.length() != baseInstant.length()) {
+        // MDT uses compaction instant time as [delta_instant] + "001".
+        // For example, "20210101000000_001" is the compaction instant time 
for "20210101000000".
+        // However, in reality, MDT compaction completes in MDT timeline 
before the deltacommit in data timeline.
+        if (baseInstant.length() - instantTime.length() == 3 && 
hasCompactionOperationSuffix(baseInstant)) {
+          return completionTimeOpt;

Review Comment:
   Do you think we should use directly its own real instant time for MDT 
compaction instead of suffixing the delta commit ?
   
   



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