pub struct S3Config {Show 15 fields
pub bucket: String,
pub prefix: Option<String>,
pub region: String,
pub endpoint: Option<String>,
pub access_key_id: Option<String>,
pub secret_access_key: Option<String>,
pub allow_http: bool,
pub multipart_threshold: u64,
pub multipart_chunk_size: usize,
pub conditional_put: bool,
pub checksum_sha256: bool,
pub max_retries: usize,
pub retry_timeout: Duration,
pub request_timeout: Duration,
pub connect_timeout: Duration,
}Expand description
Connection and bucket parameters for an S3-compatible backend.
The credentials come either from access_key_id and secret_access_key or
from the standard AWS credential chain. When both fields are None,
object_store falls back to the environment-variable chain.
Debug redacts the credential fields, so a stray {:?} call or tracing
call never leaks them.
Fields§
§bucket: StringS3 bucket name.
prefix: Option<String>Optional key prefix inside the bucket. No leading slash and no trailing slash.
region: StringAWS region. AWS S3 requires it. Use the placeholder "us-east-1" for
MinIO and R2.
endpoint: Option<String>Optional custom endpoint URL, for example http://minio:9000 or an R2
endpoint.
access_key_id: Option<String>Optional explicit access key id. Without it, the backend falls back to the AWS credential chain.
secret_access_key: Option<String>Optional explicit secret access key. Without it, the backend falls back to the AWS credential chain.
allow_http: boolAllow plaintext HTTP. MinIO without TLS requires it.
multipart_threshold: u64Files of at least this size upload with multipart. Defaults to
DEFAULT_MULTIPART_THRESHOLD.
multipart_chunk_size: usizePer-part size for multipart. Defaults to DEFAULT_MULTIPART_CHUNK_SIZE.
conditional_put: boolEnable conditional puts (If-None-Match) so a PutMode::Create write
fails instead of silently overwriting. Defaults to true.
checksum_sha256: boolSend x-amz-checksum-sha256 so the server verifies each object on
ingest. Defaults to true.
max_retries: usizeHow many times one request is retried before the error surfaces.
Defaults to DEFAULT_MAX_RETRIES; 0 disables retries.
retry_timeout: DurationCeiling on the wall-clock time one request may spend across all of its
retries. Defaults to DEFAULT_RETRY_TIMEOUT.
request_timeout: DurationCeiling on one HTTP request. Defaults to DEFAULT_REQUEST_TIMEOUT.
connect_timeout: DurationCeiling on the connect phase alone. Defaults to
DEFAULT_CONNECT_TIMEOUT.
Trait Implementations§
impl Eq for S3Config
impl StructuralPartialEq for S3Config
Auto Trait Implementations§
impl Freeze for S3Config
impl RefUnwindSafe for S3Config
impl Send for S3Config
impl Sync for S3Config
impl Unpin for S3Config
impl UnsafeUnpin for S3Config
impl UnwindSafe for S3Config
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> 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