-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
Feat geofilter from filterbar #145465
Feat geofilter from filterbar #145465
Conversation
Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually? |
Thanks for opening this PR. Spatial filtering has been an often talked about feature that has unfortunately not made a lot of forward progress. The Kibana team is excited to see community interest in spatial filtering. #1511 from all the way back in 2014 There is even this closed PR #111897 from 2021 that attempted to fix some issues with filters created in Maps application and allow them to work better with the filter editor. There are a lot of edge cases and complexity with how filters work throughout Kibana. In order to reduce complexity, how about simplifying the approach in this PR to support only the bare minimum of spatial filtering? Then once the edge cases have been resolved, future enhancements can build on top of that foundation. Mainly, how about supporting only the following operators with this PR
That way the UI can be simplified, removing the map and just providing a lat input, lon input, and distance input. Simplification will allow this PR to focus on addressing spatial filter edge cases without the complexity of UI concerns. |
@nreese The filter that I put in place only supports geo_shape queries and the associated spatial relations as the operators. https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-geo-shape-query.html#geo-shape-spatial-relations. However, looking at the linked issue #67905 I see the complexity concern because it breaks the DataGrid Expanded actions filter for/filter out buttons. I Have a bunch of meetings today and tomorrow but I can take a look at correcting that when I have free time. |
Was actually able to look at it during my meeting and fix it. Please let me know if there are any other edge cases that are broken and need to be fixed to accept this PR. |
Geo distance filter supports geo_point and geo_shape and is a great starting point. The best thing about starting with geo distance is that it avoids needing a map in the UI. Adding in a map into the UI creates a lot of complex problems that are not easy to answer
These and other issues make it imperative that the first spatial filter implementation be as simple as possible and avoid a map in the UI. Using distance filter and simple UI provides the opportunity to move forward without being blocked by any of these concerns. |
@nreese I agree with you.
|
@nreese would you and the other stakeholders have more interest in me making a plugin interface for the unified search that would function similar to the "edit query as DSL" button? I am envisioning a nav bar with the built in "Edit Filter values" and "Edit query as DSL", then button for each unified search plugin that was registered. This way users have the ability to add new filtering features to accommodate their needs without changing the baseline for everyone. I think this would solve the duplicated code worries since it isn't part of the baseline. I do think that unified geofiltering would be a valuable feature for the everyone, and a plugin approach would also make it fairly simple to incorporate these additions into the baseline at a future date. |
We are discussing this internally and will get back to you in the next week or 2. |
Creating a plugin interface for filters is a large effort and unfortunately the Kibana team does not have the resources to work with community members to design, build, and test such an interface at this time. While we do see the value in the proposal, we are not able to support any efforts in the area of a pluggable filter interface. |
I added an ER to track this needs #147741. Feel free to comment and add your thoughts about this idea there. |
Pinging @elastic/kibana-presentation (Team:Presentation) |
Summary
Add ability to create geospatial filters from the filter bar
#144064
For maintainers