suxiaogang223 opened a new issue, #1506: URL: https://github.com/apache/paimon-rust/issues/1506
### Search before asking - [x] I searched the existing issues and PRs. #1476 already provides schema-only C bucket routing, and #1472 defines bucket-only fixed routing. ### Motivation Distributed engines need to group input rows by both Paimon partition and bucket before assigning writer channels. The existing C router returns only bucket IDs. Callers still have to recreate partition equality and routing-input schema rules. ### Solution Extend the existing owned schema-only router with a public Rust partition-and-bucket result and a C Arrow batch result containing a binary partition key and Int32 bucket ID per input row. Export the union of required partition and bucket fields as an Arrow schema. Reuse existing core normalization, partition encoding, bucket functions, C handles and Arrow ownership/free conventions. Preserve existing bucket-only routing behavior. The partition bytes are execution-local equality keys for one frozen schema and SDK implementation, with no persistent cross-version identifier guarantee. Document concurrent read-only routing, exclusive plan mutation/free, input consumption on errors, empty and zero-column batches, and batch-proportional temporary allocations. ### Anything else? The initial joint C route targets fixed buckets. Exposing postpone plans and joint routing as a coherent write/commit contract is a follow-up, while existing bucket-only postpone APIs retain their behavior. Dynamic-bucket coordination and memory-pool callbacks are separate work. Tests should cover Java goldens and writer metadata parity, projection/order errors, NULLs, scalar edge cases, and Arrow lifecycle. This proposal was prepared with AI assistance. ### Willingness to contribute - [x] I'm willing to submit a PR! -- 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]
