Swirrl / cubiql

CubiQL: A GraphQL service for querying multidimensional Linked Data Cubes
Eclipse Public License 1.0
41 stars 2 forks source link

Resolve all matching dataset metadata in a single query. #141

Closed lkitching closed 6 years ago

lkitching commented 6 years ago

Issue #116 - Resolve metadata for all returned datasets in a single query rather than submitting a query for each dataset individually.

lkitching commented 6 years ago

@zeginis - Please could you take a look and let me know if this change improves the performance to an acceptable level on the datasets query.

zeginis commented 6 years ago

@lkitching I tried running this at the Scotish data and I get and "Internal server error: exception"

lkitching commented 6 years ago

@zeginis - Does it work now? I think the server was under heavy load earlier but it's working locally for me now.

zeginis commented 6 years ago

@lkitching I still get the "Internal server error: exception"

I run the query:

{cubiql{
  datasets{    
     title
  }
}}

The exception: exception.txt

I try at: http://staging-drafter-sg.publishmydata.com/v1/sparql/live The configuration I use:

{:geo-dimension-uri "http://purl.org/linked-data/sdmx/2009/dimension#refArea"
 :time-dimension-uri "http://purl.org/linked-data/sdmx/2009/dimension#refPeriod"
 :codelist-source "component"
 :codelist-label-uri "http://www.w3.org/2000/01/rdf-schema#label"
 :dataset-label-uri "http://www.w3.org/2000/01/rdf-schema#label"
 :schema-label-language nil
 :max-observations-page-size 2000}

Using other queries works fine:

{cubiql{
  dataset_employment {   
    title    
  }}}
zeginis commented 6 years ago

The same query works fine at master

lkitching commented 6 years ago

@zeginis - Does it work for you if you change the endpoint URI to https://staging-drafter-sg.publishmydata.com/v1/sparql/live? It looks like that endpoint is redirecting to https which the rdf4j client doesn't like. It doesn't seem to throw an exception reliably though.

zeginis commented 6 years ago

@lkitching at the endpoint you send it works fine and the performance is much better. So we can merge the PR.