ibid. for metrics

This commit is contained in:
Jedrzej Stuczynski
2020-02-04 15:15:51 +00:00
parent fd33589326
commit 448fc4a361
+2 -2
View File
@@ -74,11 +74,11 @@ impl MetricsReporter {
metrics: Arc<Mutex<MetricsReporter>>,
cfg: directory_client::Config,
pub_key_str: String,
sending_delay: Duration,
) {
let delay_duration = Duration::from_secs(METRICS_INTERVAL);
let directory_client = directory_client::Client::new(cfg);
loop {
tokio::time::delay_for(delay_duration).await;
tokio::time::delay_for(sending_delay).await;
let (received, sent) =
MetricsReporter::acquire_and_reset_metrics(metrics.clone()).await;