pub enum ShardState {
Provisioning,
Active,
Draining,
Stopped,
}Expand description
State of a shard in the mapper.
Variants§
Provisioning
Shard is being provisioned: id allocated and metrics collector
in place, but select_shard must not route to it yet because
upstream workers (drain / batch) have not been spawned. Caller
transitions to Active via activate once the workers are
ready. Closes the race where a freshly-added shard accepted
producer pushes before any consumer existed.
Active
Shard is active and accepting producers.
Draining
Shard is draining (no new producers, waiting for empty).
Stopped
Shard is stopped and can be removed.
Trait Implementations§
Source§impl Clone for ShardState
impl Clone for ShardState
Source§fn clone(&self) -> ShardState
fn clone(&self) -> ShardState
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ShardState
impl Debug for ShardState
Source§impl PartialEq for ShardState
impl PartialEq for ShardState
Source§fn eq(&self, other: &ShardState) -> bool
fn eq(&self, other: &ShardState) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Copy for ShardState
impl Eq for ShardState
impl StructuralPartialEq for ShardState
Auto Trait Implementations§
impl Freeze for ShardState
impl RefUnwindSafe for ShardState
impl Send for ShardState
impl Sync for ShardState
impl Unpin for ShardState
impl UnsafeUnpin for ShardState
impl UnwindSafe for ShardState
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.