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

Do not suppress 0 values #11

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

ijc
Copy link

@ijc ijc commented Nov 15, 2024

0 is a valid value for a gauge or a counter (e.g. "number of active sessions"
can easily be zero and that state is distinct from is distinct 1) and zero
samples in a period is legit for a histogram over an interval.

For gauges we should also not reset to zero on each render, but we should
continue to do so for counters.

Suppression of idle metrics should be done using StatsdBuilder::idle_timeout.

Fixes #5 (at least in line with my opinion in #5 (comment)).

0 is a valid value for a gauge or a counter (e.g. "number of active sessions"
can easily be zero and that state is distinct from is distinct 1) and zero
samples in a period is legit for a histogram over an interval.

For gauges we should also not reset to zero on each render, but we should
continue to do so for counters.

Suppression of idle metrics should be done using `StatsdBuilder::idle_timeout`.

Fixes dialtone#5
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

Successfully merging this pull request may close these issues.

Not reporting a gauge value of zero
1 participant