Hi John,

Please, do not edit the server.xml. You have to place all that stuff in
the context.xml inside the META-INF folder of your project.

I'm using Tomcat 5.0 and I can't see any META-INF folder, only a WEB-INF
folder, where should META-INF be?

I take it all I need to do is copy what I put in to server.xml to a
myapp.xml file under /conf/Catalina/localhost/ ?


Thanks for letting me know about this.

Graeme :)

From: John Cherouvim <[EMAIL PROTECTED]>
Reply-To: A mailing list about Java Server Pages specification and
reference <JSP-INTEREST@JAVA.SUN.COM>
To: JSP-INTEREST@JAVA.SUN.COM
Subject: Re: DB Connection prob (next step)
Date: Wed, 21 Mar 2007 09:40:25 +0200
MIME-Version: 1.0
Received: from swjscmail2.java.sun.com ([192.18.99.108]) by
bay0-mc11-f3.bay0.hotmail.com with Microsoft SMTPSVC(6.0.3790.2668); Wed,
21 Mar 2007 00:50:49 -0700
Received: from swjscmail1 (swjscmail1.Sun.COM [192.18.99.107])by
swjscmail2.java.sun.com (Postfix) with ESMTPid 66A3421F9D; Wed, 21 Mar 2007
01:47:24 -0600 (MDT)
Received: from JAVA.SUN.COM by JAVA.SUN.COM (LISTSERV-TCP/IP release 1.8e)
with          spool id 14194858 for JSP-INTEREST@JAVA.SUN.COM; Wed, 21 Mar
2007          01:44:38 -0600
Received: from deliver.hol.gr (unknown [62.38.3.162]) by
swjscmail1.java.sun.com (Postfix) with ESMTP id 766635030 for
<JSP-INTEREST@JAVA.SUN.COM>; Wed, 21 Mar 2007 01:34:33 -0600 (MDT)
Received: from auth-smtp.hol.gr (takeit01.mail.dc.hol.net [192.168.20.71])
by          deliver.hol.gr (8.12.11/8.11.6) with ESMTP id l2L7eOXj028163
(using          TLSv1/SSLv3 with cipher DHE-RSA-AES256-SHA (256 bits)
verified OK)          for <JSP-INTEREST@JAVA.SUN.COM>; Wed, 21 Mar 2007
09:40:24 +0200
Received: from [192.168.0.35] (static216015.dsl.hol.gr [62.38.216.16]) by
       auth-smtp.hol.gr (8.13.1/8.12.11) with ESMTP id l2L7eQg8013149 for
        <JSP-INTEREST@JAVA.SUN.COM>; Wed, 21 Mar 2007 09:40:26 +0200
X-Message-Info:
txF49lGdW42p6AeET3jeIzQl1RfOcDqrZwaY4xWXPyUcjtUlMF6K099scHMKW7x1
X-Original-To: JSP-INTEREST@JAVA.SUN.COM
Delivered-To: JSP-INTEREST@JAVA.SUN.COM
User-Agent: Thunderbird 1.5.0.10 (Windows/20070221)
References: <[EMAIL PROTECTED]>
X-Virus-Scanned: ClamAV 0.90/2889/Wed Mar 21 07:20:03 2007 on
  takeit01.mail.dc.hol.net
X-Virus-Status: Clean
Precedence: list
Return-Path: [EMAIL PROTECTED]
X-OriginalArrivalTime: 21 Mar 2007 07:50:50.0228 (UTC)
FILETIME=[A4C4F340:01C76B8D]

Please, do not edit the server.xml. You have to place all that stuff in
the context.xml inside the META-INF folder of your project. When the
application is deployed this will be copied under
conf/Catalina/localhost/myapp.xml, or under
conf/Catalina/myapp.org/ROOT.xml. Note that these locations are tomcat
specific, but all containers would do something similar.

The only reason I can think of that would justify connection pooling
descriptors on the server.xml would be if you wanted two or more
applications (contexes) to be able to share the same connection pool.

john

Graeme McLaren wrote:
Hi all, I'm trying to get connection pooling working, I've altered the
server.xml and web.xml files, written a class and it compiled with a few
errors.  What am I doing wrong here?

Cheers,

Graeme :)

in server.xml:

       <Context path="/dbcp" docBase="dbcp" debug="5"
 reloadable="true" crossContext="true">

 <Resource name="jdbc/TestDB" auth="Container"
    type="javax.sql.DataSource" removeAbandoned="true"
    removeAbandonedTimeout="30" maxActive="100"
    maxIdle="30" maxWait="10000" username="myUsername"
    password="myPassword"
    driverClassName="oracle.jdbc.driver.OracleDriver"
    url="WorkingDBUrl"/>
   </Context>


     <!--  Configuring the request and response endpoints -->
     <Connector port="80" maxHttpHeaderSize="8192" maxProcessors="150"
        maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
        enableLookups="false" redirectPort="8443" acceptCount="150"
  connectionTimeout="20000" disableUploadTimeout="true" />



===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".

Some relevant archives, FAQs and Forums on JSPs can be found at:

http://java.sun.com/products/jsp
http://archives.java.sun.com/jsp-interest.html
http://forums.java.sun.com
http://www.jspinsider.com

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".

Some relevant archives, FAQs and Forums on JSPs can be found at:

http://java.sun.com/products/jsp
http://archives.java.sun.com/jsp-interest.html
http://forums.java.sun.com
http://www.jspinsider.com

Reply via email to