pub enum DispatchStrategy {
RoundRobin,
Random,
LeastConnections,
}Expand description
Dispatch strategy for distributing commands across pooled connections.
Variants§
RoundRobin
Cycle through connections sequentially (default).
Random
Pick a random connection for each command.
LeastConnections
Pick the connection with the fewest in-flight commands. Best for workloads with variable command latency (e.g., mix of GET and SORT). Falls back to round-robin on ties.
Trait Implementations§
Source§impl Clone for DispatchStrategy
impl Clone for DispatchStrategy
impl Copy for DispatchStrategy
Source§impl Debug for DispatchStrategy
impl Debug for DispatchStrategy
Auto Trait Implementations§
impl Freeze for DispatchStrategy
impl RefUnwindSafe for DispatchStrategy
impl Send for DispatchStrategy
impl Sync for DispatchStrategy
impl Unpin for DispatchStrategy
impl UnsafeUnpin for DispatchStrategy
impl UnwindSafe for DispatchStrategy
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