pub enum CommitError {
Conflict,
Constraint(ConstraintViolation),
Io(String),
PreparedPending(Vec<String>),
}Expand description
Why a NativeTx::commit failed. Both cases leave the graph unchanged and
the transaction’s writes discarded. A local error type, so the crate-wide
CoreError is not widened.
Variants§
Conflict
The graph changed since the transaction began (optimistic conflict); retry against the new state.
Constraint(ConstraintViolation)
The transaction’s writes would violate a declared Constraint.
Io(String)
Writing the transaction to the write-ahead log failed (durable engine only). The transaction is not applied; the message is the I/O error.
PreparedPending(Vec<String>)
Two-phase commit: a transaction is prepared, and every other write is refused until it is resolved (the prepared fence). Retryable; carries the pending global transaction ids.
Trait Implementations§
Source§impl Clone for CommitError
impl Clone for CommitError
Source§impl Debug for CommitError
impl Debug for CommitError
Source§impl Display for CommitError
impl Display for CommitError
impl Eq for CommitError
Source§impl Error for CommitError
impl Error for CommitError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
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
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for CommitError
impl PartialEq for CommitError
impl StructuralPartialEq for CommitError
Auto Trait Implementations§
impl Freeze for CommitError
impl RefUnwindSafe for CommitError
impl Send for CommitError
impl Sync for CommitError
impl Unpin for CommitError
impl UnsafeUnpin for CommitError
impl UnwindSafe for CommitError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more