tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kausik Dey" <k_...@hotmail.com>
Subject Re: Tomcat 5.0.16 DBCP Connection Pool Exhausted Error
Date Tue, 16 Dec 2003 01:50:26 GMT
Hi,
I am getting right away. Below the code structure where I am getting.
   try{
      Context ctx = new InitialContext();
      if(ctx == null )
          throw new Exception("No Context found");

      DataSource ds =
(DataSource)ctx.lookup("java:comp/env/jdbc/informixDB");

      if (ds != null) {
        Connection conn = ds.getConnection();
------------------   Here its going to catch section with "connection pool
exhausted error". --------------------------
-
-
Thanks

KD
----- Original Message ----- 
From: "Kwok Peng Tuck" <pengtuck@makmal.net>
To: "Tomcat Users List" <tomcat-user@jakarta.apache.org>
Sent: Monday, December 15, 2003 8:44 PM
Subject: Re: Tomcat 5.0.16 DBCP Connection Pool Exhausted Error


> Isn't removeAbandoned deprecated ? If so is it still usable ?
>
>
> >
> > Hmm... are you getting the error right away or only after a few
requests?
> >
> > Hard to say anything without further information. It is always a good
> > idea to make sure you properly close all Statements, ResultSets anc
> > Connections obtained from the pool.
> > If you ae using commons dbcp, you could also add
> >
> > <parameter><name>logAbandoned</name><value>true</value></parameter>
> > <parameter><name>removeAbandoned</name><value>true</value></parameter>
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message