This commit is contained in:
Hannes Mehnert 2019-11-06 21:43:02 +01:00
parent b3b9894a61
commit de7c0ca8a7

View file

@ -9,11 +9,9 @@ module Make (T : Mirage_time.S) (S : Mirage_stack.V4) = struct
let timer conn get host stack dst =
let datas =
Metrics.SM.fold (fun src things acc ->
Metrics.SM.fold (fun src (tags, data) acc ->
let name = Metrics.Src.name src in
List.map (fun (tags, data) ->
Metrics_influx.encode_line_protocol (host@tags) data name)
things @ acc)
Metrics_influx.encode_line_protocol (host@tags) data name :: acc)
(get ()) []
in
let datas = String.concat "" datas in