Struct tiny_actor::config::BackPressure
source · [−]pub struct BackPressure { /* private fields */ }Expand description
The backpressure mechanism for unbounded inboxes.
Default
exponential backoff starting 5 messages in the inbox at 25 ns, with a
growth-factor of 1.3
Implementations
sourceimpl BackPressure
impl BackPressure
sourcepub fn linear(starts_at: usize, timeout: Duration) -> Self
pub fn linear(starts_at: usize, timeout: Duration) -> Self
Creates a new linear backpressure.
The timeout is calculated as follows:
timeout = timeout * (msg_count - start_at)
Panics
Panics if the timeout is bigger than 213_503 days.
Trait Implementations
sourceimpl Clone for BackPressure
impl Clone for BackPressure
sourcefn clone(&self) -> BackPressure
fn clone(&self) -> BackPressure
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Debug for BackPressure
impl Debug for BackPressure
sourceimpl Default for BackPressure
impl Default for BackPressure
sourceimpl PartialEq<BackPressure> for BackPressure
impl PartialEq<BackPressure> for BackPressure
sourcefn eq(&self, other: &BackPressure) -> bool
fn eq(&self, other: &BackPressure) -> bool
This method tests for self and other values to be equal, and is used
by ==. Read more
impl StructuralPartialEq for BackPressure
Auto Trait Implementations
impl RefUnwindSafe for BackPressure
impl Send for BackPressure
impl Sync for BackPressure
impl Unpin for BackPressure
impl UnwindSafe for BackPressure
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more