Enum s3_server::errors::S3ErrorCode
source · [−]#[non_exhaustive]
pub enum S3ErrorCode {
Show 85 variants
AccessDenied,
AccountProblem,
AllAccessDisabled,
AmbiguousGrantByEmailAddress,
AuthorizationHeaderMalformed,
BadDigest,
BucketAlreadyExists,
BucketAlreadyOwnedByYou,
BucketNotEmpty,
CredentialsNotSupported,
CrossLocationLoggingProhibited,
EntityTooSmall,
EntityTooLarge,
ExpiredToken,
IllegalLocationConstraintException,
IllegalVersioningConfigurationException,
IncompleteBody,
IncorrectNumberOfFilesInPostRequest,
InlineDataTooLarge,
InternalError,
InvalidAccessKeyId,
InvalidAddressingHeader,
InvalidArgument,
InvalidBucketName,
InvalidBucketState,
InvalidDigest,
InvalidEncryptionAlgorithmError,
InvalidLocationConstraint,
InvalidObjectState,
InvalidPart,
InvalidPartOrder,
InvalidPayer,
InvalidPolicyDocument,
InvalidRange,
InvalidRequest,
InvalidSecurity,
InvalidSOAPRequest,
InvalidStorageClass,
InvalidTargetBucketForLogging,
InvalidToken,
InvalidURI,
KeyTooLongError,
MalformedACLError,
MalformedPOSTRequest,
MalformedXML,
MaxMessageLengthExceeded,
MaxPostPreDataLengthExceededError,
MetadataTooLarge,
MethodNotAllowed,
MissingAttachment,
MissingContentLength,
MissingRequestBodyError,
MissingSecurityElement,
MissingSecurityHeader,
NoLoggingStatusForKey,
NoSuchBucket,
NoSuchBucketPolicy,
NoSuchKey,
NoSuchLifecycleConfiguration,
NoSuchUpload,
NoSuchVersion,
NotImplemented,
NotSignedUp,
NotSupported,
ObjectNotInActiveTierError,
OperationAborted,
PermanentRedirect,
PreconditionFailed,
Redirect,
RestoreAlreadyInProgress,
RequestIsNotMultiPartContent,
RequestTimeout,
RequestTimeTooSkewed,
RequestTorrentOfBucketError,
ServerSideEncryptionConfigurationNotFoundError,
ServiceUnavailable,
SignatureDoesNotMatch,
SlowDown,
TemporaryRedirect,
TokenRefreshRequired,
TooManyBuckets,
UnexpectedContent,
UnresolvableGrantByEmailAddress,
UserKeyMustBeSpecified,
XAmzContentSHA256Mismatch,
}
Expand description
S3 error code enum
See ErrorResponses
Variants (Non-exhaustive)
This enum is marked as non-exhaustive
AccessDenied
Access Denied
AccountProblem
There is a problem with your AWS account that prevents the operation from completing successfully.
AllAccessDisabled
All access to this Amazon S3 resource has been disabled.
AmbiguousGrantByEmailAddress
The email address you provided is associated with more than one account.
AuthorizationHeaderMalformed
The authorization header you provided is invalid.
BadDigest
The Content-MD5 you specified did not match what we received.
BucketAlreadyExists
The requested bucket name is not available. The bucket namespace is shared by all users of the system. Please select a different name and try again.
BucketAlreadyOwnedByYou
The bucket you tried to create already exists, and you own it. Amazon S3 returns this error in all AWS Regions except us-east-1 (N. Virginia). For legacy compatibility, if you re-create an existing bucket that you already own in us-east-1, Amazon S3 returns <code class="code">200 OK and resets the bucket access control lists (ACLs).
BucketNotEmpty
The bucket you tried to delete is not empty.
CredentialsNotSupported
This request does not support credentials.
CrossLocationLoggingProhibited
Cross-location logging not allowed. Buckets in one geographic location cannot log information to a bucket in another location.
EntityTooSmall
Your proposed upload is smaller than the minimum allowed object size.
EntityTooLarge
Your proposed upload exceeds the maximum allowed object size.
ExpiredToken
The provided token has expired.
IllegalLocationConstraintException
Indicates that you are attempting to access a bucket from a different region than where the bucket exists. To avoid this error, use the <code class="code">–region option. For example: <code class="code">aws s3 cp awsexample.txt s3://testbucket/ –region ap-east-1.
IllegalVersioningConfigurationException
Indicates that the versioning configuration specified in the request is invalid.
IncompleteBody
You did not provide the number of bytes specified by the Content-Length HTTP header.
IncorrectNumberOfFilesInPostRequest
POST requires exactly one file upload per request.
InlineDataTooLarge
Inline data exceeds the maximum allowed size.
InternalError
We encountered an internal error. Please try again.
InvalidAccessKeyId
The AWS access key ID you provided does not exist in our records.
InvalidAddressingHeader
You must specify the Anonymous role.
InvalidArgument
Invalid Argument
InvalidBucketName
The specified bucket is not valid.
InvalidBucketState
The request is not valid with the current state of the bucket.
InvalidDigest
The Content-MD5 you specified is not valid.
InvalidEncryptionAlgorithmError
The encryption request you specified is not valid. The valid value is AES256.
InvalidLocationConstraint
The specified location constraint is not valid. For more information about Regions, see How to Select a Region for Your Buckets.
InvalidObjectState
The operation is not valid for the current state of the object.
InvalidPart
One or more of the specified parts could not be found. The part might not have been uploaded, or the specified entity tag might not have matched the part’s entity tag.
InvalidPartOrder
The list of parts was not in ascending order. Parts list must be specified in order by part number.
InvalidPayer
All access to this object has been disabled.
InvalidPolicyDocument
The content of the form does not meet the conditions specified in the policy document.
InvalidRange
The requested range cannot be satisfied.
InvalidRequest
Possible cases:
- Please use AWS4-HMAC-SHA256.
- SOAP requests must be made over an HTTPS connection.
- Amazon S3 Transfer Acceleration is not supported for buckets with non-DNS compliant names.
- Amazon S3 Transfer Acceleration is not supported for buckets with periods (.) in their names.
- Amazon S3 Transfer Accelerate endpoint only supports virtual style requests.
- Amazon S3 Transfer Accelerate is not configured on this bucket.
- Amazon S3 Transfer Accelerate is disabled on this bucket.
- Amazon S3 Transfer Acceleration is not supported on this bucket. Contact AWS Support for more information.
- Amazon S3 Transfer Acceleration cannot be enabled on this bucket. Contact AWS Support for more information.
InvalidSecurity
The provided security credentials are not valid.
InvalidSOAPRequest
The SOAP request body is invalid.
InvalidStorageClass
The storage class you specified is not valid.
InvalidTargetBucketForLogging
The target bucket for logging does not exist, is not owned by you, or does not have the appropriate grants for the log-delivery group.
InvalidToken
The provided token is malformed or otherwise invalid.
InvalidURI
Couldn’t parse the specified URI.
KeyTooLongError
Your key is too long.
MalformedACLError
The XML you provided was not well-formed or did not validate against our published schema.
MalformedPOSTRequest
The body of your POST request is not well-formed multipart/form-data.
MalformedXML
This happens when the user sends malformed XML (XML that doesn’t conform to the published XSD) for the configuration. The error message is, "The XML you provided was not well-formed or did not validate against our published schema."
MaxMessageLengthExceeded
Your request was too big.
MaxPostPreDataLengthExceededError
Your POST request fields preceding the upload file were too large.
MetadataTooLarge
Your metadata headers exceed the maximum allowed metadata size.
MethodNotAllowed
The specified method is not allowed against this resource.
MissingAttachment
A SOAP attachment was expected, but none were found.
MissingContentLength
You must provide the Content-Length HTTP header.
MissingRequestBodyError
This happens when the user sends an empty XML document as a request. The error message is, "Request body is empty."
MissingSecurityElement
The SOAP 1.1 request is missing a security element.
MissingSecurityHeader
Your request is missing a required header.
NoLoggingStatusForKey
There is no such thing as a logging status subresource for a key.
NoSuchBucket
The specified bucket does not exist.
NoSuchBucketPolicy
The specified bucket does not have a bucket policy.
NoSuchKey
The specified key does not exist.
NoSuchLifecycleConfiguration
The lifecycle configuration does not exist.
NoSuchUpload
The specified multipart upload does not exist. The upload ID might be invalid, or the multipart upload might have been aborted or completed.
NoSuchVersion
Indicates that the version ID specified in the request does not match an existing version.
NotImplemented
A header you provided implies functionality that is not implemented.
NotSignedUp
Your account is not signed up for the Amazon S3 service. You must sign up before you can use Amazon S3.
NotSupported
[Custom error code]
ObjectNotInActiveTierError
The source object of the COPY operation is not in the active tier and is only stored in Amazon S3 Glacier.
OperationAborted
A conflicting conditional operation is currently in progress against this resource. Try again.
PermanentRedirect
The bucket you are attempting to access must be addressed using the specified endpoint. Send all future requests to this endpoint.
PreconditionFailed
At least one of the preconditions you specified did not hold.
Redirect
Temporary redirect.
RestoreAlreadyInProgress
Object restore is already in progress.
RequestIsNotMultiPartContent
Bucket POST must be of the enclosure-type multipart/form-data.
RequestTimeout
Your socket connection to the server was not read from or written to within the timeout period.
RequestTimeTooSkewed
The difference between the request time and the server’s time is too large.
RequestTorrentOfBucketError
Requesting the torrent file of a bucket is not permitted.
ServerSideEncryptionConfigurationNotFoundError
The server-side encryption configuration was not found.
ServiceUnavailable
Reduce your request rate.
SignatureDoesNotMatch
The request signature we calculated does not match the signature you provided. Check your AWS secret access key and signing method. For more information, see REST Authentication and SOAP Authentication for details.
SlowDown
Reduce your request rate.
TemporaryRedirect
You are being redirected to the bucket while DNS updates.
TokenRefreshRequired
The provided token must be refreshed.
TooManyBuckets
You have attempted to create more buckets than allowed.
UnexpectedContent
This request does not support content.
UnresolvableGrantByEmailAddress
The email address you provided does not match any account on record.
UserKeyMustBeSpecified
The bucket POST must contain the specified field name. If it is specified, check the order of the fields.
XAmzContentSHA256Mismatch
[Custom error code]
Implementations
sourceimpl S3ErrorCode
impl S3ErrorCode
sourcepub const fn as_status_code(self) -> Option<StatusCode>
pub const fn as_status_code(self) -> Option<StatusCode>
Returns a corresponding status code of the error code
sourcepub const fn as_static_str(self) -> &'static str
pub const fn as_static_str(self) -> &'static str
Returns a corresponding string of the error code
Trait Implementations
sourceimpl Clone for S3ErrorCode
impl Clone for S3ErrorCode
sourcefn clone(&self) -> S3ErrorCode
fn clone(&self) -> S3ErrorCode
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for S3ErrorCode
impl Debug for S3ErrorCode
sourceimpl Display for S3ErrorCode
impl Display for S3ErrorCode
impl Copy for S3ErrorCode
Auto Trait Implementations
impl RefUnwindSafe for S3ErrorCode
impl Send for S3ErrorCode
impl Sync for S3ErrorCode
impl Unpin for S3ErrorCode
impl UnwindSafe for S3ErrorCode
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more