go-http-metrics
go-http-metrics copied to clipboard
Support custom labels
Hello @slok,
I've added custom labels support for my project and now I see that this may be the solution for #47. Also did tiny tests cleanup during my work.
Custom labels are supported for prometheus as this is the collector I personally use. However, new functionality does not break previous implementation of Recorder and anyone can add custom labels support for any existing recorder.
FastHTTP example is also provided.
Hope this PR help someone.
Hey @slok, would you take a look at this PR please?
Hi @sashayakovtseva
Thanks for the PR, sorry I missed this one.
I don't know if we want to implement this in the library as today, dynamic labels are tricky and could have undesired side effects.
For now, I would like to park this feature and think a bit more.
Also, we have this other PR #74 that implements a similar feature.
This PR was opened before #74