pub enum StoreContractViolation {
Show 54 variants
CheckpointArtifactTooLarge {
actual: u64,
maximum: u64,
},
CheckpointArtifactEmpty,
CheckpointArtifactSymbolicLink(PathBuf),
CheckpointArtifactPathEscaped(PathBuf),
CheckpointArtifactUnsupportedFileType(PathBuf),
CheckpointArtifactUnsupportedUri(String),
CheckpointSchemaVersion {
expected: u16,
actual: u16,
},
CheckpointInvalidField {
field: &'static str,
reason: String,
},
CheckpointInvalidOffsets(String),
CheckpointDestructiveRollback,
CheckpointRestoreVerificationIncomplete,
HaInvalidMasterEpoch(i32),
HaInvalidSyncStateSetEpoch(i32),
HaInvalidBrokerId(i64),
HaBrokerIdOutOfRange(u64),
HaInvalidReplicaCount(usize),
HaInvalidAckPolicy(i32),
HaInvalidOffset(i64),
HaInvalidLeaseGeneration(u64),
HaEmptySyncStateSet,
HaLeaderMissingFromSyncStateSet(i64),
AppendReceiptEmptyRange,
AppendReceiptReversedRange,
AppendReceiptRejectedStatusWithRange,
AppendReceiptAcceptedStatusWithoutRange,
AppendReceiptAppendedWatermarkBehindRange,
AppendReceiptDurableWatermarkBehindRange,
AppendReceiptDurableWatermarkAheadOfAppended,
AppendReceiptMemoryDurabilityAlreadyCovered,
AppendReceiptReplicatedDurabilityRequiresDecision,
AppendReceiptReplicationDecisionBehindRange,
DerivedRecordEmpty,
DerivedRecordRangeOverflow,
DerivedCursorSourceEpochMismatch {
expected: u64,
actual: u64,
},
DerivedCursorGap {
expected: u64,
actual: u64,
},
DerivedCursorPartialOverlap {
committed: u64,
record_start: u64,
record_end: u64,
},
DerivedCheckpointInvalidLength {
expected: usize,
actual: usize,
},
DerivedCheckpointInvalidMagic,
DerivedCheckpointUnsupportedVersion(u16),
DerivedCheckpointUnknownEngine(u8),
DerivedCheckpointEngineMismatch {
expected: DerivedEngine,
actual: DerivedEngine,
},
DerivedCheckpointInvalidReservedByte(u8),
DerivedCheckpointChecksumMismatch,
TimerSnapshotUnsupportedVersion(u16),
TimerSnapshotInvalidMetadata,
TimerSnapshotInvalidFile,
TimerSnapshotChecksumMismatch,
TimerSnapshotInvalidNativeBinding,
TimerSnapshotArtifactDigestMismatch,
TimerUnknownEngine(String),
TimerInvalidPayloadLocator,
TimerInvalidPayloadStoreLocator,
TimerInvalidRoute,
TimerConfigurationOutOfRange {
field: &'static str,
actual: i128,
minimum: i128,
maximum: i128,
},
}Expand description
A deterministic violation of a public Store API contract.
This type contains caller, persisted-format, and state-invariant evidence.
Operational failures such as filesystem I/O are exposed through
crate::StoreError instead, with their private typed causes preserved.
Variants§
CheckpointArtifactTooLarge
A checkpoint artifact exceeded its configured byte budget.
CheckpointArtifactEmpty
A checkpoint artifact contains no payload bytes.
CheckpointArtifactSymbolicLink(PathBuf)
A symbolic link was found in a checkpoint artifact.
CheckpointArtifactPathEscaped(PathBuf)
A discovered checkpoint entry escaped the artifact root.
CheckpointArtifactUnsupportedFileType(PathBuf)
A checkpoint entry was neither a regular file nor a directory.
CheckpointArtifactUnsupportedUri(String)
A checkpoint URI is not a supported local file URI.
CheckpointSchemaVersion
A checkpoint schema version does not match the supported version.
CheckpointInvalidField
A checkpoint field violates its field-level contract.
CheckpointInvalidOffsets(String)
Checkpoint offsets violate their ordering contract.
CheckpointDestructiveRollback
A checkpoint permits a destructive rollback.
CheckpointRestoreVerificationIncomplete
Checkpoint restore verification is incomplete.
HaInvalidMasterEpoch(i32)
A master epoch was not positive.
HaInvalidSyncStateSetEpoch(i32)
A sync-state-set epoch was not positive.
HaInvalidBrokerId(i64)
A broker identifier was negative.
HaBrokerIdOutOfRange(u64)
An unsigned wire broker identifier exceeded the canonical representation.
HaInvalidReplicaCount(usize)
A replica policy did not require a remote replica.
HaInvalidAckPolicy(i32)
A legacy ACK count or sentinel was unknown.
HaInvalidOffset(i64)
A physical offset was negative.
HaInvalidLeaseGeneration(u64)
A Controller write-lease generation was zero.
HaEmptySyncStateSet
The sync-state set was empty.
HaLeaderMissingFromSyncStateSet(i64)
The current leader was absent from the sync-state set.
AppendReceiptEmptyRange
An appended range is empty.
AppendReceiptReversedRange
An appended range is reversed.
AppendReceiptRejectedStatusWithRange
A rejected append status carries an appended range.
AppendReceiptAcceptedStatusWithoutRange
An accepted append status does not carry an appended range.
AppendReceiptAppendedWatermarkBehindRange
The appended watermark does not cover the appended range.
AppendReceiptDurableWatermarkBehindRange
The durable watermark does not cover the claimed durability.
AppendReceiptDurableWatermarkAheadOfAppended
The durable watermark exceeds appended progress.
AppendReceiptMemoryDurabilityAlreadyCovered
Memory durability under-reports reached local durability.
AppendReceiptReplicatedDurabilityRequiresDecision
Replicated durability lacks a canonical acknowledgement decision.
AppendReceiptReplicationDecisionBehindRange
A replication acknowledgement does not cover the appended range.
DerivedRecordEmpty
A derived record has zero length.
DerivedRecordRangeOverflow
A derived record physical range overflows.
DerivedCursorSourceEpochMismatch
A derived record belongs to another source epoch.
DerivedCursorGap
A derived record begins after the next expected offset.
DerivedCursorPartialOverlap
A derived record partially overlaps the committed prefix.
Fields
DerivedCheckpointInvalidLength
A derived checkpoint has the wrong encoded length.
DerivedCheckpointInvalidMagic
A derived checkpoint has invalid magic bytes.
DerivedCheckpointUnsupportedVersion(u16)
A derived checkpoint uses an unsupported version.
DerivedCheckpointUnknownEngine(u8)
A derived checkpoint names an unknown engine.
DerivedCheckpointEngineMismatch
A derived checkpoint belongs to another engine.
DerivedCheckpointInvalidReservedByte(u8)
A derived checkpoint uses a non-zero reserved byte.
DerivedCheckpointChecksumMismatch
A derived checkpoint fails its integrity check.
TimerSnapshotUnsupportedVersion(u16)
A timer snapshot uses an unsupported schema version.
TimerSnapshotInvalidMetadata
Required timer snapshot metadata is invalid.
TimerSnapshotInvalidFile
A timer snapshot file declaration is invalid.
TimerSnapshotChecksumMismatch
A timer snapshot manifest fails its integrity check.
TimerSnapshotInvalidNativeBinding
Native timer snapshot fields do not match the selected index kind.
TimerSnapshotArtifactDigestMismatch
A timer snapshot artifact differs from its manifest declaration.
TimerUnknownEngine(String)
A persisted timer engine identifier is not recognized.
TimerInvalidPayloadLocator
A timer payload locator cannot identify a non-empty CommitLog record.
TimerInvalidPayloadStoreLocator
A timer payload-store locator identifies an empty record.
TimerInvalidRoute
A persisted timer route is incomplete.
TimerConfigurationOutOfRange
A native Timer resource limit is outside its supported range.
Trait Implementations§
Source§impl Clone for StoreContractViolation
impl Clone for StoreContractViolation
Source§impl Debug for StoreContractViolation
impl Debug for StoreContractViolation
Source§impl Display for StoreContractViolation
impl Display for StoreContractViolation
impl Eq for StoreContractViolation
Source§impl Error for StoreContractViolation
impl Error for StoreContractViolation
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()