I work on a project which (still) Jena SDB and have bundled up versions of 
Fuseki with SDB and a ReconnectingSDB library that someone posted here a long 
time ago that handles database connections timing out.  We’ve been using 
different versions of this configuration for several years.   I recently put 
together a Fuseki 2.0.0 version which has instruction on how to install it for 
both a standalone instance under Jetty or running under Tomcat.  If you can 
download from Dropbox you can get it here.

https://www.dropbox.com/s/vaqj4rjxlf6rjvi/vivo-fuseki-2.0.0.tar.gz?dl=0

From: Bangalore Akhilesh [mailto:[email protected]]
Sent: Tuesday, March 29, 2016 6:53 AM
To: [email protected]
Subject: Re: Fuseki with SDB - connection closed exception

Hi Andy,

Sorry for the formatting issues. I have attached the configuration and 
exception log files for your reference.

The database server did not restart and it is highly unlikely for the Fuseki 
server to be idle as we execute a suite of tests regularly on hourly basis.

Something which I missed in my previous e-mail is that we have deployed Fuseki 
on Tomcat 8.

Is there a way to enable connection pooling or modify the configuration to use 
a PoolDataSource etc?

Thanks,
Akhilesh

On Tue, Mar 29, 2016 at 3:05 PM, Andy Seaborne 
<[email protected]<mailto:[email protected]>> wrote:
On 29/03/16 09:33, Bangalore Akhilesh wrote:
Hi,

We have deployed fuseki with SDB against Oracle database. We have used
*jena-sdb-3.1.0-20160211.100203-49* with *apache-jena-fuseki-2.4.0-SNAPSHOT*
.

It worked fine for few days before we started to experience the SQL
connection closed problems. Can you please let me know why this is
happening? Am I missing anything in the configuration?

Below are my configuration and exception log.

*Configuration:*

This part has formatting problems:

@prefix : <# <http://example.com/#<http://example.com/>>> . @prefix fuseki: <
http://jena.apache.org/fuseki#<http://jena.apache.org/fuseki>> . @prefix rdf: <
http://www.w3.org/1999/02/22-rdf-syntax-ns#<http://www.w3.org/1999/02/22-rdf-syntax-ns>>
 . @prefix rdfs: <
http://www.w3.org/2000/01/rdf-schema#<http://www.w3.org/2000/01/rdf-schema>> . 
@prefix sdb: <
http://jena.hpl.hp.com/2007/sdb#<http://jena.hpl.hp.com/2007/sdb>> . @prefix 
ja: <
http://jena.hpl.hp.com/2005/11/Assembler#<http://jena.hpl.hp.com/2005/11/Assembler>>
 . :service_sdb_all a fuseki:
Service ; rdfs:label "SDB - Oracle" ; fuseki:name "oracle" ; fuseki:
serviceQuery "query", "sparql" ; fuseki:serviceUpdate "update" ; fuseki:
serviceUpload "upload" ; fuseki:serviceReadWriteGraphStore "data" ; fuseki:
serviceReadGraphStore "get" ; fuseki:dataset :sdb_dataset_readwrite ; . :
sdb_dataset_readwrite a sdb:DatasetStore ; sdb:store :rdbms_datastore . :
rdbms_datastore a sdb:Store ; sdb:layout "layout2" ; sdb:connection :
fuseki_data_conn ; . :fuseki_data_conn a sdb:SDBConnection ; sdb:sdbType "
oracle" ; sdb:driver "oracle.jdbc.driver.OracleDriver" ; sdb:jdbcURL "
jdbc:oracle:thin:@localhost:1521/xe" ; sdb:sdbUser "myuser" ; sdb:
sdbPassword "password" ; .

*Exception log:*

[2016-03-28 20:45:46] Fuseki     INFO  [305964] 500 SQLException in
executing SQL statement (1 ms)
[2016-03-28 20:45:46] Fuseki     INFO  [305965] GET
http://localhost:8080/fuseki/oracle/query?query=SELECT%20%3Fs%20%3Fp%20%3Fo%0D%0AWHERE%0D%0A%7B%0D%0A%20%20GRAPH%20%3Curn%3Amydepts%3Aplatforms%3Acustomers%3ATestCompany1%3E%20%7B%20%3Fs%20%3Fp%20%3Fo%20.%20%7D%0D%0A%7D%0D%0A
[2016-03-28 20:45:46] Fuseki     INFO  [305965] GET /oracle :: 'query' ::
<none> ?
query=SELECT%20%3Fs%20%3Fp%20%3Fo%0D%0AWHERE%0D%0A%7B%0D%0A%20%20GRAPH%20%3Curn%3Amydepts%3Aplatforms%3Acustomers%3ATestCompany1%3E%20%7B%20%3Fs%20%3Fp%20%3Fo%20.%20%7D%0D%0A%7D%0D%0A
[2016-03-28 20:45:46] Fuseki     INFO  [305965] Query = SELECT ?s ?p ?o
  WHERE  {    GRAPH <urn:mydepts:platforms:customers:TestCompany1> { ?s ?p
?o . }  }
*[2016-03-28 20:45:46] SDBConnection WARN  execQuery: SQLException*
*Closed Connection*

It is not clear to me what's going on.

Did the database server restart?

Was the Fuseki server idle for a significant period of time prior to the 500's 
starting?

        Andy

Reply via email to