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

Invalid frequency causes division by zero in alert scheduler. #14810

Closed
bergquist opened this issue Jan 10, 2019 · 0 comments

Comments

Projects
None yet
1 participant
@bergquist
Copy link
Contributor

commented Jan 10, 2019

It should not be possible to save an dashboard with an alert with an invalid frequency.
The frequency should be in a golang time.Duration and larger than zero.
Having frequency set at zero causes division by zero panics in the scheduler.

Accepted input: 1s, 1m, 1h
Invalid input: 1, 0s, 0m, 0h

Alert rule that allready exists with invalid frequency should default to 1m

@bergquist bergquist added this to the 5.4.3 milestone Jan 10, 2019

@bergquist bergquist self-assigned this Jan 10, 2019

bergquist added a commit to bergquist/grafana that referenced this issue Jan 10, 2019

make sure frequency cannot be zero
frequency set to zero causes division by zero
panics in the alert schedular.

closes grafana#14810

bergquist added a commit to bergquist/grafana that referenced this issue Jan 10, 2019

make sure frequency cannot be zero
frequency set to zero causes division by zero
panics in the alert schedular.

closes grafana#14810

bergquist added a commit to bergquist/grafana that referenced this issue Jan 10, 2019

make sure frequency cannot be zero
frequency set to zero causes division by zero
panics in the alert schedular.

closes grafana#14810

bergquist added a commit to bergquist/grafana that referenced this issue Jan 10, 2019

make sure frequency cannot be zero
frequency set to zero causes division by zero
panics in the alert schedular.

closes grafana#14810

@bergquist bergquist closed this in fbb3ad5 Jan 10, 2019

xlson added a commit that referenced this issue Jan 11, 2019

make sure frequency cannot be zero
frequency set to zero causes division by zero
panics in the alert schedular.

closes #14810

(cherry picked from commit fbb3ad5)

xlson added a commit that referenced this issue Jan 14, 2019

make sure frequency cannot be zero
frequency set to zero causes division by zero
panics in the alert schedular.

closes #14810

(cherry picked from commit fbb3ad5)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.