chitralverma opened a new issue, #9326:
URL: https://github.com/apache/opendal/issues/9326

   
   *Drafted with AI assistance (Claude Code, Claude Opus 5.5, effort xhigh); 
the author is accountable for it.*
   
   ### Feature Description
   
   Expose core's operation options in the OCaml binding and generate them from 
core. Part of #9320.
   
   **The API shape needs to be agreed first. This is not planned immediately.**
   
   ### Problem and Solution
   
   **Current code** (links point at `4ae8e61222`):
   
   - No operation takes options. The `blocking_*` externals have fixed 
signatures 
([operator.mli#L151-L162](https://github.com/apache/opendal/blob/4ae8e61222e6d282b2a1ec99db4e87dccacf5919/bindings/ocaml/src/operator.mli#L151-L162)).
   - `blocking_remove_all` sets `recursive` internally 
([operator/mod.rs#L174-L186](https://github.com/apache/opendal/blob/4ae8e61222e6d282b2a1ec99db4e87dccacf5919/bindings/ocaml/src/operator/mod.rs#L174-L186)).
   - `dev/src/generate/ocaml.rs` generates only `Capability` and `Metadata`.
   
   **Missing.** Every core option.
   
   **Questions to settle first**
   
   - Adding optional labelled arguments to the existing functions changes their 
types. That breaks signature ascription and partial application, so options 
probably need new functions (for example `blocking_read_with`) or an agreed 
record type.
   - How OCaml passes timestamps, durations, `user_metadata`, and a `Metadata` 
for `if_not_changed`.
   
   Once the shape is agreed, generate the option types from core with 
`dev/src/generate/ocaml.rs`, as the other bindings do.
   
   ### Additional Context
   
   The same prerequisites apply as for the other bindings: #9319 for write-side 
and compose version conditions, and #9316 for `checksum`.
   
   ### Are you willing to contribute to the development of this feature?
   
   - [ ] Yes, I am willing to contribute to the development of this feature.
   


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