You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by li yanjing <li...@gmail.com> on 2005/05/08 06:18:17 UTC

confusion to DBCP

I'm using mysql + tomcat as server to run jsp pages.
and there are JavaBeans too.
I have read a lot on the web that using a connection pool is very good.
I just wondering why I should configure DBCP in tomcat?
i think if i write the database connection in jsp pages(not in beans)
I need configure DBCP in tomcat.
if in the page I just call some JavaBeans to connect to database, i
just need write a connection pool class in java.
is that true?
thanks

--

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


Re: confusion to DBCP

Posted by Gurumoorthy <g....@btinternet.com>.
Hi,
    Yes Connection pool is good because it gives a performance boost to your
application
        ( because open connection / close connection  is cpu and network
intensive )
    You dont have a to configure DBCP in tomcat. you can do that in your
application as well.
    You can configure DBCP in struts-config.xml if you are using struts :o)
     Why to re invent a wheel ( which may be buggy ) when there are loads
which are free and tested .. :o)
    Any other question feel free to ask ..

Regards
Guru

Guru on the Web : http://gurumoorthy.no-ip.org

----- Original Message -----
From: "li yanjing" <li...@gmail.com>
To: <to...@jakarta.apache.org>
Sent: Sunday, May 08, 2005 5:18 AM
Subject: confusion to DBCP


I'm using mysql + tomcat as server to run jsp pages.
and there are JavaBeans too.
I have read a lot on the web that using a connection pool is very good.
I just wondering why I should configure DBCP in tomcat?
i think if i write the database connection in jsp pages(not in beans)
I need configure DBCP in tomcat.
if in the page I just call some JavaBeans to connect to database, i
just need write a connection pool class in java.
is that true?
thanks

--

---------------------------------------------------------------------
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