stats.rs
SHA-256b1227c346437c85e7e4d2507333f9ad85a97086fd0825332800ece9047655317
Malecule∅
Evidence
1//! This file contains the types necessary to collect various types of stats.
2use crate::loom::sync::atomic::{AtomicU64, Ordering::Relaxed};
3
4/// This type contains methods to retrieve stats from a Tokio runtime.
5#[derive(Debug)]
6pub struct RuntimeStats {
7 w …
21:23… s = Vec::with_capacity(worker_threads);
22 for _ in 0..worker_threads {
23 workers.push(WorkerStats {
24 park_count: Ato …
36:39… ator<Item = &WorkerStats> {
37 self.workers.iter()
38 }
39}
40
41impl WorkerStats {
42 /// Returns the total number of times this worker thread has pa …