From b7356ddc6cc7979ec0448bc7dfe3c8e3e37e2506 Mon Sep 17 00:00:00 2001 From: Alice Ryhl Date: Tue, 26 Nov 2024 15:30:29 +0100 Subject: [PATCH] fix histogram configuration --- src/runtime.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/runtime.rs b/src/runtime.rs index b5eff04..d71fec1 100644 --- a/src/runtime.rs +++ b/src/runtime.rs @@ -251,14 +251,14 @@ pub struct RuntimeMetrics { /// /// ##### Examples /// ``` - /// use tokio::runtime::HistogramScale; + /// use tokio::runtime::HistogramConfiguration; /// use std::time::Duration; /// + /// let config = HistogramConfiguration::linear(Duration::from_micros(50), 12); + /// /// let rt = tokio::runtime::Builder::new_multi_thread() /// .enable_metrics_poll_time_histogram() - /// .metrics_poll_time_histogram_scale(HistogramScale::Linear) - /// .metrics_poll_time_histogram_resolution(Duration::from_micros(50)) - /// .metrics_poll_time_histogram_buckets(12) + /// .metrics_poll_time_histogram_configuration(config) /// .build() /// .unwrap(); ///