skyyyy955 opened a new pull request, #10916:
URL: https://github.com/apache/paimon/pull/10916

   ### Purpose
   
   When `AbstractPagedInputView.skipBytes` reaches EOF before satisfying the 
request, it counts the final page's remaining bytes but leaves the page cursor 
unchanged. A later read or skip can therefore consume those bytes again. 
Through `DataInputViewStream`, skipping `Integer.MAX_VALUE + 1L` on a 
seven-byte input can even return 10.
   
   Advance the final page cursor before returning the partial count, following 
the existing EOF handling in the bulk-read method.
   
   ### Tests
   
   Validated on Windows 11 with JDK 8u451 and Maven 3.8.9, with normal Maven 
checks enabled:
   
   - 18 new tests cover page boundaries, short final pages, repeated EOF 
operations, seeking back, stream adaptation, and propagation of non-EOF I/O 
errors. Eight fail before the fix; all pass afterward. JDK input streams 
provide independent controls.
   - 11 existing tests in `BinaryRowSerializerLengthTest`, 
`BinaryRowSerializerPageSizeGuardTest`, and `BinaryRowSerializerShrinkTest` 
pass before and after the fix.
   - Checkstyle, Spotless, Enforcer, and `git diff --check` pass.
   
   Linux and the full table/engine suites were not run locally.
   


-- 
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]

Reply via email to