-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Discover] Drop the separate total hits request in ES|QL mode. Use th…
…e number of fetched records instead. (#178711) - Addresses a part of #177156 ## Summary This PR changes how the total hits counter is reported in Discover for ES|QL mode. The previous logic could be misleading as the received documents count sometimes was not the same as the shown total hits counter. Often it's because for ES|QL queries without sorting, separate requests might return different result. Before: Number of received docs in Discover was considered only as "partial" result for total hits. The final value was coming from UnifiedHistogram: - if chart is visible and histogram => total hits are based on the result of the histogram fetch request - if chart is visible and it's not a histogram but based on discover fetched records => total hits are calculated from the number of records - if chart is hidden => total hits are based on the results of the separate request for getting the count only After: Number of received docs in Discover is considered as "complete" result for total hits. Changes for UnifiedHistogram: - if chart is visible and histogram => logic stays but the histogram total hits count is ignored on Discover side - if chart is visible and it's not a histogram but based on discover fetched records => logic stays but the histogram total hits count is ignored on Discover side - if chart is hidden => this request is removed completely. It's a proposal. Happy to discuss. --------- Co-authored-by: Stratoula Kalafateli <[email protected]>
- Loading branch information
Showing
5 changed files
with
52 additions
and
108 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,7 +12,6 @@ | |
"dataViews", | ||
"embeddable", | ||
"inspector", | ||
"expressions", | ||
"visualizations" | ||
] | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters