Open m-khl opened 10 years ago
If executeQuery is successful, it will return an MDDataSet. That needs to have a valid CellSet object inside it, and if executeQuery() were to close the connection, it would make the CellSet invalid. MDDataSet.close() closes the connection.
So, make sure that MDDataSet.close() is being called.
Julian
@julianhyde thanks for your answer.
MDDataSet.close() is call fine and connection from the driver is closed successfully, but not the pooled connection obtained at Olap4jPoolingConnectionFactory.getConnection(), cellset just has no reference to it. How it can be released back to the pool?
You may have found a bug. I can't be sure, but please log one to we can track.
Maybe the the proxy returned by Olap4jPoolingConnectionFactory.createDelegatingOlapConnection()
should forward the close
call to the DBCP connection. Or maybe the call to executeOlapQuery
should generate a wrapper that closes the CellSet but does any necessary DBCP housekeeping, including calling the DBCP connection. I can't be sure unless I run this in a debugger.
@julianhyde I'm not sure what you mean in "please log one to we can track", I tried to raise an issue at Pentaho jira, but did find xmlaserver project. please check #10 it bypasses MDDataSet.close() and hits the pool straight, it's how I've got your point. It might not be ideal way to fix, but my tests pass fine so far.
Apologies; I was reading/replying via email, so I'd forgotten that we were in a github issue already. (This one!)
hello, Thanks for your project. I'm experimenting with the own olap4j driver impl.
if(!success)
onlythat closes connection from underlying driver, but not the dbcp connection wrapper, that leaks it.
WDYT? How we can to elaborate this issue? So far, I'll try to nuke the connection pooling.