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

[Maps] query error on document layer index missing filtered shape field #48462

Closed
bcamper opened this issue Oct 16, 2019 · 4 comments · Fixed by #62966
Closed

[Maps] query error on document layer index missing filtered shape field #48462

bcamper opened this issue Oct 16, 2019 · 4 comments · Fixed by #62966
Labels
bug Fixes for quality problems that affect the customer experience [Deprecated-Use Team:Presentation]Team:Geo Former Team Label for Geo Team. Now use Team:Presentation regression

Comments

@bcamper
Copy link

bcamper commented Oct 16, 2019

I believe this is a regression related to #47171.

I have 3 document layers, and I use 1 layer to create a filter against another layer, with coordinates as the filtered field:

filter-error-1

This creates a geo_shape filter using the indexed shape:

filter-error-2

This then causes an error on the 3rd layer, which lacks a coordinates field (it has a geo_point field called location_geo):

filter-error3

This works properly on 7.4, and I verified that it works in the console when I use the old inline shape query method. I would have expected the indexed shape query to work with ignore_unmapped: true set (which it is), but that doesn't seem to be the case (perhaps I misunderstand how it's supposed to behave here though).

@bcamper bcamper added bug Fixes for quality problems that affect the customer experience [Deprecated-Use Team:Presentation]Team:Geo Former Team Label for Geo Team. Now use Team:Presentation labels Oct 16, 2019
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-gis (Team:Geo)

@nreese
Copy link
Contributor

nreese commented Oct 17, 2019

geo_point can not use geo_shape query so that is why there is a failure.

This would have failed in 7.4 because the generated query was also a geo_shape query. The only thing
#47171 changed was using pre-indexed shape instead of passing geometry in the query

Elasticsearch team is working on adding geo_point support to geo_shape query so these type incompatibilities will go away in the future but the problem will always exist if the geo field names are different,

@nreese
Copy link
Contributor

nreese commented Oct 17, 2019

Maybe we could add an option in the drop down to "Apply to all" that would create a should clause that adds a filter for each geo field name and type paring. The problem is that this will include the geometry for each query if its not indexed in Elasticsearch and not querying against geo_shape field so it will increase the likely hood of #45521.

But I could see this being really useful for drawing filters since the geometry is small and #45521 is not an issue.

@bcamper
Copy link
Author

bcamper commented Oct 19, 2019

geo_point can not use geo_shape query so that is why there is a failure.
This would have failed in 7.4 because the generated query was also a geo_shape query. The only thing #47171 changed was using pre-indexed shape instead of passing geometry in the query

It doesn't generate an error in 7.4 or in master though, when running the same query with an inline shape field. It just returns no results. That may not be intentional, but that's the behavior I observe.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Fixes for quality problems that affect the customer experience [Deprecated-Use Team:Presentation]Team:Geo Former Team Label for Geo Team. Now use Team:Presentation regression
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants