pub enum CompactError {
Chain(ChainError),
NothingAcked,
UnackedDevice {
device_id: String,
},
EventStreamRetention {
surface: String,
},
IntentRetention,
TruncatedJournal {
checkpoint_hash: String,
},
Io(Error),
}Expand description
A compaction failure. No PartialEq (carries io::Error); match on
variants.
Variants§
Chain(ChainError)
The input log doesn’t verify — never compact what you can’t trust (the B1 verify-before-fold contract).
NothingAcked
No device has acked anything: no stable frontier exists, nothing is provably folded-by-everyone, nothing may be dropped.
UnackedDevice
A device present in the log has no ack entry — its fold frontier is unknown, so every op is data it may not have seen. Refuse.
EventStreamRetention
The policy tried to trim an event-stream surface (op_id-keyed observation multiset). Those replay from genesis; only keep-all is sound.
IntentRetention
The policy set a non-keep-all rule for the leased intent surface
(B5). Intents are keep-all — the committed_runs idempotency oracle
must survive compaction, so trimming it is never sound.
TruncatedJournal
The journal was already truncated below a checkpoint (its truncation marker names it). Re-planning from the tail alone would fold a checkpoint that silently misses everything the prior checkpoint covers — recompaction over a checkpoint base is a later slice.
Io(Error)
Trait Implementations§
Source§impl Debug for CompactError
impl Debug for CompactError
Source§impl Display for CompactError
impl Display for CompactError
Source§impl Error for CompactError
impl Error for CompactError
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()