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

   ### Purpose
   
   DataInputDeserializer.readLine() drops the final byte of an unterminated 
line: reading "ab" returns "a". It also continues past a lone carriage return, 
consuming the following line or binary payload.
   
   Read each byte before checking for the next one, recognize LF, CR and CRLF, 
and keep CRLF lookahead within the configured buffer slice. This updates the 
existing implementation to follow the [JDK 8 DataInput 
contract](https://docs.oracle.com/javase/8/docs/api/java/io/DataInput.html#readLine--).
 Other deserialization methods and serialized formats are unchanged.
   
   ### Tests
   
   ```sh
   mvn -o -B -ntp -pl paimon-common -am -DwildcardSuites=none 
-DfailIfNoTests=false -Dtest=DataInputDeserializerTest,DataOutputSerializerTest 
test
   ```
   
   Windows 11, JDK 8u451, Maven 3.8.9, baseline 
1902379e544e233b9ca9ec4d452db796a53c3f0e: 22 tests, 9 failures before the fix; 
the same 22 tests pass after it. No fast-build profile was used.
   
   The regression tests compare returned lines, remaining bytes and cursor 
positions with JDK DataInputStream, including bounded slices and unsigned 
bytes. Mixed line/binary tests read int, long and UTF values written by JDK 
DataOutputStream. The existing DataOutputSerializerTest also passes.
   
   Spotless and Enforcer passed. Both changed files passed Checkstyle 8.14 with 
the project configuration in a separate directory outside the target-path 
suppression. Local verification did not include Linux, full-module or 
Flink/Spark suites, or the verify-phase RAT check.
   
   The publication branch is based on 0369648333b9278d4d61a0768cf355f3299ec111. 
Its selected parent/API/test-utils/common build inputs and reviewed files match 
the tested baseline above, and the patch is unchanged. Local tests were not 
rerun for this base change.
   


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