pub enum WalError {
Io(Error),
Corruption {
offset: u64,
path: PathBuf,
detail: String,
},
SequenceSkip {
expected: u64,
got: u64,
},
Full {
count: usize,
limit: usize,
},
InvalidHeader {
path: PathBuf,
detail: String,
},
PayloadTooLarge {
size: usize,
limit: usize,
},
LockPoisoned(String),
Poisoned,
}Expand description
Write-Ahead Log errors.
Variants§
Io(Error)
Underlying I/O error.
Corruption
Data corruption detected (CRC mismatch).
Fields
SequenceSkip
Sequence number discontinuity detected during replay.
Fields
Full
WAL is full — too many unflushed WAL files.
Fields
InvalidHeader
Invalid WAL file header (wrong magic bytes or unsupported version).
Fields
PayloadTooLarge
Payload exceeds the maximum allowed size per WAL record.
LockPoisoned(String)
Internal lock was poisoned (indicates a prior panic while holding the lock).
Poisoned
The WAL writer’s file is in an unknown state after a failed fsync
or a failed rewind, and every write is refused until the database is
reopened.
The message names reopening, not clear_poison(). It named the
latter for a long time, and no user of the chronix facade can call
it: it is a chronix-engine method the facade does not re-export. An
error that tells the operator to do something they cannot do is worse
than one that says nothing.
Trait Implementations§
Source§impl Error for WalError
impl Error for WalError
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()