pub struct TrackerConfig {
pub window_ms: NonZeroU32,
pub min_samples: u32,
pub max_trackable_latency_ms: u32,
}Expand description
Configuration for LatencyTracker.
All duration-like fields use integer milliseconds for compactness.
§Example
use adaptive_timeout::TrackerConfig;
let config = TrackerConfig {
min_samples: 10,
..TrackerConfig::default()
};Fields§
§window_ms: NonZeroU32Total sliding window duration in milliseconds. This is the full time
span the histogram remembers — not per sub-window. The window is
divided into N equal sub-windows of window_ms / N each.
Default: 60,000 (60s).
min_samples: u32Minimum samples before quantile estimates are valid. Below this,
queries return None. Default: 3.
max_trackable_latency_ms: u32Maximum trackable latency in milliseconds. Values above this are clamped. Default: 60,000 (60s).
Implementations§
Trait Implementations§
Source§impl Clone for TrackerConfig
impl Clone for TrackerConfig
Source§fn clone(&self) -> TrackerConfig
fn clone(&self) -> TrackerConfig
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 TrackerConfig
impl Debug for TrackerConfig
Source§impl Default for TrackerConfig
impl Default for TrackerConfig
impl Copy for TrackerConfig
Auto Trait Implementations§
impl Freeze for TrackerConfig
impl RefUnwindSafe for TrackerConfig
impl Send for TrackerConfig
impl Sync for TrackerConfig
impl Unpin for TrackerConfig
impl UnsafeUnpin for TrackerConfig
impl UnwindSafe for TrackerConfig
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