hi:
I am new in using
JDBC, but I think I have good understanding of how to create an destroy a connection using a connection pool and datasource.
Here is my situation:
The Database admin accusing me of not writing good code. He says that my code leaves database connections open. I close all my connections proporly in a finally clause. I ran a simulator accessing the database and excuting a SQL statement. I ran the simulatore on
Tomcat accessing SQL server 2k. The simulator run in 5 windows, 5 users, with 10000 connections per user. Total of 50000 times of opening, excuting a query, and then closing a connection.
After the simulation stoped, and after the connection idle time out past, he could see from his side that there are about 3 or 4 connections open. The minimum number of connection on the server is 2. He is telling me that there are 1 or 2 connections are not closed.
I know there is nothing wrong with the code. Is it normal that some connection will still open? How can I answer his demands for closing all the connections?
I really appreciate any help.