diff --git a/tracing-trace/src/processor/span_stats.rs b/tracing-trace/src/processor/span_stats.rs index 63b6ae5c1..0d6d2f4e2 100644 --- a/tracing-trace/src/processor/span_stats.rs +++ b/tracing-trace/src/processor/span_stats.rs @@ -1,7 +1,7 @@ use std::collections::{BTreeMap, HashMap}; use std::time::Duration; -use serde::Serialize; +use serde::{Deserialize, Serialize}; use crate::entry::{Entry, NewCallsite, SpanClose, SpanEnter, SpanExit}; use crate::{Error, TraceReader}; @@ -12,10 +12,10 @@ enum SpanStatus { Inside(std::time::Duration), } -#[derive(Serialize)] +#[derive(Serialize, Deserialize)] pub struct CallStats { - nb: usize, - ns: u64, + pub nb: usize, + pub ns: u64, } pub fn to_call_stats(