danny0405 commented on a change in pull request #3267:
URL: https://github.com/apache/hudi/pull/3267#discussion_r670935008
##########
File path:
hudi-common/src/main/java/org/apache/hudi/common/table/log/AbstractHoodieLogRecordScanner.java
##########
@@ -113,8 +120,11 @@ protected AbstractHoodieLogRecordScanner(FileSystem fs,
String basePath, List<St
this.readerSchema = readerSchema;
this.latestInstantTime = latestInstantTime;
this.hoodieTableMetaClient =
HoodieTableMetaClient.builder().setConf(fs.getConf()).setBasePath(basePath).build();
+ this.orderingField =
this.hoodieTableMetaClient.getTableConfig().getPreCombineField();
// load class from the payload fully qualified class name
this.payloadClassFQN =
this.hoodieTableMetaClient.getTableConfig().getPayloadClass();
+ // only the OverwriteWithLatestAvroPayload needs combining by orderingVal
+ this.naturalOrder =
!OverwriteWithLatestAvroPayload.class.isAssignableFrom(ReflectionUtils.getClass(this.payloadClassFQN));
Review comment:
One problem is that may pay load impls implement the interface
`HoodieRecordPayload` directly, and there is no need to do preCombine for them.
--
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]