Hi, We have written a Jena client application that uses RDFConnectionFactory, as specified in the Jena docs.
Recently, we switched to a new remote triple store (MarkLogic) that uses digest auth. We would like to be able to handle the auth properly, and we would also like to send additional query string params with each request, like "?database=MyDb". How can we specify these things through the RDFConnectionFactory/RDFConnection interface? Can I set it up so that the digest auth only happens once, when the RDFConnection is created? I looked at the RDFConnectionRemote class, and noticed that an HttpClient can be set. This setting is not part of the factory interface. It seems like the HttpClient is not always used; the query method, for example, calls: QueryExecutionFactory.createServiceRequest(svcQuery, query) ...which does not pass the httpClient param. This seems like it could be a bug - maybe someone can confirm this? I also noticed that the method of supplying params to a request via HttpClient (HttpClient.getParams()) seems to be deprecated. It says to use RequestConfig, but I don't know how to specify a RequestConfig through the RDFConnection. What should I do? Our usage in the client app follows the "traditional" transactional pattern outlined in the Jena RDF API docs: http://jena.apache.org/documentation/rdfconnection/ try ( RDFConnection conn = RDFConnectionFactory.connect(...) ) { conn.begin(ReadWrite.WRITE) ; try { conn.load("data1.ttl") ; conn.load("data2.ttl") ; conn.querySelect("SELECT DISTINCT ?s { ?s ?p ?o }", (qs)-> Resource subject = qs.getResource("s") ; System.out.println("Subject: "+subject) ; }) ; conn.commit() ; } finally { conn.end() ; } } Thanks! Russell Morrisey Sr. Java Developer | Shared Services Team [email protected] cscglobal.com<http://www.cscglobal.com/> [cid:[email protected]] Ask us about our new brand reveal - coming this May. ________________________________ NOTICE: This e-mail and any attachments is intended only for use by the addressee(s) named herein and may contain legally privileged, proprietary or confidential information. If you are not the intended recipient of this e-mail, you are hereby notified that any dissemination, distribution or copying of this email, and any attachments thereto, is strictly prohibited. If you receive this email in error please immediately notify me via reply email or at (800) 927-9800 and permanently delete the original copy and any copy of any e-mail, and any printout.
