cshuo commented on PR #20366: URL: https://github.com/apache/hudi/pull/20366#issuecomment-6287305800
After further analysis, I think we can address this with two changes: - **Use a converter in `HoodieEmptyRecord`.** Keep the engine ordering value for comparisons and convert it to Java only when `getOrderingValueAsJava` is called, instead of eagerly creating and storing a second value. A shared, stateless converter avoids allocating a converter per record or retaining the reader context. - **Align the reader and writer record contexts for native log compaction.** The native delete writer should use the same record context that produced the ordering values. This removes the need for special-case logic in `HoodieNativeLogFormatWriter` to handle empty records from a different context. The storage-form conversion in [#20373](https://github.com/apache/hudi/pull/20373) is still needed. I've put together an alternative implementation along these lines in [#20396](https://github.com/apache/hudi/pull/20396). All six log compaction regression cases from this PR pass with that implementation. Feedback and review are welcome! -- 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]
