use std::time::Duration;
#[derive(Clone)]
#[non_exhaustive]
pub struct OrphanReporterConfig {
pub reporter_interval: Duration,
pub sample_size: usize,
}
impl OrphanReporterConfig {
pub fn reporter_interval(mut self, reporter_interval: Duration) -> Self {
self.reporter_interval = reporter_interval;
self
}
pub fn sample_size(mut self, sample_size: usize) -> Self {
self.sample_size = sample_size;
self
}
}
impl Default for OrphanReporterConfig {
fn default() -> Self {
Self {
reporter_interval: Duration::from_secs(10),
sample_size: 10,
}
}
}