Module client
Available on crate feature
net only.Expand description
generic client net logic
Modules§
Structs§
- Abortable
Connector Service - A
Servicethat runs every established client connection in its own childScopeand cuts its I/O once that scope is aborted, seeAbortableIo. - Boxed
Connector Service - A
ConnectorServicewhich only job is toBoxthe createdServiceby the innerConnectorService. - Bypass
Rules - A compiled set of proxy bypass rules.
- Connect
Request - A protocol-independent request to establish a client connection.
- Connection
Attempt - Requirements and observations for one connection attempt, shared with address races and outer deadlines through request extensions.
- Connection
Attempt Transfer - Gives a child connection an attempt
ConnectionAttempt::dialed_forthe attempt of its parent, if that has one. - Connection
Error - A classified error produced while establishing or using a client connection.
- Connector
Target - Target
HostWithPortwhich if found in extensions is to be used by a connector such as a TCPConnector instead of the requested address, unless a proxy is requested in which case a proxy is to be used instead. - Connector
Target Stream Extensionscarrier for anAddressCandidatessource.- Connector
Transport Protocol - Transport protocol a connector must use for the selected route.
- Dialed
Proxy Connection - Marks a connection to a proxy made by a
ProxyDialer, naming the proxy it was dialed to. - Direct
Only Connector - A connector for a client without proxy support: it serves a route without a proxy and
refuses a proxied
ProxyRouteinstead of connecting around the proxy. - Direct
Only Connector Layer Layerproducing aDirectOnlyConnector.- Established
Client Connection - The established connection to a server returned for the http client to be used.
- Lazy
Proxy Address Layer - Lazily resolve and apply a proxy address to any input with extensions.
- Lazy
Proxy Address Service - Service produced by
LazyProxyAddressLayer. - MapEstablished
Connection - Apply middleware to each connection returned by a connector.
- MapEstablished
Connection Layer - A
Layerthat produces aMapEstablishedConnectionservice. - Maybe
Proxied Connector - Route a client connection directly or through a proxy, making a proxy optional.
- NoProxy
EnvLayer - Lazily apply conventional
NO_PROXYbypass rules. - NoProxy
EnvService - Service produced by
NoProxyEnvLayer. - Plaintext
Proxy Only - The connector towards proxies
PlaintextProxyOnlyLayercreates. - Plaintext
Proxy Only Layer - The TLS stage of a connector towards proxies that has no TLS: it refuses every proxy that asks for TLS, before anything is dialed.
- Proxied
Route - Selects every input with a proxied
ProxyRoute, whichever proxy it names. - Proxy
Address Layer - Apply one fixed proxy address to any service input with extensions.
- Proxy
Address Service - Service produced by
ProxyAddressLayer. - Proxy
Bypass Layer - Apply precompiled
BypassRulesto a service input. - Proxy
Bypass Service - Service produced by
ProxyBypassLayer. - Proxy
Connection Extensions - Connection-scoped extensions for the hop to the proxy.
- Proxy
Connection Extensions Transfer - Moves the contents of
ProxyConnectionExtensionsonto the connection to the proxy, see [proxy_request]. - Proxy
Dial Request - What a
ProxyDialerdials: the connection toproxy, for the origin request whose extensions areorigin. - Proxy
Dialer - Dials the connection to a proxy:
proxy_requestthrough the connector towards proxies it wraps, which hands back that connection. - Proxy
Dialer Layer - Wraps a connector towards proxies in a
ProxyDialer. - Proxy
EnvLayer - Lazily select a proxy from curl-compatible environment variables.
- Proxy
EnvService - Service produced by
ProxyEnvLayer. - Proxy
Route Connect Error - Errors produced by every attempted route of an unsuccessful connection.
- Proxy
Route Failure Cache - Shared negative cache for temporarily failing proxy routes.
- Proxy
Route Failure Cache Config - Configuration for a
ProxyRouteFailureCache. - Proxy
Route Failure Cache Connector - Connector wrapper that applies a shared
ProxyRouteFailureCache. - Proxy
Route Failure Cache Layer - Layer that applies a shared
ProxyRouteFailureCacheto a connector. - Proxy
Route Failure Cached Error - Error returned when a proxy route is still inside its failure backoff.
- Proxy
Route Index - Index of the selected route within the ordered route collection.
- Proxy
Routes - Ordered proxy routes to try while establishing a client connection.
- Proxy
Routes Connector - Try ordered proxy routes until a connection is established.
- Proxy
Routes Connector Layer - Layer that tries ordered proxy routes while establishing a connection.
- Proxy
Routes Layer - Resolve and materialize the route decision for downstream middleware.
- Proxy
Routes Service - Service produced by
ProxyRoutesLayer. - System
Proxy Config - A snapshot of the operating system’s proxy configuration.
- System
Proxy Connect Layer - Adapt a
SystemProxyLayerto connector-levelConnectRequestinputs. - System
Proxy Connect Service - Service produced by
SystemProxyConnectLayer. - System
Proxy Layer - Apply the operating system’s proxy settings to client service inputs.
- System
Proxy PacRequest - The request information passed to a system PAC resolver.
- System
Proxy Service - See
SystemProxyLayer.
Enums§
- Connection
Error Domain - The architectural domain in which establishing or using a client connection failed.
- Connection
Error Kind - A protocol-independent description of a failed connection operation.
- Connection
Policy Scope - Whether an establishment result describes a connector’s fixed policy or a request override. Publish this on established connections or classified errors so discovery and failure caches can scope availability updates correctly.
- Either
Conn - A type to allow you to use multiple types as a single type.
- Either
Conn3 - A type to allow you to use multiple types as a single type.
- Either
Conn4 - A type to allow you to use multiple types as a single type.
- Either
Conn5 - A type to allow you to use multiple types as a single type.
- Either
Conn6 - A type to allow you to use multiple types as a single type.
- Either
Conn7 - A type to allow you to use multiple types as a single type.
- Either
Conn8 - A type to allow you to use multiple types as a single type.
- Either
Conn9 - A type to allow you to use multiple types as a single type.
- Either
Conn3 Connected - A type to allow you to use multiple types as a single type.
- Either
Conn4 Connected - A type to allow you to use multiple types as a single type.
- Either
Conn5 Connected - A type to allow you to use multiple types as a single type.
- Either
Conn6 Connected - A type to allow you to use multiple types as a single type.
- Either
Conn7 Connected - A type to allow you to use multiple types as a single type.
- Either
Conn8 Connected - A type to allow you to use multiple types as a single type.
- Either
Conn9 Connected - A type to allow you to use multiple types as a single type.
- Either
Conn Connected - A type to allow you to use multiple types as a single type.
- Established
Proxy Route - The proxy route actually established by a connector.
- Maybe
Proxied - The connection established by
MaybeProxiedConnector, direct or through a proxy. - Proxy
Route - A requested route through which a client connection should be established.
- Proxy
Route Context - Requested proxy route or ordered route plan used to scope connection outcomes.
- Proxy
Route Failure Cache Scope - Scope used to identify temporarily failing proxy routes.
- System
Proxy Invalid Bypass Rule Policy - How system proxy discovery handles bypass rules Rama cannot parse.
Constants§
- DEFAULT_
SYSTEM_ PROXY_ CONFIG_ TTL - How long a
SystemProxyLayerkeeps a system proxy snapshot before lazily checking for changes.
Traits§
- Address
Candidates - A lazily-resolved source of connection target
IpAddresses. - Connector
Service - Glue trait that is used as the Connector trait bound for clients establishing a connection on one layer or another.
- Proxy
Selector - Decides which side of a
MaybeProxiedConnectorserves an input. - System
Proxy PacResolver - Resolves proxy routes for a request using one system-configured PAC script.
- System
Proxy PacService - Supplies a resolver for a system-configured PAC URI.
Functions§
- proxy_
connection_ reuse - The reuse rules of a connection to a proxy, for the connection that carries
origin requests over it: a tunnel through it, or that connection itself for a
forwarding proxy.
Noneifconnectionis not a connection to a proxy. - proxy_
request - Create the request to establish the connection to
proxyitself. - proxy_
request_ uri - Normalize a request target for fixed-proxy selection and PAC evaluation.
- race_
connect - Race connection attempts over a stream of candidate
SocketAddresses.