prometheus.ex icon indicating copy to clipboard operation
prometheus.ex copied to clipboard

Prefer already formatted time value instead of native time

Open svileng opened this issue 4 years ago • 0 comments

Getting Histograms to work with time values is not straightforward. I never used or converted any time values to native time until I started using this library. I think this is counter intuitive and prone to error, since it is easy to mis-read the documentation.

It will be much more natural to do the conversion to native time inside the library by default, rather than asking the user to do so every time. This way the user can supply an integer/float and the library will do the conversion for you.

I realise this will be a breaking change but I think it will pay off. What do you think?

svileng avatar Apr 27 '20 21:04 svileng