#[non_exhaustive]pub enum S3Error {
#[non_exhaustive] Status {
status: u16,
code: Option<String>,
request_id: Option<String>,
},
Transport(Arc<dyn Error + Send + Sync>),
TimedOut,
DeadlineExceeded,
SourceRead(Arc<Error>),
InvalidResponse(&'static str),
InvalidArgument(&'static str),
Cache(Arc<Error>),
}Expand description
Why an S3 call, or the cache directory of the backend, failed.
The text of an error and its Debug output carry the HTTP status, the
error code and the request id of the store’s answer. They never carry
credentials, signatures or the body of a response.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
#[non_exhaustive]Status
The store answered with an error status, or with an error document under a success status.
Fields
This variant is marked as non-exhaustive
Non-exhaustive enum variants could have additional fields added in future. Therefore, non-exhaustive enum variants cannot be constructed in external crates and cannot be matched against.
Transport(Arc<dyn Error + Send + Sync>)
No answer: the connection, the TLS handshake, the request or the response body failed.
TimedOut
Nothing was sent or received for 60 seconds.
DeadlineExceeded
The deadline of the call passed.
SourceRead(Arc<Error>)
The data to send could not be read from its file.
InvalidResponse(&'static str)
The answer breaks what the call expects of it.
InvalidArgument(&'static str)
A setting or argument cannot be used. The text names it.
Cache(Arc<Error>)
The cache directory could not be read or written.
Trait Implementations§
Source§impl Error for S3Error
impl Error for S3Error
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl !RefUnwindSafe for S3Error
impl !UnwindSafe for S3Error
impl Forget for S3Error
impl Freeze for S3Error
impl Move for S3Error
impl Send for S3Error
impl Sync for S3Error
impl Unpin for S3Error
impl UnsafeUnpin for S3Error
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
Mutably borrows from an owned value. Read more