You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2008/09/30 09:39:00 UTC
DO NOT REPLY [Bug 45913] New: removeAbandoned configuration not
working.
https://issues.apache.org/bugzilla/show_bug.cgi?id=45913
Summary: removeAbandoned configuration not working.
Product: Tomcat 5
Version: 5.5.12
Platform: PC
OS/Version: Windows XP
Status: NEW
Severity: normal
Priority: P2
Component: Catalina
AssignedTo: dev@tomcat.apache.org
ReportedBy: svkirans@gmail.com
Hi,
Iam using tomcat connection pooling to maintain db connections.
The following configurations were made in context.xml.
<Resource name="jdbc/testdb" auth="Container"
type="javax.sql.DataSource"
username="root" password="root123"
driverClassName="com.mysql.jdbc.Driver"
url="jdbc:mysql://localhost:3306/test35_dev"
maxActive="-1"
maxIdle="10"
minIdle="6"
maxwait="5000"
minEvictableIdleTimeMillis="30000"
numTestsPerEvictionRun = "25"
timeBetweenEvictionRunsMillis="30000"
removeAbandoned="true"
removeAbandonedTimeout="60"
/>
I used the following code to look up and get the data base connections
Context initCtx = new InitialContext();
Context envCtx = (Context) initCtx.lookup("java:comp/env");
// Look up our data source
DataSource ds = (DataSource) envCtx.lookup("jdbc/testdb");
// Allocate and use a connection from the pool
Connection connection = ds.getConnection();
After this the application is creating 50 connections and it is not closing
the connections after using.Will removeAbandoned step in and return the
connections to the pool and remove the excess connections greater than maxIdle
parameter.But when the application needs the next set of connections it is
creating new connections instead of using the existing ones and as a result the
MySql server is running out of connections.Why is removeAbandoned not handling
the unclosed connections even after 1 minute even though it is configured to do
so.
Thanks
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
DO NOT REPLY [Bug 45913] removeAbandoned configuration not working.
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=45913
svkirans <sv...@gmail.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |svkirans@gmail.com
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org
DO NOT REPLY [Bug 45913] removeAbandoned configuration not working.
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=45913
Mark Thomas <ma...@apache.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |INVALID
--- Comment #1 from Mark Thomas <ma...@apache.org> 2008-10-01 07:57:08 PST ---
This is a question for the users list.
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org