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

   ### Purpose
   
   With ignore-delete configured, 0.7- tables could persist lone retract 
records into data files, so a first-row merge group consisting solely of such 
records leaves `FirstRowMergeFunction.getResult()` null. 
`FirstRowMergeFunctionWrapper.getResult()` then dereferenced that null at 
`contains.test(result.key())`, so every compaction of such a key crashed with a 
`NullPointerException`.
   
   This returns the empty result before the contains lookup when the merge 
result is null, matching the existing "nothing to emit" path.
   
   ### Tests
   
   Added `testFirstRowAllRetractRecordsWithIgnoreDelete` in 
`LookupChangelogMergeFunctionWrapperTest`: with ignore-delete, a merge group of 
only DELETE records now yields an empty `ChangelogResult` (null result, no 
changelog) instead of an NPE.
   
   ### API and Format
   
   No.
   
   ### 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