kerwin-zk opened a new pull request, #8614:
URL: https://github.com/apache/paimon/pull/8614
## Purpose
`DeletionVectorTest` fails when the suite is run with
`spark.paimon.write.use-v2-write=true`.
Its helper `runAndCheckSplitScan` asserts that a DELETE/UPDATE/MERGE on a
deletion-vector append table reads through a `PaimonSplitScan` (the V1
deletion-vector copy-on-write path). However, since #8539 added V2 delta-based
row-level operations, an **unaware-bucket** deletion-vector append table with
V2 write enabled is routed to `PaimonSparkDeltaOperation` / `WriteDelta`, whose
scan side is a *regular pushdown scan* (see
`PaimonSparkDeltaOperation.newScanBuilder`) and therefore produces **no**
`PaimonSplitScan`. The `assert(batchScans.nonEmpty)` then fails:
```
- Paimon DeletionVector: delete for append non-partitioned table with bucket
= -1 *** FAILED ***
ArrayBuffer() was empty DELETE FROM T WHERE id = 2
(DeletionVectorTest.scala:85)
```
With the default (`write.use-v2-write=false`) the suite still exercises the
V1 path, so the failure is only visible when V2 write is enabled. The delta
path itself is functionally correct and covered by `DeltaRowLevelOpsTest`.
## Tests
`runAndCheckSplitScan` now detects the V2 delta plan (`WriteDelta`, via
`EXPLAIN EXTENDED`) and, in that case, just executes the statement instead of
asserting the V1 split scan. Behavior is unchanged for the V1 path (default
config and bucketed deletion-vector append tables), and the suite now passes
under both `write.use-v2-write=false` and `true`.
## API and Format
No public API or format change.
## Documentation
No documentation 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]