suxiaogang223 opened a new pull request, #522:
URL: https://github.com/apache/paimon-rust/pull/522

   ## Summary
   
   Add write-side C FFI bindings (`bindings/c/src/write.rs`) following the same 
opaque handle / `extern "C"` patterns as the existing read-side bindings. 
Closes #520.
   
   ## API surface (14 functions)
   
   ```
   // WriteBuilder
   paimon_table_new_write_builder(table)        → paimon_result_write_builder
   paimon_write_builder_free(wb)                → void
   paimon_write_builder_with_overwrite(wb)      → *mut paimon_error
   paimon_write_builder_new_write(wb)           → paimon_result_table_write
   paimon_write_builder_new_commit(wb)          → paimon_result_table_commit
   
   // TableWrite
   paimon_table_write_free(tw)                  → void
   paimon_table_write_write_arrow_batch(tw, array, schema) → *mut paimon_error
   paimon_table_write_prepare_commit(tw)        → paimon_result_prepare_commit
   
   // TableCommit
   paimon_table_commit_free(tc)                 → void
   paimon_table_commit_commit(tc, msgs)         → *mut paimon_error
   paimon_table_commit_overwrite(tc, msgs)      → *mut paimon_error
   paimon_table_commit_truncate_table(tc)       → *mut paimon_error
   paimon_table_commit_abort(tc, msgs)          → *mut paimon_error
   
   // CommitMessages
   paimon_commit_messages_free(msgs)            → void
   ```
   
   ## Design decisions
   
   - **In-process transfer**: CommitMessages are passed as opaque handles (no 
serialization), matching Python bindings
   - **Shared commit_user**: WriteBuilder generates a UUID shared by writer and 
committer
   - **Arrow C Data Interface**: Batch import via 
`FFI_ArrowArray`/`FFI_ArrowSchema` raw pointers
   
   ## Tests (15 cases, all passing)
   
   - Read path (3), Predicate (3), Write path (7), Error handling (1), 
Integration (1)
   
   Run: `cargo +1.91.0 test -p paimon-c`


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

Reply via email to