nsivabalan commented on code in PR #12507:
URL: https://github.com/apache/hudi/pull/12507#discussion_r1889485106
##########
hudi-common/src/main/java/org/apache/hudi/metadata/HoodieTableMetadataUtil.java:
##########
@@ -2228,9 +2229,17 @@ public static HoodieData<HoodieRecord>
readSecondaryKeysFromBaseFiles(HoodieEngi
engineContext.setJobStatus(activeModule, "Secondary Index: reading
secondary keys from " + partitionFiles.size() + " partitions");
return engineContext.parallelize(partitionFiles,
parallelism).flatMap(partitionWithBaseAndLogFiles -> {
final String partition = partitionWithBaseAndLogFiles.getKey();
+ // get the log files for the partition and group them by fileId
+ Map<String, List<HoodieLogFile>> logFilesByFileId =
getPartitionLatestFileSlicesIncludingInflight(metaClient, Option.of(fsView),
partition).stream()
Review Comment:
typically our FSV may not have inflight files. So, how do we know we are
getting the inflights here? can you throw some light please
##########
hudi-common/src/main/java/org/apache/hudi/metadata/HoodieTableMetadataUtil.java:
##########
@@ -2228,9 +2229,17 @@ public static HoodieData<HoodieRecord>
readSecondaryKeysFromBaseFiles(HoodieEngi
engineContext.setJobStatus(activeModule, "Secondary Index: reading
secondary keys from " + partitionFiles.size() + " partitions");
return engineContext.parallelize(partitionFiles,
parallelism).flatMap(partitionWithBaseAndLogFiles -> {
final String partition = partitionWithBaseAndLogFiles.getKey();
+ // get the log files for the partition and group them by fileId
+ Map<String, List<HoodieLogFile>> logFilesByFileId =
getPartitionLatestFileSlicesIncludingInflight(metaClient, Option.of(fsView),
partition).stream()
Review Comment:
actually lets sync up on this. I have a slightly diff approach to make this
more optimized.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]