sekaiga commented on code in PR #5052: URL: https://github.com/apache/hudi/pull/5052#discussion_r850357531
########## hudi-common/src/main/java/org/apache/hudi/common/table/log/AbstractHoodieLogRecordReader.java: ########## @@ -346,6 +349,19 @@ public synchronized void scan(Option<List<String>> keys) { } } + /** + * Check whether the current instants are valid + * + * @param instantTime + * @return + */ + private boolean checkIfValidCommit(String instantTime) { + HoodieTimeline deltaCommitTimeline = this.hoodieTableMetaClient.getActiveTimeline().getDeltaCommitTimeline().filterCompletedInstants(); + return deltaCommitTimeline.containsInstant(instantTime) || + (deltaCommitTimeline.isBeforeTimelineStarts(instantTime) && + this.hoodieTableMetaClient.getArchivedTimeline().getDeltaCommitTimeline().filterCompletedInstants().containsOrBeforeTimelineStarts(instantTime)); Review Comment: we should compare the instantTime with active timeline and archived timeline. not just active timeline -- 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