dsmiley at mitre
May 4, 2011, 7:45 AM
Post #2 of 6
The Lucene spatial module is slated to be eliminated soon because of its complexity and bugs that have confounded Lucene committers. Ryan McKinley, Chris Male, and I are working on a replacement but it isn't ready. If I were you I wouldn't waste time trying to understand that module. If you can wait a couple months, I would wait. If not, I suggest looking at the basic geospatial search capability in Solr (which uses very little from Lucene) and then try to extract that. I'll warn you if you need to do any distance sorting, it's going to get complicated fast. Distance sorting uses Solr function queries.
~ David Smiley
On May 4, 2011, at 12:49 AM, Film Noir wrote:
> Hi all,
> First of all, I have to say my understanding of Lucene Spatial is very
> little and the Googling and forum/mail list searching hasn't gotten me very
> I'm trying to determine if I can use Lucene-Spatial 3.1.0 with Hibernate
> Search 3.1.0. The article on DZone talks of this very issue:
> I'm having trouble with the implementation though, I have tried implementing
> the getLatLng() ( with CartesianTierFieldBridgeImpl ) and getGeohash()
> methods in the Entity, without success.
> Does anyone have experience mixing the two who could provide some pointers?
> I'm working with the following code below to attempt the return the
> addresses that are within 5 miles of NY:
> DistanceQueryBuilder builder = new
> DistanceQueryBuilder(40.689168,-74.044563, 10.0, "addrLatitude",
> "addrLongitude", CartesianTierPlotter.DEFALT_FIELD_PREFIX, true, 0, 20);
> FullTextSession fullTextSession = Search.getFullTextSession(
> sessionFactory.getCurrentSession() );
> FullTextQuery fullTextQuery = fullTextSession.createFullTextQuery(
> builder.getQuery( new MatchAllDocsQuery() ), Address.class );
> View this message in context: http://lucene.472066.n3.nabble.com/Lucene-Spatial-and-Hibernate-Search-tp2897389p2897389.html
> Sent from the Lucene - General mailing list archive at Nabble.com.