yihua commented on code in PR #20309:
URL: https://github.com/apache/hudi/pull/20309#discussion_r4266993597
##########
hudi-io/src/main/java/org/apache/hudi/io/hfile/HFileDataBlock.java:
##########
@@ -93,8 +93,8 @@ static HFileDataBlock createDataBlockToWrite(HFileContext
context,
* of the data block; the cursor points to the actual first key of the data
block which is
* lexicographically greater than the lookup key.
*/
- int seekTo(HFileCursor cursor, Key key, int blockStartOffsetInFile) {
- int relativeOffset = cursor.getOffset() - blockStartOffsetInFile;
+ int seekTo(HFileCursor cursor, Key key, long blockStartOffsetInFile) {
+ int relativeOffset = (int) (cursor.getOffset() - blockStartOffsetInFile);
Review Comment:
Note that a single block is bounded to <2 GB by the format, so this cast is
safe. The HFile size containing multiple blocks can be larger than 2GB.
--
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]