manojpec commented on a change in pull request #4449:
URL: https://github.com/apache/hudi/pull/4449#discussion_r780869585
##########
File path:
hudi-common/src/main/java/org/apache/hudi/io/storage/HoodieHFileReader.java
##########
@@ -62,6 +64,7 @@
// Scanner used to read individual keys. This is cached to prevent the
overhead of opening the scanner for each
// key retrieval.
private HFileScanner keyScanner;
+ private final String keyField = HoodieMetadataPayload.SCHEMA_FIELD_ID_KEY;
Review comment:
Unlike HFile writer, readers don't pass in hfile config or any other
writer config. Callers make use of the factory static methods to construct the
reader. Factory and the reader are the hudi-common package and hence it cannot
make use of the hudi-client storage configs where the new hfile properties are
available. Factory can pass in the key schema field as an extra arg, but that
doesn't cover all cases. There are callers who can instantiate HFileReader from
the serialized contents and they are also at the hudi-common package level with
no access to new storage configs.
In https://github.com/apache/hudi/pull/4447, I made all the HFileReader
callers to pass in the key schema field and thats what made the patch to touch
a lot of places all around.
--
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]