Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Support float64 gauges #150

Open
rzimmerman opened this issue Mar 16, 2023 · 0 comments
Open

feat: Support float64 gauges #150

rzimmerman opened this issue Mar 16, 2023 · 0 comments

Comments

@rzimmerman
Copy link

It can be useful to represent a Unix timestamp in a gauge. Prometheus metrics are float64s, so this works well when directly using the Prometheus libraries. However, because go-metrics Guage's are stored as float32s, there isn't enough precision to store a timestamp (https://go.dev/play/p/RvJ11Y8R7Cz) and times get truncated to about 2 minute intervals.

There's one instance of this in Vault: https://github.com/hashicorp/vault/blob/2dd4528ed8a8be83e0c1e0b48b1f23dab701181f/builtin/logical/pki/path_tidy.go#L1209
Which may be a bug.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant