You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Mark Thill <ma...@yahoo.com> on 2002/07/12 16:31:17 UTC

context in server.xml doesn't reload

I'm running tomcat 4.0.3 and I have created a context
path in my server.xml file which looks something like
this:

<Context path="/foo" docBase="C:\some\path" debug="0">
    <Resource name="JDBC/SEC_POOLCONN"
auth="Container"
type="javax.sql.ConnectionPoolDataSource"/>
    <ResourceParams name="JDBC/SEC_POOLCONN">

<parameter><name>user</name><value>username</value></parameter>
<parameter><name>password</name><value>passwod</value></parameter>
<parameter><name>driverClassName</name><value>com.sybase.jdbc2.jdbc.SybDriver</value></parameter>
<parameter><name>driverName</name><value>jdbc:sybase:Tds:192.168.1.10:5010</value></parameter>
<parameter><name>initialPoolSize</name><value>3</value></parameter>
</ResourceParams>
</context>

I start up tomcat and the context is created (/foo)
Everything seems to work fine when I load the
application and run it the first time.  Then, 
through the manager application I go and remove the
context /foo (because maybe I want to load a new
foo.war file that I've added some fixes to) and 
then install the new foo.war file using the 
manager/install?path=/foo&war=jar:file:C:\java\jakarta-tomcat-4.0.3\webapps\foo.war!/

command which says it is successful.  When I return to
the application, the 
first attempt to try to get an connection from the
pool gives a 
NullPointerException because the pool seems to be gone
or not reloaded.  I'm guessing that since I've
declared the resource in the server.xml file it won't
reload it when I reinstall the war file.  Does anyone
have any suggestions of how I might get around this
problem?  The only solution so far is to resart
Tomcat, but this is not ideal since we don't want all
the applications going down because of a change to a
single application.

Thanks in advance
Mark

__________________________________________________
Do You Yahoo!?
Sign up for SBC Yahoo! Dial - First Month Free
http://sbc.yahoo.com

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>