pub enum FatalStorageError {
Show 23 variants
CreateDatabaseDirectory(PathBuf, Error),
DuplicateEraIdIndex {
era_id: EraId,
first: BlockHash,
second: BlockHash,
},
FailedToOverwriteBlock,
DatabaseNotFound(RecordId),
UnableToMoveFile {
source_path: PathBuf,
dest_path: PathBuf,
original_error: Error,
},
MissingStorageFiles {
missing_files: Vec<PathBuf>,
},
BlockValidation(BlockValidationError),
BlockHeaderNotStoredUnderItsHash {
queried_block_hash_bytes: Vec<u8>,
found_block_header_hash: BlockHash,
block_header: Box<BlockHeader>,
},
NoBlockHeaderForBlockBody {
block_body_hash: Digest,
block_body: Box<BlockBody>,
},
SignatureVerification(Error),
CorruptedBlockSignatureIndex {
raw_key: Vec<u8>,
block_hash_bytes: Vec<u8>,
},
InvalidSwitchBlock(Box<BlockHeader>),
UnexpectedBlockBodyPart {
block_body_hash: Digest,
part_hash: Digest,
},
StoredItemSerializationFailure(Error),
UnexpectedFinalizedApprovals {
transaction_hash: TransactionHash,
},
UnexpectedSerializationFailure(Error),
UnexpectedDeserializationFailure(Error),
ApprovalsHashesLengthMismatch {
block_hash: BlockHash,
expected: usize,
actual: usize,
},
InvalidExecutionResultsV1Length {
deploy_hash: DeployHash,
results_length: usize,
},
Prometheus(Error),
VariantMismatch(VariantMismatch),
BlockStoreError(BlockStoreError),
UnexpectedRecordId(RecordId),
}
Expand description
A fatal storage component error.
An error of this kinds indicates that storage is corrupted or otherwise irrecoverably broken, at least for the moment. It should usually be followed by swift termination of the node.
Variants§
CreateDatabaseDirectory(PathBuf, Error)
Failure to create the root database directory.
DuplicateEraIdIndex
Found a duplicate switch-block-at-era-id index entry.
Fields
FailedToOverwriteBlock
An internal DB error - blocks should be overwritten.
DatabaseNotFound(RecordId)
Record specified in raw request has not been found in the storage module.
UnableToMoveFile
Filesystem error while trying to move file.
Fields
MissingStorageFiles
Mix of missing and found storage files.
BlockValidation(BlockValidationError)
Error when validating a block.
BlockHeaderNotStoredUnderItsHash
A block header was not stored under its hash.
Fields
block_header: Box<BlockHeader>
The block header found in storage.
NoBlockHeaderForBlockBody
Block body did not have a block header.
SignatureVerification(Error)
Could not verify finality signatures for block.
CorruptedBlockSignatureIndex
Corrupted block signature index.
Fields
InvalidSwitchBlock(Box<BlockHeader>)
Switch block does not contain era end.
UnexpectedBlockBodyPart
A block body was found to have more parts than expected.
Fields
StoredItemSerializationFailure(Error)
Failed to serialize an item that was found in local storage.
UnexpectedFinalizedApprovals
We tried to store finalized approvals for a nonexistent transaction.
Fields
transaction_hash: TransactionHash
The missing transaction hash.
UnexpectedSerializationFailure(Error)
ToBytes
serialization failure of an item that should never fail to serialize.
UnexpectedDeserializationFailure(Error)
ToBytes
deserialization failure of an item that should never fail to serialize.
ApprovalsHashesLengthMismatch
Stored finalized approvals hashes count doesn’t match number of deploys.
Fields
InvalidExecutionResultsV1Length
V1 execution results hashmap doesn’t have exactly one entry.
Fields
deploy_hash: DeployHash
The deploy hash.
Prometheus(Error)
Error initializing metrics.
VariantMismatch(VariantMismatch)
Type mismatch indicating programmer error.
BlockStoreError(BlockStoreError)
BlockStoreError
UnexpectedRecordId(RecordId)
BlockStoreError
Trait Implementations§
Source§impl Debug for FatalStorageError
impl Debug for FatalStorageError
Source§impl Display for FatalStorageError
impl Display for FatalStorageError
Source§impl Error for FatalStorageError
impl Error for FatalStorageError
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
Source§impl From<BlockStoreError> for FatalStorageError
impl From<BlockStoreError> for FatalStorageError
Source§fn from(source: BlockStoreError) -> Self
fn from(source: BlockStoreError) -> Self
Source§impl From<BlockValidationError> for FatalStorageError
impl From<BlockValidationError> for FatalStorageError
Source§fn from(source: BlockValidationError) -> Self
fn from(source: BlockValidationError) -> Self
Source§impl From<Box<BlockValidationError>> for FatalStorageError
impl From<Box<BlockValidationError>> for FatalStorageError
Source§fn from(err: Box<BlockValidationError>) -> Self
fn from(err: Box<BlockValidationError>) -> Self
Source§impl From<Error> for FatalStorageError
impl From<Error> for FatalStorageError
Source§impl From<VariantMismatch> for FatalStorageError
impl From<VariantMismatch> for FatalStorageError
Source§fn from(source: VariantMismatch) -> Self
fn from(source: VariantMismatch) -> Self
Auto Trait Implementations§
impl Freeze for FatalStorageError
impl !RefUnwindSafe for FatalStorageError
impl Send for FatalStorageError
impl Sync for FatalStorageError
impl Unpin for FatalStorageError
impl !UnwindSafe for FatalStorageError
Blanket Implementations§
Source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
Source§type ArchivedMetadata = ()
type ArchivedMetadata = ()
Source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
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> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
Source§impl<From, To> FallibleInto<To> for Fromwhere
To: TryFrom<From>,
impl<From, To> FallibleInto<To> for Fromwhere
To: TryFrom<From>,
fn try_into_wrapped(self) -> Result<To, VMError>
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
Source§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Source§impl<T, N1, N2> Niching<NichedOption<T, N1>> for N2
impl<T, N1, N2> Niching<NichedOption<T, N1>> for N2
Source§unsafe fn is_niched(niched: *const NichedOption<T, N1>) -> bool
unsafe fn is_niched(niched: *const NichedOption<T, N1>) -> bool
Source§fn resolve_niched(out: Place<NichedOption<T, N1>>)
fn resolve_niched(out: Place<NichedOption<T, N1>>)
out
indicating that a T
is niched.