You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by "Timm, Sean" <ST...@mailgo.com> on 2000/04/13 00:45:55 UTC
Problem with Tomcat 3.1rc1
I'm having a problem with Tomcat 3.1rc1. I'm running JDK 1.2.2.
With the default distribution of Tomcat 3.1rc1, I add a Context that points
to another directory, and that directory contains a WEB-INF directory with a
web.xml file to describe the servlet information. That web.xml file
establishes my servlet (Cocoon in this case) as the default servlet for that
web application. When I try and access
http://localhost:8080/mycontext/whatever, I get a 404 error not found (and
it's not coming from my servlet...my servlet doesn't even get hit). It took
me a while to figure out how to fix this, but I found that if I edit the
server.xml in the tomcat/conf directory by removing the "default" servlet
(the first one listed), my servlet gets called like it is supposed to.
Am I doing something wrong, or is this a bug? I'm trying to fix up some
documentation on how to use Cocoon2 with Tomcat 3.1, but I'd prefer not to
have to throw into the documentation that you have to delete the "default"
servlet because it makes things not work. :)
Thanks,
Sean T.
Re: Problem with Tomcat 3.1rc1
Posted by Hans Bergsten <ha...@gefionsoftware.com>.
"Timm, Sean" wrote:
>
> I'm having a problem with Tomcat 3.1rc1. I'm running JDK 1.2.2.
>
> With the default distribution of Tomcat 3.1rc1, I add a Context that points
> to another directory, and that directory contains a WEB-INF directory with a
> web.xml file to describe the servlet information. That web.xml file
> establishes my servlet (Cocoon in this case) as the default servlet for that
> web application. When I try and access
> http://localhost:8080/mycontext/whatever, I get a 404 error not found (and
> it's not coming from my servlet...my servlet doesn't even get hit). It took
> me a while to figure out how to fix this, but I found that if I edit the
> server.xml in the tomcat/conf directory by removing the "default" servlet
> (the first one listed), my servlet gets called like it is supposed to.
>
> Am I doing something wrong, or is this a bug? I'm trying to fix up some
> documentation on how to use Cocoon2 with Tomcat 3.1, but I'd prefer not to
> have to throw into the documentation that you have to delete the "default"
> servlet because it makes things not work. :)
Ah, that's probably what I ran into a while ago when I was trying to
replace the default servlet in my own context without success.
To me it sounds like mappings in an application web.xml file don't override
the same mappings in Tomcat's default web.xml file. If that's the case,
it's a bug IMHO.
Hans
--
Hans Bergsten hans@gefionsoftware.com
Gefion Software http://www.gefionsoftware.com