LinkedDataFragments / Client.Java

A Triple Pattern Fragments client for Java (Jena)
MIT License
8 stars 10 forks source link

4+ sec for a construct query? #7

Closed m1ci closed 9 years ago

m1ci commented 9 years ago

Hi, I'm using the Java client and running "quite" simple CONSTRUCT query which takes around 4 seconds to execute. The CONSTRUCT query is:

CONSTRUCT {
  <http://dbpedia.org/resource/Germany> <http://purl.org/dc/terms/subject> ?category .
  ?category <http://freme-project.eu/ns#info> ?info .
  ?category <http://www.w3.org/2000/01/rdf-schema#label> ?label
 } WHERE {
  <http://dbpedia.org/resource/Germany> <http://purl.org/dc/terms/subject> ?category .
  ?category <http://freme-project.eu/ns#info> ?info .
  ?category <http://www.w3.org/2000/01/rdf-schema#label> ?label 
}

and it is executed against http://rv2622.1blu.de:5000/dbpedia-categories LDF endpoint.

Am I doing smth wrong or this is expected time? I tried to run the same query but using the JS client at http://rv2622.1blu.de/ldf-client/ and it is executed much faster.

Thanks!

m1ci commented 9 years ago

oh, I see, this has been already discussed in previous issue https://github.com/LinkedDataFragments/Client.Java/issues/4 So, this performance seems to be expected. Unfortunately, we need to execute thousands of such construct queries in reasonable time. Maybe I try to split the construct in 3 simple request but this seems to be the same what the client is doing....

RubenVerborgh commented 9 years ago

@m1ci Your best bet is the JavaScript client at the moment. The current Java stack (Jena) is not well-suited for the task. I will clarify this in the README.

RubenVerborgh commented 9 years ago

Clarified in 1312b02d4a44548a53428bd8ef8d6455b9dd4cf2.