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

Return 0 for all buckets with 0 count on time-series TS.RANGE queries #50

Closed
dpipemazo opened this issue Aug 21, 2020 · 5 comments · Fixed by #51
Closed

Return 0 for all buckets with 0 count on time-series TS.RANGE queries #50

dpipemazo opened this issue Aug 21, 2020 · 5 comments · Fixed by #51
Labels
enhancement New feature or request question Further information is requested

Comments

@dpipemazo
Copy link
Contributor

Is your enhancement related to a problem? Please describe.

When using redis time series TS.RANGE commands with COUNT aggregation, grafana will show us interpolated lines between data samples:

Screenshot from 2020-08-21 08-20-19

Looking at the data from the query, the data source is returning a sparse set of data, which makes sense.

Screenshot from 2020-08-21 08-20-38

Describe the solution you'd like

It would be ideal to be able to clearly see time buckets with 0 data logged and have grafana show "0" for those buckets. I don't see the setting grafana-side and I see that some other grafana data sources have query "fill" options that will fill in blank time buckets with null values.

Describe alternatives you've considered

An alternative would be to file this grafana-side -- seems to be something they should support a bit more natively. I also might be missing something.

Additional context

This is using the latest grafana/grafana image launched with "GF_INSTALL_PLUGINS=redis-datasource". Redis 6.0.4 with Redis Time series 1.2.7 compiled from source.

@mikhail-vl mikhail-vl added the question Further information is requested label Aug 21, 2020
@mikhail-vl
Copy link
Contributor

@dpipemazo Thank you for submitting the issue.

I am checking with the RedisTimeSeries team what will be the best solution to implement it and will get back to you.

@mikhail-vl
Copy link
Contributor

@dpipemazo RedisTimeSeries recommended looking at how to implement it on the Grafana side.

Could you please give me an example of data sources which has a "fill" option to investigate.

@mikhail-vl mikhail-vl added the enhancement New feature or request label Aug 21, 2020
@dpipemazo
Copy link
Contributor Author

@mikhailredis thanks for the quick reply!

I found this thread this morning which shows options for InfluxDB and discusses some for postgres as well I believe

@mikhail-vl
Copy link
Contributor

@dpipemazo Looking at threads fill missing implemented for multiple datasource using $__timeGroup and a part of the query editor. Redis Datasource has his own query editor and I just added fill missing, which looks great.

Screen Shot 2020-08-22 at 2 05 43 PM

You can build it yourself following BUILD instructions and let me know if it works for you.
This feature will be available in the upcoming release submitted for review next week.

@dpipemazo
Copy link
Contributor Author

@mikhailredis (and team) awesome, thank you! Will build from source and try it out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request question Further information is requested
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants