Hi Osma, as you can see below, it makes no difference:

[2017-01-09 09:07:12] Fuseki     INFO  [4] POST /spatial :: 'query' ::
[application/x-www-form-urlencoded charset=utf-8] ?
[2017-01-09 09:07:12] Fuseki     INFO  [4] Query = PREFIX spatial: <
http://jena.apache.org/spatial#> PREFIX rdfs: <
http://www.w3.org/2000/01/rdf-schema#>  SELECT distinct ?place {     ?place
spatial:intersectBox (31.556 -117.128654 31.556  -117.128658) .    }
[2017-01-09 09:07:16] Fuseki     INFO  [4] exec/select
[2017-01-09 09:07:16] Fuseki     INFO  [4] 200 OK (3.561 s)
[2017-01-09 09:07:21] Fuseki     INFO  [5] POST
http://localhost:3030/spatial/query
[2017-01-09 09:07:21] Fuseki     INFO  [5] POST /spatial :: 'query' ::
[application/x-www-form-urlencoded charset=utf-8] ?
[2017-01-09 09:07:21] Fuseki     INFO  [5] Query = PREFIX spatial: <
http://jena.apache.org/spatial#> PREFIX rdfs: <
http://www.w3.org/2000/01/rdf-schema#>  SELECT   ?place {     ?place
spatial:intersectBox (31.556 -117.128654 31.556  -117.128658) .    }
[2017-01-09 09:07:25] Fuseki     INFO  [5] exec/select
[2017-01-09 09:07:25] Fuseki     INFO  [5] 200 OK (4.350 s)
[2017-01-09 09:07:28] Fuseki     INFO  [6] POST
http://localhost:3030/spatial/query
[2017-01-09 09:07:28] Fuseki     INFO  [6] POST /spatial :: 'query' ::
[application/x-www-form-urlencoded charset=utf-8] ?
[2017-01-09 09:07:28] Fuseki     INFO  [6] Query = PREFIX spatial: <
http://jena.apache.org/spatial#> PREFIX rdfs: <
http://www.w3.org/2000/01/rdf-schema#>  SELECT   ?place {     ?place
spatial:intersectBox (31.556 -117.128654 31.556  -117.128658) .    }
[2017-01-09 09:07:34] Fuseki     INFO  [6] exec/select
[2017-01-09 09:07:34] Fuseki     INFO  [6] 200 OK (5.334 s)

I wonder why is so slow if the lucene index is so fast and the result set
contains only 17 resources.

On 9 January 2017 at 08:55, Osma Suominen <[email protected]> wrote:

> Hi Samur!
>
> Does it help if you drop the DISTINCT?
>
> -Osma
>
>
> 09.01.2017, 09:49, Samur Araujo kirjoitti:
>
>> Hi all, I noticed that jena spatial is very slow.
>>
>> Query like the one below take 3s to execute (under entire geonames).
>>
>> PREFIX spatial: <http://jena.apache.org/spatial#>PREFIX rdfs:
>> <http://www.w3.org/2000/01/rdf-schema#>
>> SELECT distinct ?place{
>>     ?place spatial:intersectBox (32.55668 -117.12865 32.56668
>> -117.13865) .
>>   }
>>
>> The same query in solr/lucene takes only 20ms.
>>
>> I wonder why fuseki or jena spatial is so slow.
>>
>> Any clue about it?
>>
>>
>
> --
> Osma Suominen
> D.Sc. (Tech), Information Systems Specialist
> National Library of Finland
> P.O. Box 26 (Kaikukatu 4)
> 00014 HELSINGIN YLIOPISTO
> Tel. +358 50 3199529
> [email protected]
> http://www.nationallibrary.fi
>



-- 
Senior Data Scientist
Geophy
www.geophy.com

Nieuwe Plantage 54-55
2611XK  Delft
+31 (0)70 7640725

1 Fore Street
EC2Y 9DT  London
+44 (0)20 37690760

Reply via email to