Skip to content

Floats or integers? #151

Open
Open
@eproxus

Description

@eproxus

I'm super confused regarding float vs integer values. The Prometheus documentation itself recommends using the base unit seconds for duration (i.e. not milliseconds for example).

When recording duration histogram values in seconds I see very strange values in Prometheus, even though the data I log is quite sensible (i.e. request durations of 1.371114 seconds show up as 1e-09 in the metric http_client_total_duration_seconds_sum).

Are floats even supported in prometheus_histogram? The documentation says:

"Raises {invalid_value, Value, Message} if Value isn't an integer

Histograms seems to accept floats anyway, but I'm not sure it does the right thing with them.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions