Repository navigation
Conversation
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Which issue does this PR close?
Related: #6871 (per-operator proxy support for bindings). This RFC proposes the design; implementation lands in follow-up PRs.
Rationale for this change
Bindings cannot configure the HTTP transport of an operator. Every binding builds operators from a flat
HashMap<String, String>, so a user who needs a proxy for one operator must setHTTPS_PROXYprocess-wide, changing the network path of every other operator and thread.Rust users can already replace the transport via
Operator::with_context(op.context().with_http_transport(...)), but areqwest::Clientcannot cross an FFI boundary, so bindings have no equivalent. Layers are already the mechanism OpenDAL uses to expose operator behavior to bindings (RetryLayer,TimeoutLayer,ConcurrentLimitLayer,CapabilityOverrideLayer), andLayer::apply_contextalready owns the transport slot that needs to change.What changes are included in this PR?
A new RFC,
core/core/src/docs/rfcs/0000_http_config.md, proposing:HttpConfigvalue type inopendal-core(proxy,no_proxy,connect_timeout,read_timeout,timeout,user_agent).HttpTransport::configurehook that builds a configured transport; unsupported transports fail withUnsupportedinstead of ignoring options.HttpConfigLayer(cratecore/layers/http-config/) that replaces the operator's transport at construction time, so invalid options fail when the layer is created.Service configuration is untouched: no new config keys, no
ConfiguratororOperatorUrichanges.The RFC documents the replace semantics precisely, including layer-ordering rules (apply before transport-wrapping layers such as
ConcurrentLimitLayer), that the configured transport overrides laterwith_contextreplacements, and why wrapping was rejected (proxy/connect/TLS options must be owned by the client that establishes connections).Are there any user-facing changes?
No code changes yet; documentation only.
Breaking changes
None.
AI Usage Statement
HttpTransport/HttpTransporterinopendal-core, layer replay inOperator, binding layer surfaces, pyo3/jiff conversion) and revised the reference-level sections accordingly: corrected the stated precedence betweenHttpConfigLayerandOperator::with_context, specified rejection ofno_proxywithoutproxy, added credential masking for proxy values in error context, and fixed theTimeoutLayerprecedent claim.