You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by "Durfee, Bernard" <Be...@suny.edu> on 2005/01/20 16:48:17 UTC

Major bug in deployer!!

I am trying to use the Tomcat manager to deploy a web application packed
in a WAR file. In my WAR file I have a directory named 'META-INF' and in
that directory I have a file named 'context.xml'. The 'context.xml' file
looks like...

<?xml version="1.0" encoding="UTF-8"?>
<Context path="/servlet/myservlet" reloadable="true">
    ...
</Context>

...so I am telling Tomcat to send all URLs ending with
'/servlet/myservlet' to the web application being deployed. I do a
browse, point to the WAR file and then press 'Deploy'. Tomcat then
copies the WAR file to '/webapps' and copies the 'context.xml' file to
'conf/.../myservlet.xml'.

So far so good.

Now when I go to the manager listing the web applications I see
'/myservlet' in the 'Applications' column. Uh oh! Seems that the 'path'
attribute in the 'context.xml' file is being completely ignored! So
right now I am forced to put the <Context> element in the 'server.xml'
file directly, in which Tomcat respects the 'path' attribute.

So my question is... Is there a workaround for this problem that will
allow me to deploy my web application using the deployer when my web
application context path needs to be '/servlet/myservlet'? Yes, the
context NEEDS to be '/servlet/myservlet'!

I have tried this in 5.5.4, 5.5.6 and 5.5.7 with the same results. The
deployer would make life on our network admin MUCH easier because I
would be able to deploy new versions of the web application without
bugging him to install them manually. Thanks in advance!!

Bernard Durfee

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


Re: Major bug in deployer!!

Posted by Parsons Technical Services <pa...@earthlink.net>.
This is the default action of the 5.5 path and is noted on the context 
documentation. The way to fix this is to name the context.xml as 
servlet#myservlet.xml

Doug


----- Original Message ----- 
From: "Durfee, Bernard" <Be...@suny.edu>
To: "Tomcat Users List" <to...@jakarta.apache.org>
Sent: Thursday, January 20, 2005 10:48 AM
Subject: Major bug in deployer!!


I am trying to use the Tomcat manager to deploy a web application packed
in a WAR file. In my WAR file I have a directory named 'META-INF' and in
that directory I have a file named 'context.xml'. The 'context.xml' file
looks like...

<?xml version="1.0" encoding="UTF-8"?>
<Context path="/servlet/myservlet" reloadable="true">
    ...
</Context>

...so I am telling Tomcat to send all URLs ending with
'/servlet/myservlet' to the web application being deployed. I do a
browse, point to the WAR file and then press 'Deploy'. Tomcat then
copies the WAR file to '/webapps' and copies the 'context.xml' file to
'conf/.../myservlet.xml'.

So far so good.

Now when I go to the manager listing the web applications I see
'/myservlet' in the 'Applications' column. Uh oh! Seems that the 'path'
attribute in the 'context.xml' file is being completely ignored! So
right now I am forced to put the <Context> element in the 'server.xml'
file directly, in which Tomcat respects the 'path' attribute.

So my question is... Is there a workaround for this problem that will
allow me to deploy my web application using the deployer when my web
application context path needs to be '/servlet/myservlet'? Yes, the
context NEEDS to be '/servlet/myservlet'!

I have tried this in 5.5.4, 5.5.6 and 5.5.7 with the same results. The
deployer would make life on our network admin MUCH easier because I
would be able to deploy new versions of the web application without
bugging him to install them manually. Thanks in advance!!

Bernard Durfee

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