Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [geomesa-users] Geomesa Cassandra Query Issue

Hi Jonathan,

Thanks for the clear images; those help illustrate the issue quite nicely!

As some good news, I can explain the issue, hopefully provide a work-around (and a diagnosis step). 

With 'large' polygons, there is a corner case where it becomes challenging to know whether or not the desired polygon crosses the anti-meridian or not.  For your second case, the query re-writer uses Spatial4J and assumes that the connections between the upper left and right corners goes the other way around the planet.  That's why the result set seems to flip.

Incidentally, for BBOX queries, there's no such confusion and hence those work just fine.

The solution is to add additional way points so that successive coordinates have a difference in longitude less than 180 degrees. 

As a debugging step, check out the GeoMesa query explainer:
http://www.geomesa.org/documentation/user/datastores/explaining.html
http://www.geomesa.org/documentation/user/geoserver.html#geoserver-explain-query

I think the filter re-writing would have already happened.  That'd give some insight into whether or not GeoMesa has flipped the query around.

Cheers,

Jim

On 12/19/2017 05:09 PM, Jonathan Meyer wrote:

 

 

I am using Geomesa with a  Cassandarda data store.  I have come across a potential issue that I’m not sure how to deal with and am hoping someone may be able to shed some light.  I have a front end web app using leaflet to display point data queried from Geoserver.  So I am using the Geomesa Cassandra plugin to geoserver.  I have an edge case where if a user enters a very large (80% of the world) polygon search area, the search results will return all the points outside the polygon and not inside the polygon.  Using a BBox instead of a polygon in the same approximate area will return all the points within the bbox as expected.  Drawing a polygon that is say 60% of the world will also return expected results.  There seems to be some point where polygon searches don’t return what is expected.   The only thing that changes in these searches is the shape or size of the geometry.

Any help or suggestions greatly appreciated.

 

See the below images as examples:

 

 

 

Jonathan Meyer

 



_______________________________________________
geomesa-users mailing list
geomesa-users@xxxxxxxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.locationtech.org/mailman/listinfo/geomesa-users



Back to the top