pub enum LeanWorkerRestartReason {
Explicit,
MaxRequests {
limit: u64,
},
MaxImports {
limit: u64,
},
RssCeiling {
current_kib: u64,
limit_kib: u64,
},
Idle {
idle_for: Duration,
limit: Duration,
},
Cancelled {
operation: &'static str,
},
RequestTimeout {
operation: &'static str,
duration: Duration,
},
}Expand description
Reason recorded for the latest worker cycle.
Variants§
Explicit
The caller explicitly requested a process cycle.
MaxRequests
Request count reached the configured limit before the next request.
MaxImports
Import-like request count reached the configured limit before the next import.
RssCeiling
Child resident set size reached the configured limit.
Idle
Worker was idle at least as long as the configured limit.
Cancelled
Parent-side cancellation replaced the child during an in-flight request.
RequestTimeout
Parent-side request timeout replaced the child during an in-flight request.
Trait Implementations§
Source§impl Clone for LeanWorkerRestartReason
impl Clone for LeanWorkerRestartReason
Source§fn clone(&self) -> LeanWorkerRestartReason
fn clone(&self) -> LeanWorkerRestartReason
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 LeanWorkerRestartReason
impl Debug for LeanWorkerRestartReason
Source§impl PartialEq for LeanWorkerRestartReason
impl PartialEq for LeanWorkerRestartReason
Source§fn eq(&self, other: &LeanWorkerRestartReason) -> bool
fn eq(&self, other: &LeanWorkerRestartReason) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for LeanWorkerRestartReason
impl StructuralPartialEq for LeanWorkerRestartReason
Auto Trait Implementations§
impl Freeze for LeanWorkerRestartReason
impl RefUnwindSafe for LeanWorkerRestartReason
impl Send for LeanWorkerRestartReason
impl Sync for LeanWorkerRestartReason
impl Unpin for LeanWorkerRestartReason
impl UnsafeUnpin for LeanWorkerRestartReason
impl UnwindSafe for LeanWorkerRestartReason
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