GroveError

Enum GroveError 

Source
pub enum GroveError {
Show 20 variants ExtensionNotFound { extension_id: String, message: Option<String>, }, ExtensionLoadFailed { extension_id: String, reason: String, path: Option<String>, }, ActivationFailed { extension_id: String, reason: String, }, DeactivationFailed { extension_id: String, reason: String, }, WASMRuntimeError { reason: String, module_id: Option<String>, }, WASMCompilationFailed { reason: String, module_path: Option<String>, }, WASMModuleNotFound { module_id: String, }, TransportError { transport_type: String, reason: String, }, ConnectionError { endpoint: String, reason: String, }, APIError { api_method: String, reason: String, error_code: Option<i32>, }, ConfigurationError { key: String, reason: String, }, IoError { path: Option<String>, operation: String, reason: String, }, SerializationError { type_name: String, reason: String, }, DeserializationError { type_name: String, reason: String, }, Timeout { operation: String, timeout_ms: u64, }, InvalidArgument { argument_name: String, reason: String, }, NotImplemented { feature: String, }, PermissionDenied { resource: String, reason: String, }, ResourceExhausted { resource: String, reason: String, }, InternalError { reason: String, backtrace: Option<String>, },
}
Expand description

Grove error type

Variants§

§

ExtensionNotFound

Extension not found error

Fields

§extension_id: String

The extension identifier

§message: Option<String>

Optional error message

§

ExtensionLoadFailed

Extension loading failed error

Fields

§extension_id: String

The extension identifier

§reason: String

The failure reason

§path: Option<String>

Optional path to the extension

§

ActivationFailed

Extension activation failed error

Fields

§extension_id: String

The extension identifier

§reason: String

The failure reason

§

DeactivationFailed

Extension deactivation failed error

Fields

§extension_id: String

The extension identifier

§reason: String

The failure reason

§

WASMRuntimeError

WASM runtime error

Fields

§reason: String

The error reason

§module_id: Option<String>

Optional module identifier

§

WASMCompilationFailed

WASM compilation failed error

Fields

§reason: String

The failure reason

§module_path: Option<String>

Optional path to the module

§

WASMModuleNotFound

WASM module not found error

Fields

§module_id: String

The module identifier

§

TransportError

Transport error

Fields

§transport_type: String

The transport type

§reason: String

The error reason

§

ConnectionError

Connection error

Fields

§endpoint: String

The endpoint that failed

§reason: String

The error reason

§

APIError

API call error

Fields

§api_method: String

The API method that failed

§reason: String

The error reason

§error_code: Option<i32>

Optional error code

§

ConfigurationError

Configuration error

Fields

§key: String

The configuration key

§reason: String

The error reason

§

IoError

I/O error

Fields

§path: Option<String>

Optional path related to the error

§operation: String

The operation that failed

§reason: String

The error reason

§

SerializationError

Serialization error

Fields

§type_name: String

The type name being serialized

§reason: String

The error reason

§

DeserializationError

Deserialization error

Fields

§type_name: String

The type name being deserialized

§reason: String

The error reason

§

Timeout

Timeout error

Fields

§operation: String

The operation that timed out

§timeout_ms: u64

The timeout duration in milliseconds

§

InvalidArgument

Invalid argument error

Fields

§argument_name: String

The argument name

§reason: String

The error reason

§

NotImplemented

Not implemented error

Fields

§feature: String

The feature that is not implemented

§

PermissionDenied

Permission denied error

Fields

§resource: String

The resource that was denied

§reason: String

The error reason

§

ResourceExhausted

Resource exhausted error

Fields

§resource: String

The resource that was exhausted

§reason: String

The error reason

§

InternalError

Internal error

Fields

§reason: String

The error reason

§backtrace: Option<String>

Optional backtrace (skipped during serialization)

Implementations§

Source§

impl GroveError

Source

pub fn extension_not_found(extension_id: impl Into<String>) -> Self

Create extension not found error

Source

pub fn extension_load_failed( extension_id: impl Into<String>, reason: impl Into<String>, ) -> Self

Create extension load failed error

Source

pub fn activation_failed( extension_id: impl Into<String>, reason: impl Into<String>, ) -> Self

Create activation failed error

Source

pub fn wasm_runtime_error(reason: impl Into<String>) -> Self

Create WASM runtime error

Source

pub fn transport_error( transport_type: impl Into<String>, reason: impl Into<String>, ) -> Self

Create transport error

Source

pub fn connection_error( endpoint: impl Into<String>, reason: impl Into<String>, ) -> Self

Create connection error

Source

pub fn api_error( api_method: impl Into<String>, reason: impl Into<String>, ) -> Self

Create API error

Source

pub fn timeout(operation: impl Into<String>, timeout_ms: u64) -> Self

Create timeout error

Source

pub fn invalid_argument( argument_name: impl Into<String>, reason: impl Into<String>, ) -> Self

Create invalid argument error

Source

pub fn not_implemented(feature: impl Into<String>) -> Self

Create not implemented error

Source

pub fn error_code(&self) -> &'static str

Get error code for categorization

Source

pub fn is_recoverable(&self) -> bool

Check if error is recoverable

Source

pub fn is_transient(&self) -> bool

Check if error is transient (can be retried)

Trait Implementations§

Source§

impl Clone for GroveError

Source§

fn clone(&self) -> GroveError

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for GroveError

Source§

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

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

impl<'de> Deserialize<'de> for GroveError

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Display for GroveError

Source§

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

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

impl Error for GroveError

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 GroveError

Convert from std::io::Error

Source§

fn from(err: Error) -> Self

Converts to this type from the input type.
Source§

impl From<Error> for GroveError

Convert from serde_json::Error

Source§

fn from(err: Error) -> Self

Converts to this type from the input type.
Source§

impl Serialize for GroveError

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

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> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> FromRef<T> for T
where T: Clone,

§

fn from_ref(input: &T) -> T

Converts to this type from a reference to the input type.
§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
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> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts 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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts 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
Source§

impl<T> IntoRequest<T> for T

Source§

fn into_request(self) -> Request<T>

Wrap the input message T in a tonic::Request
§

impl<T> Pointable for T

§

const ALIGN: usize

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> Serializable for T
where T: Serialize + for<'de> Deserialize<'de>,

Source§

fn to_json(&self) -> Result<String>

Serialize to JSON string
Source§

fn to_json_pretty(&self) -> Result<String>

Serialize to JSON pretty string
Source§

fn from_json(json: &str) -> Result<Self>
where Self: Sized,

Deserialize from JSON string
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
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.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

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
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,