pub enum Kind {
Show 18 variants
ActiveBlobNotSet,
WrongConfig,
Uninitialized,
WorkDirInUse,
WorkDirUnavailable {
path: PathBuf,
msg: String,
io_err_kind: ErrorKind,
},
FileUnavailable(ErrorKind),
KeySizeMismatch,
ActiveBlobDoesntExist,
ActiveBlobExists,
RecordExists,
EmptyIndexBunch,
Index(String),
Bincode(String),
IO(String),
WrongFileNamePattern(PathBuf),
Conversion(String),
Validation {
kind: ValidationErrorKind,
cause: String,
},
Other,
}
Expand description
A list specifying categories of Storage error.
Variants§
ActiveBlobNotSet
Active blob not set, often initialization failed.
WrongConfig
Input configuration is wrong.
Uninitialized
Probably storage initialization failed.
WorkDirInUse
Work directory is locked by another storage.
Or the operation lacked the necessary privileges to complete.
Stop another storage or delete *.lock
file
Happens when try to write/read from work dir that doesn’t exist. In case when work dir wasn’t created or disk was unmounted. Contains path to failed work dir, IOError description and IOErrorKind.
Blob detects os errors during IO operation which indicate possible problems with disk
KeySizeMismatch
Storage was initialized with different key size
ActiveBlobDoesntExist
Active blob doesn’t exist
ActiveBlobExists
Active blob already exists
RecordExists
Record with the same key and the same metadata already exists
EmptyIndexBunch
Any error not part of this list
Index(String)
Index error
Bincode(String)
Bincode serialization deserialization error
IO(String)
std::io::Error
WrongFileNamePattern(PathBuf)
Wrong file name pattern in config
Conversion(String)
Conversion error
Validation
Fields
kind: ValidationErrorKind
Describes what check failed.
Validation errors, eg. magic byte check
Other
Other error