-
Notifications
You must be signed in to change notification settings - Fork 12.3k
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
movingAverage / movingMedian parameter type #1207
Milestone
Comments
Thanks for reporting this, will investigate |
Fixed! |
Thanks! |
This was referenced Dec 25, 2022
This was referenced Dec 25, 2022
This was referenced Jun 20, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The movingAverage and movingMedian functions in Graphite can both take either an int argument to define the window size in samples or a string argument to define the window size as a time period (e.g. '10m'). For some reason Grafana only supports the latter for movingMedian and the former for movingAverage.
It is possible to enter a time period for movingAverage by manually putting it in quotes (e.g. movingAverage('10m')) but the editor will remove the quotes at some point so it becomes movingAverage(10m), breaking the syntax. On the other hand, it is impossible to enter a window size in samples for movingMedian as the editor forces the quotes there (e.g. movingMedian('10')), which again breaks the syntax.
Not sure what's the best way to fix this. I would vote for making both functions behave the same way as movingMedian currently does (ie. take a string parameter) as it makes more sense to me to define the window size as a time period, but I suppose some people may disagree. Is there a way to add support for both formats?
Test cases (all four should work according to http://graphite.readthedocs.org/en/latest/functions.html#graphite.render.functions.movingAverage):
The text was updated successfully, but these errors were encountered: