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

[GitHub] [hudi] xushiyan commented on a diff in pull request #7740: [HUDI-5464] Suffix instant time for metadata partition init deltacommit

xushiyan commented on code in PR #7740:
URL: https://github.com/apache/hudi/pull/7740#discussion_r1085799867


##########
hudi-client/hudi-client-common/src/main/java/org/apache/hudi/metadata/HoodieBackedTableMetadataWriter.java:
##########
@@ -1040,7 +1043,13 @@ protected void compactIfNecessary(BaseHoodieWriteClient writeClient, String inst
     // Trigger compaction with suffixes based on the same instant time. This ensures that any future
     // delta commits synced over will not have an instant time lesser than the last completed instant on the
     // metadata table.
-    final String compactionInstantTime = latestDeltaCommitTimeInMetadataTable + METADATA_COMPACTION_TIME_SUFFIX;
+    if (latestDeltaCommitTimeInMetadataTable.length() > MILLIS_INSTANT_TIMESTAMP_FORMAT_LENGTH) {
+      checkState(latestDeltaCommitTimeInMetadataTable.endsWith(METADATA_TABLE_INIT_TIME_SUFFIX),

Review Comment:
   make sense to skip compaction in this case



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