From 1b1b980211ac7f4a1af96de602896bd7794b29fe Mon Sep 17 00:00:00 2001 From: Simon Cruanes Date: Mon, 11 Apr 2022 16:33:05 -0400 Subject: [PATCH] test: in emit1, use `GC_metrics` --- tests/bin/emit1.ml | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/tests/bin/emit1.ml b/tests/bin/emit1.ml index 0d791436..c7adf5f6 100644 --- a/tests/bin/emit1.ml +++ b/tests/bin/emit1.ml @@ -8,17 +8,7 @@ let sleep_outer = ref 2.0 let run () = Printf.printf "collector is on %S\n%!" (Opentelemetry_client_ocurl.get_url()); - - (* regularly emit some metrics *) - let emit_gc() = - let gc = Gc.stat() in - T.Metrics.( - emit [ - gauge ~name:"ocaml_opentracing.test.major_heap_words" [int gc.Gc.heap_words]; - sum ~name:"ocaml_opentracing.test.minor_allocated" [float gc.Gc.minor_words]; - ]); - in - let _al = Gc.create_alarm emit_gc in + T.GC_metrics.basic_setup(); let i = ref 0 in while true do