pub enum ConfError {
Show 18 variants
Io {
path: PathBuf,
source: Error,
},
EmptyDocument,
TooManyPools(usize),
EmptyPoolName,
UnknownKey {
name: String,
},
MissingRequired(&'static str),
BadAddr {
field: &'static str,
value: String,
reason: String,
},
BadToken {
value: String,
reason: String,
},
BadConsistency {
field: &'static str,
value: String,
},
BadSecure(String),
BadDataStore(i64),
BadNoxuConfig(&'static str),
BadHash(String),
BadDistribution(String),
OutOfRange {
field: &'static str,
value: i64,
reason: &'static str,
},
BadServer {
field: &'static str,
value: String,
reason: String,
},
BadHashTag(String),
Yaml {
message: String,
},
}Expand description
Variants§
Io
I/O error while reading a configuration file.
EmptyDocument
The YAML document was empty or missing the top-level pool.
TooManyPools(usize)
The top-level mapping had more than one pool.
EmptyPoolName
The top-level pool name was the empty string.
UnknownKey
A directive name in the YAML is not recognized.
MissingRequired(&'static str)
A required directive is absent from the configuration.
BadAddr
listen / dyn_listen / stats_listen address could not be parsed.
Fields
BadToken
A token list could not be parsed as comma-separated big-ints.
BadConsistency
read_consistency / write_consistency value is not a known level.
Fields
BadSecure(String)
secure_server_option value is not a known mode.
BadDataStore(i64)
data_store value is not 0 (Redis), 1 (Memcache), or 2
(Noxu). The string forms redis, memcache, and noxu
are also accepted on the YAML side and are translated to
these integers before validation.
BadNoxuConfig(&'static str)
data_store: noxu was selected but noxu_path was not
supplied or dynomited was built without --features riak.
BadHash(String)
hash value is not a recognized hash algorithm name.
BadDistribution(String)
distribution value is not a recognized distribution
algorithm name.
OutOfRange
A numeric directive is out of its allowed range.
Fields
BadServer
A server / dyn_seeds entry is malformed.
Fields
BadHashTag(String)
hash_tag must be exactly two characters, per the C parser.
Yaml
The YAML failed to parse at the document level.
Trait Implementations§
Source§impl Error for ConfError
impl Error for ConfError
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()