Hi all, Today a compaction fails to commit if any other transaction added a position delete to one of the files it rewrote while it was running. The rewrite is a logical no-op, but RewriteFiles validation can't tell a layout change from a row change, so minutes or hours of work are discarded and retried due to conflicts. Under steady write + delete traffic on hot partitions this happens repeatedly.
I'd like to propose an improvement: the rewrite records how row positions moved from source to output files, and at commit time translates any concurrently committed deletion vectors onto the output files instead of failing. The idea comes from Commutative Compaction (Douglas & Hellerstein, FORMATS '26)[1]; Chris and I have been working through the design together. I have a working Spark implementation with tests and benchmarks and would like to open a PR once there is agreement on the direction. More details in the doc: https://docs.google.com/document/d/1-8T316SMGNWIGzgid5hn0K6xj7hDDMRquleyuQrj3m8 Would appreciate any feedback on the approach! Thanks, Shawn [1] https://dl.acm.org/doi/10.1145/3802514.3809174
