pub enum SharedEmbeddedLockPolicy {
ReadBiased,
Fair,
}Expand description
Lock policy for SharedEmbeddedStore stripes.
ReadBiased favors read-heavy cache workloads by allowing new readers to
enter while a writer is waiting. Fair uses parking_lot::RwLock, which is
a better fit when writes are frequent or write latency matters more than
peak read-side throughput.
Variants§
ReadBiased
Favor readers. Best for read-heavy shared-handle workloads.
Fair
Favor bounded writer progress. Best for write-heavy or skewed workloads.
Trait Implementations§
Source§fn clone(&self) -> SharedEmbeddedLockPolicy
fn clone(&self) -> SharedEmbeddedLockPolicy
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§fn eq(&self, other: &SharedEmbeddedLockPolicy) -> bool
fn eq(&self, other: &SharedEmbeddedLockPolicy) -> bool
Tests for
self and other values to be equal, and is used by ==.Auto Trait Implementations§
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