RE: [Sparql4j-devel] Design issue: datasource
Status: Pre-Alpha
Brought to you by:
jsaarela
|
From: Seaborne, A. <and...@hp...> - 2005-01-25 12:15:50
|
-------- Original Message -------- > From: Alberto Reggiori <> > Date: 20 January 2005 10:36 >=20 > On Jan 20, 2005, at 10:04 AM, Janne Saarela wrote: >=20 > > > > I would like to propose the datasource for this driver to be > > > >=20 > > > > jdbc:sparql4j:[http|other]://www.serveraddress.com[:port]/path/more; > > > > param1=3Dvalue1 > > >=20 >=20 > [...snip...] >=20 > > > Hmm, - actually there is a level missing. We need something like: > > > jdbc:sparql4j:sparql (yuk - 2 sparql's) to say: > > > jdbc:sparql4j > > > Get JDBC to route requests to our driver > > > jdbc:sparql4j:sparql > > > our driver is going to use the SPARQL protocol > > > jdbc:sparql4j:sparql:http://server/path > > > our driver is going to use SPARQL protocol at the named service > > > May be that's excessive. An alternative is to not have sparql4j be > > > the subprotocol name and directly name the connection protocol: >=20 > and we have to keep inmind that URIs has generally a <4k max size (or > the network/firewalls might limit that) - and we want to be sure that > those "connection" parameters are not too verbose (I would be in favor > or k/v paris vs. full blown URIs if not necessary) Agree about 4k - there are some 1k limits in old proxies I gather (never met one myself). Connection URL and service request URL are different. In my quick-hack driver, I found the javax.sql.DataSource interface useful - the service description can be passed in there. To stick to java.sql, then a nasty encoding into the JDBC URL (which is unpacked by the driver (never leaves the machine - no 4k limit). c.f. the JDBC-ODBC bridge where the driver takes params.=20 >=20 > > I'm wondering what happens if the sparql protocol enables short names > > in the 'lang' attribute value, will the datasource effectively have > > to be something like=20 > >=20 > > jdbc:sparql:http://server/queryprocessor?lang=3Dsparql > >=20 > > This would mean any service description part of the protocol would > > need to be available before an application is built. >=20 > what do we mean for "service description" ? I hope not the WS XML world > meaning of it - or even worse OWL-S :) >=20 > Default is SPARQL (no lang param) - otherwise specified That seems to be the way the F2F was going but we have to await draft text to be sure. It's all very fluid. >=20 > > A datasource such as > >=20 > > jdbc:sparql:http://server/queryprocessor > >=20 > > would effectively have to fetch a service description before launching > > the first query in order to determine the 'lang' value. Luckily that > > value should be cacheable not having to fetch it before every single > > query. >=20 > also me worried about how to process that "service description" - I am > digging into JDBC3.0 spec chapter 7 (Database Metadata) and other > implementations around - which has some methods to retrieve general > information about the data source - not sure how much flexible > though... Good point. java.sql does rather prescibe the DB details but something might be workable. >=20 > Alberto Andy |