danny0405 commented on code in PR #13580:
URL: https://github.com/apache/hudi/pull/13580#discussion_r2218834600
##########
hudi-client/hudi-client-common/src/main/java/org/apache/hudi/io/FileGroupReaderBasedMergeHandle.java:
##########
@@ -175,11 +221,17 @@ public void write() {
TypedProperties props = TypedProperties.copy(config.getProps());
long maxMemoryPerCompaction =
IOUtils.getMaxMemoryPerCompaction(taskContextSupplier, config);
props.put(HoodieMemoryConfig.MAX_MEMORY_FOR_MERGE.key(),
String.valueOf(maxMemoryPerCompaction));
+ Iterator<T> engineRecordIterator = recordIterator == null
+ ? null : new MappingIterator<>(recordIterator, HoodieRecord::getData);
// Initializes file group reader
- try (HoodieFileGroupReader<T> fileGroupReader =
HoodieFileGroupReader.<T>newBuilder().withReaderContext(readerContext).withHoodieTableMetaClient(hoodieTable.getMetaClient())
-
.withLatestCommitTime(maxInstantTime).withFileSlice(fileSlice).withDataSchema(writeSchemaWithMetaFields).withRequestedSchema(writeSchemaWithMetaFields)
+ try (HoodieFileGroupReader<T> fileGroupReader =
HoodieFileGroupReader.<T>newBuilder()
+
.withReaderContext(readerContext).withHoodieTableMetaClient(hoodieTable.getMetaClient())
+ .withLatestCommitTime(maxInstantTime).withFileSlice(fileSlice != null
? fileSlice :
+ new FileSlice(new HoodieFileGroupId(partitionPath, fileId),
instantTime, baseFileToMerge, Collections.emptyList()))
Review Comment:
`.withFileSlice` is deprecated, we can set up the base file and log files
stream directly now.
--
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]