pub enum CommitError {
Validation(String),
StoreWrite(StorageError),
MessageVersionConflict {
thread_id: String,
expected: u64,
actual: u64,
},
EventAppend(EventStoreError),
OutboxInsert(OutboxError),
Commit(String),
ScopeMismatch(String),
}Expand description
Failure surface for CommitCoordinator::commit_checkpoint.
Any variant aborts the transaction. The runtime treats this as terminal for the current run per ADR-0036 D6.
Variants§
Validation(String)
Plan failed pre-commit validation.
StoreWrite(StorageError)
ThreadRunStore checkpoint write failed.
MessageVersionConflict
A version-guarded committed message append found a stale expected version — the committed log advanced under the writer. The caller reloads, re-merges its delta, recomputes the range, and retries (ADR-0042 A).
EventAppend(EventStoreError)
EventStore::append failed for a staged draft.
OutboxInsert(OutboxError)
Inline-writer outbox insert failed.
Commit(String)
Backend-level commit error (transaction commit failure, network).
ScopeMismatch(String)
Builder-time scope mismatch detected at runtime.
Implementations§
Source§impl CommitError
impl CommitError
Sourcepub fn reclassify_append_conflict(self, thread_id: &str) -> CommitError
pub fn reclassify_append_conflict(self, thread_id: &str) -> CommitError
Reclassify a wrapped store-level StorageError::VersionConflict from
an append commit into the message-level CommitError::MessageVersionConflict
carrying thread_id, so the append retry path can distinguish a stale
version (reload-merge-retry) from other store-write failures (abort).
Other errors pass through unchanged (ADR-0042 A).
Trait Implementations§
Source§impl Debug for CommitError
impl Debug for CommitError
Source§impl Display for CommitError
impl Display for CommitError
Source§impl Error for CommitError
impl Error for CommitError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl From<EventStoreError> for CommitError
impl From<EventStoreError> for CommitError
Source§fn from(source: EventStoreError) -> CommitError
fn from(source: EventStoreError) -> CommitError
Source§impl From<OutboxError> for CommitError
impl From<OutboxError> for CommitError
Source§fn from(source: OutboxError) -> CommitError
fn from(source: OutboxError) -> CommitError
Source§impl From<StorageError> for CommitError
impl From<StorageError> for CommitError
Source§fn from(source: StorageError) -> CommitError
fn from(source: StorageError) -> 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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.