lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mark harwood <>
Subject Re: [jira] Commented: (LUCENE-1781) Large distances in Spatial go beyond Prime MEridian
Date Fri, 11 Sep 2009 10:02:32 GMT
>> It seems like something higher up must accept two rects and OR them together during
the searching?

That's the way I've done it before. It's like the old "Asteroids" arcade game where as the
ship drifts off-screen stage right it is simultaneously emerging back from stage-left.

----- Original Message ----
From: Michael McCandless (JIRA) <>
Sent: Friday, 11 September, 2009 10:21:57
Subject: [jira] Commented: (LUCENE-1781) Large distances in Spatial go beyond Prime MEridian


Michael McCandless commented on LUCENE-1781:

Bill, could you please post a single patch that includes all of your changes (fixing LLRect
& TestCartesian)?  Also, please first "svn up" to the latest svn trunk so that the patch
applies cleanly.

bq.testPrimeM() should be fixed by the new It goes over 90 degrees, and
pole flips. If this is not working with the new LLRect, there is something wrong with that.

Hmm I'm seeing testPrimeM fail -- maybe once I sync to your new patch I'll see it pass.  Maybe
name that test "testPoleFlipping" or something instead?

So testPrimeM isn't testing the "miles is too large" issue?  If not, can you add a new test
that explicitly tests this?  We can use something ridiculous like 100000 miles.

bq. LLRect does calculate the right box across anti-meridien.

I agree that it calculates the correct "upper right" and "lower left", but when those cross
the anti-meridian, it's not possible to represent that with a single rect (you need two).
 This is where I'm waaaay out of my depth w/ GIS search... in general, how is this "normally"
handled?  It seems like something higher up must accept two rects and OR them together during
the searching?

> Large distances in Spatial go beyond Prime MEridian
> ---------------------------------------------------
>                 Key: LUCENE-1781
>                 URL:
>             Project: Lucene - Java
>          Issue Type: Bug
>          Components: contrib/spatial
>    Affects Versions: 2.9
>         Environment: All
>            Reporter: Bill Bell
>            Assignee: Michael McCandless
>             Fix For: 3.1
>         Attachments:, LUCENE-1781.patch, LUCENE-1781.patch,,
> Get an error when using Solr when distance is calculated for the boundary box past 90
> Aug 4, 2009 1:54:00 PM org.apache.solr.common.SolrException log
> SEVERE: java.lang.IllegalArgumentException: Illegal lattitude value 93.1558669413734
>         at org.apache.lucene.spatial.geometry.FloatLatLng.<init>(
>         at org.apache.lucene.spatial.geometry.shape.LLRect.createBox(
>         at org.apache.lucene.spatial.tier.DistanceUtils.getBoundary(
>         at org.apache.lucene.spatial.tier.CartesianPolyFilterBuilder.getBoxShape(
>         at org.apache.lucene.spatial.tier.CartesianPolyFilterBuilder.getBoundingArea(
>         at org.apache.lucene.spatial.tier.DistanceQueryBuilder.<init>(
>         at
>         at org.apache.solr.handler.component.SearchHandler.handleRequestBody(
>         at org.apache.solr.handler.RequestHandlerBase.handleRequest(
>         at org.apache.solr.core.SolrCore.execute(
>         at org.apache.solr.servlet.SolrDispatchFilter.execute(
>         at org.apache.solr.servlet.SolrDispatchFilter.doFilter(
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(
>         at org.apache.catalina.core.StandardWrapperValve.invoke(
>         at org.apache.catalina.core.StandardContextValve.invoke(
>         at org.apache.catalina.core.StandardHostValve.invoke(
>         at org.apache.catalina.valves.ErrorReportValve.invoke(
>         at org.apache.catalina.core.StandardEngineValve.invoke(
>         at org.apache.catalina.connector.CoyoteAdapter.service(
>         at org.apache.coyote.http11.Http11AprProcessor.process(
>         at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(
>         at$
>         at

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

To unsubscribe, e-mail:
For additional commands, e-mail:


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message