swift-server / swift-prometheus

Prometheus client library for Swift
https://swiftpackageindex.com/swift-server/swift-prometheus
Apache License 2.0
145 stars 32 forks source link

Add missing call to label customization closure for meter #111

Closed simonjbeaumont closed 8 months ago

simonjbeaumont commented 8 months ago

Motivation

The PrometheusMetricsFactory has a nameAndLabelSanitizer closure property to customize the name and labels used by callers of the Swift Metrics API. This wasn't being called in makeMeter.

Modifications

Call nameAndLabelSanitzer in makeMeter, like in the other factory methods.

Result

All factory methods use the customization closure, nameAndLabelSanitizer.

ktoso commented 8 months ago

@swift-server-bot test this please