pub enum TrackingResult {
Recorded,
ConsecutiveThresholdExceeded {
consecutive_errors: u32,
threshold: u32,
},
RateThresholdExceeded {
error_count: usize,
window_ms: u64,
rate: u32,
},
}Expand description
Result of error tracking evaluation.
Returned by on_send_failure() to indicate what action should be taken.
Variants§
Recorded
Error recorded, no threshold exceeded.
ConsecutiveThresholdExceeded
Consecutive error threshold exceeded — tunnel restart recommended.
RateThresholdExceeded
Sliding window error rate exceeded — warning state.
Implementations§
Source§impl TrackingResult
impl TrackingResult
Sourcepub fn requires_restart(&self) -> bool
pub fn requires_restart(&self) -> bool
Whether a tunnel restart is recommended.
Sourcepub fn is_warning(&self) -> bool
pub fn is_warning(&self) -> bool
Whether this is a warning state.
Trait Implementations§
Source§impl Clone for TrackingResult
impl Clone for TrackingResult
Source§fn clone(&self) -> TrackingResult
fn clone(&self) -> TrackingResult
Returns a duplicate of the value. Read more
1.0.0 · 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 TrackingResult
impl Debug for TrackingResult
Source§impl PartialEq for TrackingResult
impl PartialEq for TrackingResult
impl Eq for TrackingResult
impl StructuralPartialEq for TrackingResult
Auto Trait Implementations§
impl Freeze for TrackingResult
impl RefUnwindSafe for TrackingResult
impl Send for TrackingResult
impl Sync for TrackingResult
impl Unpin for TrackingResult
impl UnsafeUnpin for TrackingResult
impl UnwindSafe for TrackingResult
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§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.