Priyaranjan created JENA-307:
--------------------------------
Summary: QueryExecution is not being closed in
SPARQL_Query.execute method.
Key: JENA-307
URL: https://issues.apache.org/jira/browse/JENA-307
Project: Apache Jena
Issue Type: Question
Components: Fuseki
Affects Versions: Fuseki 0.2.4
Reporter: Priyaranjan
QueryExecution is not being closed in SPARQL_Query.execute method.
In the execute method , after sending the results , only the dataset.end()
method is called to end the transation. But the QueryExecution that
was created is never closed.
This is in contrary to the examples provided at
http://jena.apache.org/documentation/tdb/tdb_transactions.html for Read
Transcations ,
where the qExec.close is called before calling dataset.end
Location location = ... ;
Dataset dataset = ... ;
dataset.begin(ReadWrite.READ) ;
try {
QueryExecution qExec = QueryExecutionFactory.create("SELECT * {?s ?p ?o}
LIMIT 10", dataset) ;
ResultSet rs = qExec.execSelect() ;
try {
ResultSetFormatter.out(rs) ;
} finally { qExec.close() ; }
// Another query - same view of the data.
qExec = QueryExecutionFactory.create("SELECT * {?s ?p ?o} OFFSET 10 LIMIT
10", dataset) ;
rs = qExec.execSelect() ;
try {
ResultSetFormatter.out(rs) ;
} finally { qExec.close() ; }
} finally { dataset.end() ; }
Is this a bug in Fuseki ?
In my application , I am creating a database connection , when the
QueryExecution is created , and I need to close the connection when
the QueryExecution is closed.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira