luoyuxia opened a new pull request, #2880:
URL: https://github.com/apache/fluss/pull/2880

   ### Purpose
   
   Linked issue: close #2879
   
   This PR backports the `$binlog` update-pairing fix to `release-0.9`.
   
   When one Flink `SourceReader` processes records from multiple log splits, 
`$binlog`
   can interleave `UPDATE_BEFORE` / `UPDATE_AFTER` records from different 
splits.
   The previous implementation kept only one global pending `UPDATE_BEFORE` 
record,
   which could be overwritten by another split and then fail with:
   
   ```text
   Received UPDATE_AFTER (+U) without a preceding UPDATE_BEFORE (-U) record.
   ```
   
   ### Brief change log
   
   - keep pending `UPDATE_BEFORE` state per split instead of using one global 
buffer;
   - pass the current split id through the emitter/deserialization path for 
`$binlog`;
   - pair `UPDATE_BEFORE` and `UPDATE_AFTER` only within the same split;
   - add a regression test for cross-split interleaving in 
`BinlogRowConverterTest`.
   
   ### Tests
   
   - Added `BinlogRowConverterTest#testCrossSplitInterleavingDoesNotCorrupt`
   - Not run locally
   
   ### API and Format
   
   No API or storage format changes.
   
   ### Documentation
   
   No.
   


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