You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-dev@jakarta.apache.org by Chris Kimpton <ki...@yahoo.com> on 2001/12/20 12:39:47 UTC

JDBCContentStore.retrieveRevisionContent - not closing connections?

Hi,

I am using an Oracle backed JDBCContentStore with slide 1.0.16.

Everytime we download a document - eg through the webapp.

A new cursor is being opened - but this never seems to be being
released.
We found this out because we hit the "ORA-01000 maximum open cursors
exceeded" error from oracle.
I am guessing that the above class/method is the likely candidate -
as it seems to be the method that gets the content.  It also does not
seem to release the prepared statement it creates.
Looking at it, I presume we cannot just close it in the method - as
the input stream for the binary object won't have been read at that
point.
So - should it read the whole object in and then close the connection
here?
Or should some finaliser code in the NodeRevisionContent object close
the connection? Although this option does not sound right...


Comments - I will probably go for the first option in my code - let
me know if you want the patch?

Regards,
Chris

=====
Need somewhere to Live in London? - Then go to http://freeflats.com

__________________________________________________
Do You Yahoo!?
Check out Yahoo! Shopping and Yahoo! Auctions for all of
your unique holiday gifts! Buy at http://shopping.yahoo.com
or bid at http://auctions.yahoo.com

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: JDBCContentStore.retrieveRevisionContent - not closing connections?

Posted by Chris Kimpton <ki...@yahoo.com>.
Hi,

> Your patch for bug 5582 will be committed in a few minutes, 

Thanks.


> Reading the content into memory or a local tmp file was also a good
> option.
> (You might want to implement this if you have a lot of slow
> clients)
> 

Performance is phase 2 - as usual -  ;-)

Regards,
Chris

=====
Need somewhere to Live in London? - Then go to http://freeflats.com

__________________________________________________
Do You Yahoo!?
Send your FREE holiday greetings online!
http://greetings.yahoo.com

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: JDBCContentStore.retrieveRevisionContent - not closing connections?

Posted by Dirk Verbeeck <di...@pandora.be>.
Hi Chris

Your patch for bug 5582 will be committed in a few minutes, it a nice
solution for this problem.
Reading the content into memory or a local tmp file was also a good
option.
(You might want to implement this if you have a lot of slow clients)

Thanks for the patch
Dirk


Chris Kimpton wrote:
> 
> Hi,
> 
> I am using an Oracle backed JDBCContentStore with slide 1.0.16.
> 
> Everytime we download a document - eg through the webapp.
> 
> A new cursor is being opened - but this never seems to be being
> released.
> We found this out because we hit the "ORA-01000 maximum open cursors
> exceeded" error from oracle.
> I am guessing that the above class/method is the likely candidate -
> as it seems to be the method that gets the content.  It also does not
> seem to release the prepared statement it creates.
> Looking at it, I presume we cannot just close it in the method - as
> the input stream for the binary object won't have been read at that
> point.
> So - should it read the whole object in and then close the connection
> here?
> Or should some finaliser code in the NodeRevisionContent object close
> the connection? Although this option does not sound right...
> 
> Comments - I will probably go for the first option in my code - let
> me know if you want the patch?
> 
> Regards,
> Chris
> 
> =====
> Need somewhere to Live in London? - Then go to http://freeflats.com
> 
> __________________________________________________
> Do You Yahoo!?
> Check out Yahoo! Shopping and Yahoo! Auctions for all of
> your unique holiday gifts! Buy at http://shopping.yahoo.com
> or bid at http://auctions.yahoo.com
> 
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>