[Open Discussion] Kibana Input Controls With Nested Support
Opened this issue · 4 comments
Background:
Since Kibana 6.1, interactive input controls for filtering data in dashboard are supported out-of-the-box. The controls are dropdown filter (for strings) and slicer filter (for numbers/dates).
There are some open-source controls to previous and even current Kibana versions, here are some of them:
- Dropdown: Dropdown Plugin, Dropdown Vis Plugin
- Slicer: Slider Plugin
- Timepicker: Time Plugin
- Other: Relational Filter Plugin, Searchbox
Problem:
The filters were desgined for extracting values from flat documents. Non of the filters (as far as I could see, please fix me if i'm wrong) support filter aggregations. This is crutial for not only finding the documents with the relevant nested values, but also to filter some of them out.
Examples are shown below.
-
Kibana visualization:
Kibana dropdown filter only allows matching terms by index pattern. Does the filter bar even supports aggregations? Or nested clauses (nested query, inner hits)? Tried to add some filters, but it didn't change the results.
. -
Open-Source visualization:
I have tested some of the external plugins out. With the support of this great plugin, additional nested clauses are added seemesly to existing queries they produce. But no filter aggregation is available (one type of aggregation only is supported).
Discussion:
Is there a workaround?
- Somehow add the ability to add aggregations right from the filter bar with this plugin. This might allow to add/merge the relevant filter aggregation. Seems pretty cool but pretty complicated.
- Adding support of filter aggregation to the existing filters. The question is wether to add them to the new supported filters in Kibnana 6.1+ or the external open-sourced filters.
Hmm.. I know that filters in Discover support nested fields, as I added that support. I may have missed this functionality in the dashboard and didn't properly test for it. Since the code I injected was put into the general filters javascript support I think I assumed it would work everywhere. Obviously I was mistaken.
The support for nested clauses is actually everywhere. Even in the dashboard filters. The problem is with somehow adding filter aggreggatios: nested aggregation clauses are seemly added when needed, but there is no place where I can add a proper filter aggregation afterwards to filter out unnecessary terms.
Does the query bar support aggregations in general?
The issue is open in v 7.9.1.
@ppadovani can you please suggest, some other way to manage input control for nested elements.