5 Replies Latest reply on Jul 17, 2003 5:17 AM by kar2000

    Connection Pool exhaust

    jeffzeng

      In my currenct project,I use JBoss 2.2.2 and Tomcat 3.2.3.Now I find I can't release database connection obtained from JBoss connection pool although I invoke con.close().My app blocks on waiting for idle db connection after some time.
      I check my code and found that when I directly invoke entity bean's method everything is ok,but when I do some complex query via session bean,the connection pool will be exhausted fast and whole system hangs up.
      I use :
      try{
      ...
      }catch(Exception e){
      }finally{
      try{
      if(stmt != null){
      stmt.close();
      }
      }catch(Exception ee){}
      try{
      if(con != null){
      con.close();
      }
      }catch(Exception ee){}
      }
      Can you tell me how can I avoid this condition ?