#[non_exhaustive]pub enum PersistenceError {
InvalidPersistenceId(String),
InvalidAtomicWrite(String),
Rejected(String),
Failure(String),
Serialization(String),
UnknownSerializer(SerializerId),
DuplicateSerializer(SerializerId),
Connection(String),
RevisionConflict {
persistence_id: PersistenceId,
expected: Revision,
actual: Revision,
},
RevisionExhausted {
persistence_id: PersistenceId,
},
}Expand description
Errors produced by persistence operations.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
InvalidPersistenceId(String)
A persistence id violates the identity format contract.
InvalidAtomicWrite(String)
An atomic journal write violates its construction invariants.
Rejected(String)
A deterministic request was rejected before storage.
Failure(String)
A persistence operation failed or its outcome is uncertain.
Serialization(String)
A value could not be serialized or deserialized.
UnknownSerializer(SerializerId)
No serializer is registered for a durable serializer id.
DuplicateSerializer(SerializerId)
More than one serializer was registered with the same durable id.
Connection(String)
A storage connection could not be established or was lost.
RevisionConflict
A durable-state compare-and-set revision did not match.
Fields
persistence_id: PersistenceIdDurable-state identity whose revision did not match.
RevisionExhausted
A durable-state revision cannot advance beyond its numeric range.
Fields
persistence_id: PersistenceIdDurable-state identity whose revision reached the maximum value.
Trait Implementations§
Source§impl Clone for PersistenceError
impl Clone for PersistenceError
Source§fn clone(&self) -> PersistenceError
fn clone(&self) -> PersistenceError
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for PersistenceError
impl Debug for PersistenceError
Source§impl Display for PersistenceError
impl Display for PersistenceError
Source§impl Error for PersistenceError
impl Error for PersistenceError
1.30.0 · 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()