tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jacob Kjome <h...@visi.com>
Subject Re: Connection pooling using Jakarta commons
Date Wed, 14 Aug 2002 16:12:05 GMT
Tomcat-4.1.x has solved this for you because it supports context 
configuration files (CCF).   CCF's consist of the <Context ...> element 
that you would normally put in the server.xml.  Just put your app and the 
CCF with the <Context ...> element defining your application in the webapps 
directory and you are off and running.  No need to modify the server.xml.

For examples, look at the admin.xml and manager.xml Tomcat's webapps directory.

Of course, if your hosting company is running Tomcat-4.0.x, you are out of 
luck for this solution.  Tell them to upgrade to Tomcat-4.1.8.  It is of 
very good quality and makes configuration a breeze!

Jake

At 11:47 AM 8/14/2002 +0100, you wrote:
>Hi,
>
>I'm new here. My name's Mel. Hi!
>
>Anyway, I have a question that I cannot find an answer for anywhere.
>I've implemented connection pooling using Tomcat 4.0 and the required 
>projects from Jakarta commons as instructed in the JNDI resources how to 
>that can be found with in the Tomcat documentation. 
>(http://jakarta.apache.org/tomcat/tomcat-4.0-doc/jndi-resources-howto.html)
>I have edited my server.xml and web.xml files and it works perfectly. How 
>comes the time for my project to be transferred onto the new web hosting 
>companys web site. This is where I have hit a problem. I cannot edit their 
>server.xml. Only my own web.xml. So i've added the <resource-ref> element 
>to web.xml:
>
><resource-ref>
>     <res-ref-name>jdbc/ocb_clients</res-ref-name>
>     <res-type>javax.sql.DataSource</res-type>
>     <res-auth>Container</res-auth>
></resource-ref>
>
>However, server.xml contains many parameters:
>
><ResourceParams name="jdbc/ocb_clients">
>     <parameter>
>       <name>factory</name>
>       <value>org.apache.commons.dbcp.BasicDataSourceFactory</value>
>     </parameter>
>     <parameter>
>      <name>username</name>
>      <value>username here</value>
>     </parameter>
>     <parameter>
>      <name>password</name>
>      <value>password_here</value>
>     </parameter>
>     <parameter>
>        <name>driverClassName</name>
>        <value>org.gjt.mm.mysql.Driver</value>
>     </parameter>
>     <parameter>
>       <name>url</name>
>       <value>jdbc:mysql://localhost:3306/ocb_clients</value>
>     </parameter>
></ResourceParams>
>
>Can these be included in web.xml somehow? Or do I need to take a different 
>approach?
>Thanks very much for any help,
>Mel.
>
>
>
>
>--
>To unsubscribe, e-mail:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
>For additional commands, e-mail: <mailto:tomcat-user-help@jakarta.apache.org>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message