Skip to main content

CommitError

Enum CommitError 

Source
#[non_exhaustive]
pub enum CommitError {
Show 20 variants Plan(CommitPlanError), Binding { reserved_transaction: TransactionId, plan_transaction: TransactionId, }, BaseSnapshotBinding, DependencyLimit { observed: usize, maximum: usize, }, PlanSize { observed: usize, maximum: usize, }, TransactionWorkspaceExists { transaction: TransactionId, }, UnsafeBlobStore { workspace_root: PathBuf, blobs_directory: PathBuf, }, Host(HostError), Store(TransactionStoreError), Blob(BlobStoreError), DataDirectory(DataDirectoryError), Journal(JournalError), PlanDecode(PlanDecodeError), InternalIo { operation: &'static str, source: Error, }, Stale { conflicts: Vec<RevalidationConflict>, }, Verification(Box<VerificationFailure>), FaultInjected { point: FaultPoint, }, RecoveryRequired { transaction: TransactionId, cause: String, }, RecoveryConflict(RecoveryConflict), InvalidRecoveryState { transaction: TransactionId, state: TransactionState, },
}
Expand description

Trusted-commit, revalidation, or recovery failure.

Variants (Non-exhaustive)§

This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
§

Plan(CommitPlanError)

The immutable commit artifact is internally inconsistent.

§

Binding

The single-use reservation covers another transaction.

Fields

§reserved_transaction: TransactionId

Transaction consumed from the store.

§plan_transaction: TransactionId

Transaction derived from the supplied artifact.

§

BaseSnapshotBinding

Reservation and artifact cover different base snapshots.

§

DependencyLimit

The combined dependency set exceeds its configured bound.

Fields

§observed: usize

Observed dependency count.

§maximum: usize

Configured maximum.

§

PlanSize

An encoded plan or recovery journal exceeds its configured bound.

Fields

§observed: usize

Observed byte length.

§maximum: usize

Configured maximum.

§

TransactionWorkspaceExists

A durable workspace already exists and must be recovered first.

Fields

§transaction: TransactionId

Affected transaction.

§

UnsafeBlobStore

A caller-supplied blob store overlaps the untrusted workspace namespace.

Fields

§workspace_root: PathBuf

Canonical workspace authority root.

§blobs_directory: PathBuf

Canonical immutable blob directory.

§

Host(HostError)

Capability-scoped host observation or mutation failed.

§

Store(TransactionStoreError)

Atomic transaction-state persistence failed.

§

Blob(BlobStoreError)

Immutable blob loading or verification failed.

§

DataDirectory(DataDirectoryError)

The protected workspace data capability could not be established.

§

Journal(JournalError)

Durable journal validation failed.

§

PlanDecode(PlanDecodeError)

Durable plan decoding failed.

§

InternalIo

Internal capability-directory I/O failed.

Fields

§operation: &'static str

Stable operation label.

§source: Error

Underlying host error.

§

Stale

Revalidation detected stale dependencies before mutation.

Fields

§conflicts: Vec<RevalidationConflict>

Bounded set of exact conflicts.

§

Verification(Box<VerificationFailure>)

An operation or post-commit final-state check failed.

§

FaultInjected

Test-only simulated crash point fired.

Fields

§point: FaultPoint

Fired boundary.

§

RecoveryRequired

Mutation may have begun and the durable journal must be recovered.

Fields

§transaction: TransactionId

Affected transaction.

§cause: String

Original failure rendered without leaking file content.

§

RecoveryConflict(RecoveryConflict)

Recovery could not prove ownership and left host data untouched.

§

InvalidRecoveryState

Store state is incompatible with the durable recovery artifact.

Fields

§transaction: TransactionId

Affected transaction.

§state: TransactionState

Unexpected persisted state.

Trait Implementations§

Source§

impl Debug for CommitError

Source§

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

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

impl Display for CommitError

Source§

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

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

impl Error for CommitError

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<BlobStoreError> for CommitError

Source§

fn from(source: BlobStoreError) -> Self

Converts to this type from the input type.
Source§

impl From<CommitPlanError> for CommitError

Source§

fn from(source: CommitPlanError) -> Self

Converts to this type from the input type.
Source§

impl From<DataDirectoryError> for CommitError

Source§

fn from(source: DataDirectoryError) -> Self

Converts to this type from the input type.
Source§

impl From<HostError> for CommitError

Source§

fn from(source: HostError) -> Self

Converts to this type from the input type.
Source§

impl From<JournalError> for CommitError

Source§

fn from(source: JournalError) -> Self

Converts to this type from the input type.
Source§

impl From<PlanDecodeError> for CommitError

Source§

fn from(source: PlanDecodeError) -> Self

Converts to this type from the input type.
Source§

impl From<TransactionStoreError> for CommitError

Source§

fn from(source: TransactionStoreError) -> Self

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 = !

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.