pub enum HashRingError {
InvalidConfiguration(u8, Vnid),
VirtualNodeAlreadyExists(String),
VirtualNodeDoesNotExist(String),
ConcurrentModification,
EmptyRing,
SingleDistinctNodeRing,
}
Expand description
An error type returned by calls to the API exposed by this crate.
Variants§
InvalidConfiguration(u8, Vnid)
The configuration parameters for the construction of the consistent hashing ring appears to be invalid.
The error contains the invalid values for the replication factor and the number of virtual nodes per ring node, in this order.
VirtualNodeAlreadyExists(String)
A hash collision has been detected; one of the virtual nodes probably already exists in the consistent hashing ring.
VirtualNodeDoesNotExist(String)
One of the virtual nodes does not exist in the consistent hashing ring.
ConcurrentModification
The write operation on the consistent hashing ring failed due to some other write operation occurring concurrently on it.
EmptyRing
The consistent hashing ring is currently empty.
SingleDistinctNodeRing
Only one Node
currently populates the consistent hashing ring.
Trait Implementations§
Source§impl Debug for HashRingError
impl Debug for HashRingError
Source§impl Display for HashRingError
impl Display for HashRingError
Source§impl Error for HashRingError
impl Error for HashRingError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for HashRingError
impl RefUnwindSafe for HashRingError
impl Send for HashRingError
impl Sync for HashRingError
impl Unpin for HashRingError
impl UnwindSafe for HashRingError
Blanket Implementations§
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
Mutably borrows from an owned value. Read more