Remove Dependency for "stanbol.commons.web.sparql" to 
"stanbol.contenthub.servicesapi"
--------------------------------------------------------------------------------------

                 Key: STANBOL-580
                 URL: https://issues.apache.org/jira/browse/STANBOL-580
             Project: Stanbol
          Issue Type: Bug
          Components: Commons, Content Hub
            Reporter: Rupert Westenthaler
            Assignee: Suat Gonul


Commons Module MUST NOT depend on any other Stanbol modules other than Commons. 
Because of that the "org.apache.stanbol.commons.web.sparql" MUST NOT depend on 
"org.apache.stanbol.contenthub.servicesapi"

Possible Solution:

I would suggest to use the Whiteboard pattern to register TripleCollections 
that should be exposed by SPARQL. The SparqlEndpointResource could than lookup 
all NamedGraphs - the registered TripleCollections - by using the BundleContext 
or a ServiceTracker.

Additional Notes:

*  This solution would allow to expose multiple query-able RDF graphs via 
{stanbol}/sparql
* SPARQL already allows to specify the graph to query by using the 
"default-graph-uri" parameter. This parameter should be supported by 
"stanbol.commons.web.sparql" to allow requests to select a specific registered 
TripleCollection for the query
* If no "default-graph-uri" is specified the TripleCollection registered with 
the higest "service.ranking" (if multiple lowest "service.id") is used to 
execute the query

The following properties are supported for  ServiceRegistrations of 
TripleCollections:

* "graph.uri" (requried) : The URI of the graph. This is the same as used with 
the TcManager
* "service.ranking" : If not than '0' will be used as default
* "graph.name" : The name of the graph. Human readable name intended to be used 
in the UI of the SparqlEndpointResource (dropdown box to select one of the 
registered TripleCollections)
* "graph.description" : A human readable description providing additional 
information about the RDF graph.

NOTE: I would not recommend to directly use the TcManager because

1. we might not want to make all grpahs public available
2. we might want to publish graphs hold in-memory that are not registered with 
any TcManager (e.g. the configuration of the Stanbol instance)

If this proposal is accepted I would recommend to copy this description to an 
own sub-task

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to