CloudError

Enum CloudError 

Source
pub enum CloudError {
Show 34 variants ClientInit(String), ProviderNotEnabled(String), SecretFetch { name: String, error: String, }, SecretCreate { name: String, error: String, }, SecretUpdate { name: String, error: String, }, SecretDelete { name: String, error: String, }, SecretFormat { name: String, reason: String, }, SecretList(String), SecretNotFound(String), StorageFetch { key: String, error: String, }, StorageRead { key: String, error: String, }, StoragePut { key: String, error: String, }, StorageDelete { key: String, error: String, }, StorageList { prefix: String, error: String, }, StorageObjectNotFound(String), MetricsExport(String), LogWrite(String), LogExport(String), TraceSpanCreate(String), TraceExport(String), AuthFailed(String), AuthorizationFailed(String), InvalidCredentials(String), ConfigError(String), MissingConfig(String), InvalidConfig { key: String, reason: String, }, Network(String), Connection(String), Timeout(String), Authentication(String), Serialization(String), Deserialization(String), OperationFailed(String), Internal(String),
}
Expand description

Unified cloud error type for all cloud operations.

Variants§

§

ClientInit(String)

§

ProviderNotEnabled(String)

§

SecretFetch

Fields

§name: String
§error: String
§

SecretCreate

Fields

§name: String
§error: String
§

SecretUpdate

Fields

§name: String
§error: String
§

SecretDelete

Fields

§name: String
§error: String
§

SecretFormat

Fields

§name: String
§reason: String
§

SecretList(String)

§

SecretNotFound(String)

§

StorageFetch

Fields

§error: String
§

StorageRead

Fields

§error: String
§

StoragePut

Fields

§error: String
§

StorageDelete

Fields

§error: String
§

StorageList

Fields

§prefix: String
§error: String
§

StorageObjectNotFound(String)

§

MetricsExport(String)

§

LogWrite(String)

§

LogExport(String)

§

TraceSpanCreate(String)

§

TraceExport(String)

§

AuthFailed(String)

§

AuthorizationFailed(String)

§

InvalidCredentials(String)

§

ConfigError(String)

§

MissingConfig(String)

§

InvalidConfig

Fields

§reason: String
§

Network(String)

§

Connection(String)

§

Timeout(String)

§

Authentication(String)

§

Serialization(String)

§

Deserialization(String)

§

OperationFailed(String)

§

Internal(String)

Implementations§

Source§

impl CloudError

Source

pub fn secret_fetch( name: impl Into<String>, error: impl Into<String>, ) -> CloudError

Creates a new SecretFetch error.

Source

pub fn secret_create( name: impl Into<String>, error: impl Into<String>, ) -> CloudError

Creates a new SecretCreate error.

Source

pub fn secret_update( name: impl Into<String>, error: impl Into<String>, ) -> CloudError

Creates a new SecretUpdate error.

Source

pub fn storage_fetch( key: impl Into<String>, error: impl Into<String>, ) -> CloudError

Creates a new StorageFetch error.

Source

pub fn storage_put( key: impl Into<String>, error: impl Into<String>, ) -> CloudError

Creates a new StoragePut error.

Source

pub fn secret_delete( name: impl Into<String>, error: impl Into<String>, ) -> CloudError

Creates a new SecretDelete error.

Source

pub fn storage_delete( key: impl Into<String>, error: impl Into<String>, ) -> CloudError

Creates a new StorageDelete error.

Source

pub fn storage_read( key: impl Into<String>, error: impl Into<String>, ) -> CloudError

Creates a new StorageRead error.

Source

pub fn storage_get( key: impl Into<String>, error: impl Into<String>, ) -> CloudError

Alias for storage_fetch (for compatibility).

Source

pub fn storage_list( prefix: impl Into<String>, error: impl Into<String>, ) -> CloudError

Creates a new StorageList error.

Trait Implementations§

Source§

impl Debug for CloudError

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
Source§

impl Display for CloudError

Source§

fn fmt(&self, __formatter: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
Source§

impl Error for CloudError

1.30.0 · Source§

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

👎Deprecated since 1.42.0: use the Display impl or to_string()
1.0.0 · Source§

fn cause(&self) -> Option<&dyn Error>

👎Deprecated since 1.33.0: replaced by Error::source, which can support downcasting
Source§

fn provide<'a>(&'a self, request: &mut Request<'a>)

🔬This is a nightly-only experimental API. (error_generic_member_access)
Provides type-based access to context intended for error reports. Read more
Source§

impl From<Error> for CloudError

Source§

fn from(err: Error) -> CloudError

Converts to this type from the input type.
Source§

impl From<Error> for CloudError

Source§

fn from(err: Error) -> CloudError

Converts to this type from the input type.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.