#metrics #exporter #log #metrics-core

metrics-exporter-log

A metrics-core compatible exporter for forwarding metrics to logs

5 releases (3 breaking)

0.4.0 Jan 22, 2020
0.3.0 Jul 30, 2019
0.2.1 Jun 11, 2019
0.2.0 May 1, 2019
0.1.0 Apr 24, 2019

#7 in #exporter

Download history 613/week @ 2022-10-13 907/week @ 2022-10-20 959/week @ 2022-10-27 1848/week @ 2022-11-03 1183/week @ 2022-11-10 1339/week @ 2022-11-17 2438/week @ 2022-11-24 1492/week @ 2022-12-01 1124/week @ 2022-12-08 1332/week @ 2022-12-15 858/week @ 2022-12-22 1201/week @ 2022-12-29 1294/week @ 2023-01-05 1429/week @ 2023-01-12 1459/week @ 2023-01-19 1618/week @ 2023-01-26

6,094 downloads per month
Used in 2 crates

MIT license

18KB
238 lines

metrics-exporter-log

conduct-badge downloads-badge release-badge docs-badge license-badge

metrics-exporter-log is a metrics-core compatible exporter for forwarding metrics to logs.

code of conduct

NOTE: All conversations and contributions to this project shall adhere to the Code of Conduct.


lib.rs:

Exports metrics via the log crate.

This exporter can utilize observers that are able to be converted to a textual representation via [Drain<String>]. It will emit that output by logging via the log crate at the specified level.

Run Modes

  • Using run will block the current thread, capturing a snapshot and logging it based on the configured interval.
  • Using async_run will return a future that can be awaited on, mimicing the behavior of run.

Dependencies

~3MB
~41K SLoC