Timothy Carroll wrote: <snip>
If anyone has any advise on where to look or what to look for, it would be greatly appreciated. I hate to call people out, but I did see Mr. Petro's name on some of the DBCPDataSourceFactory code comments. I hope he has a notion to comment (Andrew?), because I may have some additional questions on that piece of the puzzle as well.
We had had this problem too in Java-code. In our case it looked like this:
1. We created a Connection object that wasn't closed, to save on
overhead in creating the connection.
2. On that connection, we created Statement and PreparedStatement, that
wasn't closed after use but wasn't reused next time.
Those still open Statement objects keeps a cursor open in the database.
How do you fix something like this? There are (at least) 2 strategies
that I recommend implementing both of:
1. Use a Connection pool, get your connection from the pool, close the
connection when you're done. A good pool will close the statements for you.
2. Find all uses of Statement et.al, and ensure they are closed in a
finally block; try { statement.close(); } catch (Exception ignore) {}
Thanks a bunch everybody... Tim
///regards, -- | _/ _/_/_/ _/ _/ _/_/_/ | Jens Carlberg | _/ _/ _/_/ _/ _/ | UNIT, Linköpings universitet | _/ _/_/ _/ _/_/ _/ | Tel: +46 13 281758 | _/_/ _/_/_/ _/ _/ _/_/_/ | Fax: +46 13 284400
smime.p7s
Description: S/MIME Cryptographic Signature
