#[non_exhaustive]pub struct RuntimeConfig { /* private fields */ }Expand description
Selects execution for transfer-manager work.
Defaults to owned managed execution. Configuring HTTP on the SDK or S3 configuration does not change this selection.
use aws_s3_transfer::{config::Managed, config::RuntimeConfig};
let managed = RuntimeConfig::managed(Managed::default());
let caller_runtime = RuntimeConfig::multi_thread_tokio();§HTTP transport
With managed execution and no HTTP client configured, the transfer manager builds its own transport:
- One connection pool, partitioned by managed thread, so each connection is driven by the thread that opened it.
- Connections per host capped according to the process’s file-descriptor limit. Requests beyond the cap wait for a connection.
- Proxy settings from
HTTP_PROXY,HTTPS_PROXY,ALL_PROXYandNO_PROXY.
wasm targets have no such transport; see Managed.
An HTTP client set on the SdkConfig or S3
configuration replaces this transport: its pool, TLS, DNS and proxy settings
apply, its connections are not partitioned by managed thread, and the
transfer manager does not cap its connections per host. With
multi_thread_tokio, the S3 client uses the
configured HTTP client or, without one, the SDK default.
Configure an HTTP client to change TLS, DNS or connection settings.
Implementations§
Source§impl RuntimeConfig
impl RuntimeConfig
Sourcepub fn multi_thread_tokio() -> Self
pub fn multi_thread_tokio() -> Self
Uses the caller’s Tokio runtime without creating managed threads.
Transfer tasks are spawned on the runtime performing dispatch. Use a multi-thread runtime so concurrent work can execute on different threads. wasm targets are the exception: their threads are unavailable or cooperative, so a current-thread runtime is supported there.
Trait Implementations§
Source§impl Debug for RuntimeConfig
impl Debug for RuntimeConfig
Auto Trait Implementations§
impl Forget for RuntimeConfig
impl Freeze for RuntimeConfig
impl Move for RuntimeConfig
impl RefUnwindSafe for RuntimeConfig
impl Send for RuntimeConfig
impl Sync for RuntimeConfig
impl Unpin for RuntimeConfig
impl UnsafeUnpin for RuntimeConfig
impl UnwindSafe for RuntimeConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more