lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jean-Sebastien Vachon <>
Subject Re: JTeam Spatial Plugin
Date Tue, 11 May 2010 19:32:03 GMT

Thanks for your suggestion but I received more information about this issue from one of the
JTeam's developer and he told me that
my problem was caused by the plugin not supporting sharding at this time. 

In my case, I noticed that individual shards were computing the distance through the geo_distance
However, the "master" Solr instance controlling the shards was kind of loosing this information
from the lack of support for shards.

For now there is no quick work around that I know of.


On 2010-05-11, at 2:54 PM, Michael wrote:

> Try using "geo_distance" in the return fields.
> On Thu, Apr 29, 2010 at 9:26 AM, Jean-Sebastien Vachon
> <> wrote:
>> Hi All,
>> I am using JTeam's Spatial Plugin RC3 to perform spatial searches on my index and
it works great. However, I can't seem to get it to return the computed distances.
>> My query component is run before the geoDistanceComponent and the distanceField is
set to "distance"
>> Fields for lat/long are defined as well and the different tiers field are in the
results. Increasing the radius cause the number of matches to increase so I guess that my
setup is working...
>> Here is sample query and its output (I removed some of the fields to keep it short):
>> /select?passkey=sample&q={!spatial%20lat=40.27%20long=-76.29%20radius=22%20calc=arc}title:engineer&wt=json&indent=on&fl=*,distance
>> --------
>> {
>>  "responseHeader":{
>>  "status":0,
>>  "QTime":69,
>>  "params":{
>>        "fl":"*,distance",
>>        "indent":"on",
>>        "q":"{!spatial lat=40.27 long=-76.29 radius=22 calc=arc}title:engineer",
>>        "wt":"json"}},
>>  "response":{"numFound":223,"start":0,"docs":[
>>        {
>>         "title":"Electrical Engineer",
>>        "long":-76.3054962158203,
>>         "lat":40.037899017334,
>>         "_tier_9":-3.004,
>>         "_tier_10":-6.0008,
>>         "_tier_11":-12.0016,
>>         "_tier_12":-24.0031,
>>         "_tier_13":-47.0061,
>>         "_tier_14":-93.00122,
>>         "_tier_15":-186.00243,
>>         "_tier_16":-372.00485},
>> }}
>> This output suggests to me that everything is in place. Anyone knows how to fetch
the computed distance? I tried adding the field 'distance' to my list of fields but it didn't
>> Thanks

View raw message