Page
Library
Module
Module type
Parameter
Class
Class type
Source
Core/Lwt split:
Add a new prometheus-lwt metrics package. (@avsm @mtelvers @talex5 #66 #67 #68 #69, reviewed by @dinosaure)
This release is not a breaking change, but instead prepares for deprecation of Lwt in the core package so a future release can remove Lwt from the prometheus core. Users of the core's Lwt-typed functions should migrate to Prometheus_lwt now. Code using the new interface will keep working unchanged in future releases.
prometheus-lwt.gettime argument. Instead, this is provided once by the new Prometheus.init function, which is called automatically when using Prometheus_unix.To migrate existing code, add a dep on prometheus-lwt and rename following the deprecation warnings from the compiler.
Bug fixes:
%.17g (@samoht @talex5 #62). The text exposition formatter printed metric values with %f, so any magnitude below ~5e-7 was reported as 0.000000.Other changes:
Astring dependency (@talex5 #63).Asetmap dependency (@talex5 #64). This changes the types of LabelSetMap and MetricFamilyMap slightly, which might affect custom reporters.# TYPE rather than #TYPE in the output.Makefile target run tests (@talex5 #49).Add logging configuration (#29, @talex5). To configure a server to report counts for log messages:
let () = Prometheus_unix.Logging.init ()This installs a reporter that reports the number of messages logged by each log source and at each level. The reporter also displays the timestamp and log source with each message, which is a more suitable configuration for servers.
"%f" (#22, @toots)Gc.quick_stat for faster stats (#25, @talex5)Sample_set module to clean up the API a bit (#13, @talex5)Re rather than Str