taowenjun commented on issue #9337:
URL: https://github.com/apache/gluten/issues/9337#issuecomment-7242377918

   @liujiayi771 @Zouxxyy Thanks for the earlier discussion and work on Paimon 
native reads. I would like to discuss another possible route for Velox PK/DV 
support, reusing the upstream Velox Paimon connector rather than adding a 
second paimon-cpp reader path.
   
   Upstream Velox has now merged:
   - https://github.com/facebookincubator/velox/pull/20364: primary-key 
merge-on-read for deduplicate / first-row tables.
   - https://github.com/facebookincubator/velox/pull/20678: correct handling of 
unknown delete-row counts in older files.
   - https://github.com/facebookincubator/velox/pull/20556: deletion-vector 
reads.
   
   At Gluten main `048d082e6455` (#13808), the selected IBM Velox `2026_11_26` 
refs have raw PK/DV capabilities but still reject merge-on-read. The Gluten 
`PaimonScanTransformer` also still rejects PK/DV tables and converts splits to 
raw file ranges. Therefore, this is not a proposal to simply remove the 
validation guard.
   
   ### Proposed limited scope
   
   1. Keep the Paimon Java catalog, fixed-snapshot planning and complete 
DataSplit boundaries.
   2. Map the planned table/split metadata into Velox `PaimonTableHandle` and 
`PaimonConnectorSplit`, including schema/field IDs, primary keys, supported 
merge options, file metadata and deletion vectors. Preserve unknown delete 
counts instead of converting them to zero. The existing CH SDK serialized-split 
payload is a reference, not an assumption that Velox can deserialize the same 
bytes.
   3. Add the Paimon connector's native plan/split dispatch. Retain the 
existing append-only path and planning-time fallback for unsupported 
combinations.
   4. Initially validate batch deduplicate reads with ordinary integer/string 
keys. Do not claim partial-update, aggregation, arbitrary schema evolution or 
every sequence configuration is supported.
   
   Our use case is batch analysis of CDC-produced PK tables, including 
DV-enabled tables and older Paimon writer files. We can use fixed snapshots and 
compare with the JVM reader, covering updates, deletes/reinserts, projection, 
non-key filtering and the unknown-delete-count case. Existing 
SeaTunnel-to-ClickHouse validation provides useful business fixtures, but is 
not evidence that this new native path already works. No integration code or 
native runtime validation has been completed for this proposal.
   
   I opened an IBM baseline request here: 
https://github.com/IBM/velox/issues/3027 . A regular baseline update may be 
preferable to a separate backport.
   
   Would this upstream-Velox-connector route fit the project's direction? Is 
anyone already working on the Gluten-side integration, particularly alongside 
the previously mentioned internal paimon-cpp implementation? I would like to 
coordinate the scope and validation first, and am interested in contributing 
the Gluten-side wiring and tests if this is not duplicate work.
   


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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to