Skip to main content

StorageError

Enum StorageError 

Source
pub enum StorageError {
Show 15 variants Unhealthy, Precondition { path: String, }, Builder(String), CorruptLog, UnsupportedCommandVersion(u32), OutcomePayload, Durability(String), SnapshotExpired { requested: u64, oldest: u64, }, FutureSnapshot { requested: u64, visible: u64, }, ResourceExhausted(String), InvalidConfiguration(String), Cancelled, InvalidRead(String), ReadersActive, ConflictHistoryUnavailable { commit_index: u64, },
}
Expand description

Errors returned by the storage layer: failed preconditions, corrupt or unsupported durable state, resource exhaustion, and invalid read requests.

Variants§

§

Unhealthy

A poisoned storage lock fenced the store; reopen is required.

§

Precondition

A transaction precondition was violated; path is the offending key.

Fields

§path: String

Key whose precondition failed.

§

Builder(String)

The deterministic expander failed while building a commit.

§

CorruptLog

A durable record could not be decoded or verified.

§

UnsupportedCommandVersion(u32)

A log record carries a command version this build does not support.

§

OutcomePayload

The stored outcome payload is missing or cannot be deserialized.

§

Durability(String)

The physical backend failed while applying or reading durable state.

§

SnapshotExpired

The requested snapshot predates the oldest retained commit.

Fields

§requested: u64

Snapshot commit index that was requested.

§oldest: u64

Oldest commit index still readable.

§

FutureSnapshot

The requested snapshot is newer than the visible commit index.

Fields

§requested: u64

Snapshot commit index that was requested.

§visible: u64

Commit index currently visible.

§

ResourceExhausted(String)

A managed byte budget refused the request.

§

InvalidConfiguration(String)

The supplied storage configuration is not valid.

§

Cancelled

A pinned read was cancelled by its caller.

§

InvalidRead(String)

Scan bounds or batch limits are invalid.

§

ReadersActive

Physical compaction was requested while protected read views are open.

§

ConflictHistoryUnavailable

No conflict summary is retained for a commit that must be probed.

Fields

§commit_index: u64

Commit index whose conflict summary is missing.

Trait Implementations§

Source§

impl Clone for StorageError

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

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

Performs copy-assignment from source. Read more
Source§

impl Debug for StorageError

Source§

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

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

impl Display for StorageError

Source§

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

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

impl Error for StorageError

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

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.

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> Same for T

Source§

type Output = T

Should always be Self
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 = !

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

fn try_from(value: U) -> Result<T, !>

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.