pub trait FetchTransport:
Send
+ Sync
+ 'static {
// Required method
fn send(&self, request: Request) -> TransportFuture;
}Expand description
A trusted, single-hop transport.
Dropping its future must cancel its work. Implementations must not detach I/O or follow redirects. A network implementation must additionally enforce its resolved-address policy at connection time; an origin allowlist is not DNS or private-network isolation.
Required Methods§
fn send(&self, request: Request) -> TransportFuture
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementations on Foreign Types§
Source§impl<T: FetchTransport + ?Sized> FetchTransport for Arc<T>
Share one transport, such as a network client, between services or routes.
impl<T: FetchTransport + ?Sized> FetchTransport for Arc<T>
Share one transport, such as a network client, between services or routes.