File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -38,8 +38,9 @@ thiserror = { version = "1.0.31", optional = true }
38
38
39
39
[dev-dependencies ]
40
40
async-trait = " 0.1.56"
41
- criterion = { version = " 0.5 .0" , default-features = false }
41
+ criterion = { version = " 0.4 .0" , default-features = false , features = [ " html_reports " ] }
42
42
opentelemetry-jaeger = " 0.18.0"
43
+ pprof = { version = " 0.11.1" , features = [" flamegraph" , " criterion" ] }
43
44
futures-util = { version = " 0.3" , default-features = false }
44
45
tokio = { version = " 1" , features = [" full" ] }
45
46
tokio-stream = " 0.1"
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ use opentelemetry::{
4
4
trace:: { SpanBuilder , Tracer as _, TracerProvider as _} ,
5
5
Context ,
6
6
} ;
7
+ use pprof:: criterion:: { Output , PProfProfiler } ;
7
8
use std:: time:: SystemTime ;
8
9
use tracing:: trace_span;
9
10
use tracing_subscriber:: prelude:: * ;
@@ -122,5 +123,9 @@ fn tracing_harness() {
122
123
dummy ( ) ;
123
124
}
124
125
125
- criterion_group ! ( benches, many_children) ;
126
+ criterion_group ! {
127
+ name = benches;
128
+ config = Criterion :: default ( ) . with_profiler( PProfProfiler :: new( 100 , Output :: Flamegraph ( None ) ) ) ;
129
+ targets = many_children
130
+ }
126
131
criterion_main ! ( benches) ;
You can’t perform that action at this time.
0 commit comments