pub enum CloudFrontError {
NoSuchResource {
code: &'static str,
message: String,
},
InvalidArgument(String),
MissingArgument(String),
ResourceInUse(String),
DistributionNotDisabled(String),
PreconditionFailed(String),
InvalidIfMatchVersion(String),
MalformedInput(String),
AlreadyExists {
code: &'static str,
message: String,
},
NotImplemented(String),
AccessDenied(String),
Internal(String),
}Expand description
Top-level CloudFront service error.
Each variant maps to an AWS error Code and an HTTP status.
Variants§
NoSuchResource
The requested resource does not exist.
Fields
InvalidArgument(String)
The caller submitted an invalid argument.
MissingArgument(String)
The request references an argument that is missing.
ResourceInUse(String)
The resource is already in use.
DistributionNotDisabled(String)
The distribution (or similar config resource) is not currently disabled and therefore cannot be deleted.
PreconditionFailed(String)
If-Match ETag does not match the current resource ETag.
InvalidIfMatchVersion(String)
If-Match header was required but not provided.
MalformedInput(String)
The submitted configuration is invalid (referential integrity, shape).
AlreadyExists
Attempt to create a resource that already exists.
Fields
NotImplemented(String)
Feature not supported / not implemented in Rustack.
AccessDenied(String)
Access denied.
Internal(String)
Generic internal error.
Implementations§
Source§impl CloudFrontError
Constructors for convenience.
impl CloudFrontError
Constructors for convenience.
Sourcepub fn no_such_distribution(id: impl Into<String>) -> Self
pub fn no_such_distribution(id: impl Into<String>) -> Self
“NoSuchDistribution” shortcut.
Sourcepub fn no_such_invalidation(id: impl Into<String>) -> Self
pub fn no_such_invalidation(id: impl Into<String>) -> Self
“NoSuchInvalidation” shortcut.
Sourcepub fn no_such_origin_access_control(id: impl Into<String>) -> Self
pub fn no_such_origin_access_control(id: impl Into<String>) -> Self
“NoSuchOriginAccessControl” shortcut.
Sourcepub fn no_such_oai(id: impl Into<String>) -> Self
pub fn no_such_oai(id: impl Into<String>) -> Self
“NoSuchCloudFrontOriginAccessIdentity” shortcut.
Sourcepub fn no_such_cache_policy(id: impl Into<String>) -> Self
pub fn no_such_cache_policy(id: impl Into<String>) -> Self
“NoSuchCachePolicy” shortcut.
Sourcepub fn no_such_origin_request_policy(id: impl Into<String>) -> Self
pub fn no_such_origin_request_policy(id: impl Into<String>) -> Self
“NoSuchOriginRequestPolicy” shortcut.
Sourcepub fn no_such_response_headers_policy(id: impl Into<String>) -> Self
pub fn no_such_response_headers_policy(id: impl Into<String>) -> Self
“NoSuchResponseHeadersPolicy” shortcut.
Sourcepub fn no_such_public_key(id: impl Into<String>) -> Self
pub fn no_such_public_key(id: impl Into<String>) -> Self
“NoSuchPublicKey” shortcut.
Sourcepub fn no_such_resource(kind: &'static str, id: impl Into<String>) -> Self
pub fn no_such_resource(kind: &'static str, id: impl Into<String>) -> Self
“NoSuchResource” generic shortcut.
Trait Implementations§
Source§impl Debug for CloudFrontError
impl Debug for CloudFrontError
Source§impl Display for CloudFrontError
impl Display for CloudFrontError
Source§impl Error for CloudFrontError
impl Error for CloudFrontError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()