Skip to content

Conversation

@slorello89
Copy link
Contributor

No description provided.

@slorello89 slorello89 requested a review from banker June 1, 2023 17:54
@codecov
Copy link

codecov bot commented Jun 1, 2023

Codecov Report

Merging #297 (de4fc7b) into master (f9d3d8a) will increase coverage by 0.13%.
The diff coverage is 99.24%.

@@ Coverage Diff @@ ## master #297 +/- ## ========================================== + Coverage 94.67% 94.81% +0.13%  ========================================== Files 39 39 Lines 2686 2776 +90 Branches 80 87 +7 ========================================== + Hits 2543 2632 +89  Misses 132 132 - Partials 11 12 +1 
Impacted Files Coverage Δ
src/redis/command.ts 100.00% <ø> (ø)
src/components/QueryEditor/QueryEditor.tsx 98.03% <96.42%> (-0.38%) ⬇️
pkg/query.go 100.00% <100.00%> (ø)
pkg/redis-search.go 100.00% <100.00%> (ø)
src/redis/search.ts 100.00% <100.00%> (ø)
@SaadAdel539
Copy link

Thank you for adding the support for ft.search

However, I came across an issue while trying to create a Panel for the dashboard using it

Issue
the query returns ONLY the first document while creating the Panel unless you enable the Streaming option

Steps to generate

  1. create a new panel
  2. Fields values:
  • Type = RedisSeatch
  • Command = FT.SEARCH
  • Key = {your index name} (choose an index with more than one document)
  • rest of keys leave them as default

Result: only one document
Expected result: the first 10 docs in the index
Workaround: enable the Streaming option

@slorello89
Copy link
Contributor Author

@SaadAdel539 - first off, big thanks for taking a look at this.

Secondly, yep I see what you are talking about. It technically IS responding with all the results, but they were segmented into different frames, so you could choose between which frame was being displayed. Naturally this format doesn't make any sense when you are working with an FT.SEARCH, so I've moved everything into a single response frame - and now it should look correct.

Of course the explorer view (which I was initially using to check this) squashes all the frames in the result set together to get a much more sensible looking result.

If you take a look now, you should get what you are looking for:

image

@slorello89 slorello89 requested a review from j8-redis July 5, 2023 13:38
@slorello89 slorello89 merged commit f30b262 into RedisGrafana:master Jul 12, 2023
@zidokobik
Copy link

It seems like Grafana variable is not supported in the query input.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

4 participants