For more information, here is STDOUT :

Starting tomcat. Check logs/tomcat.log for error messages
No apps in webapps/
cannot load servlet name: jsp
cannot load servlet name: default

...and here is STDERR :

2001-04-23 03:20:05 - ContextManager: Adding context Ctx(  )
2001-04-23 03:20:05 - Ctx(  ): Removing duplicate servlet jsp
jsp(org.apache.jasper.runtime.JspServlet/null)
2001-04-23 03:20:05 - Ctx(  ): Removing duplicate *.jsp ->
jsp(org.apache.jasper.servlet.JspServlet/null)
2001-04-23 03:20:05 - PoolTcpConnector: Starting Ajp12ConnectionHandler on
8007
2001-04-23 03:20:05 - PoolTcpConnector: Starting Ajp13ConnectionHandler on
8009

No "tomcat.log" file was generated.  I have no webapps in the "webapps"
folder, I just use one context which maps to "/".

Does having the same mapping in <tomcat_home>/conf/web.xml and any other
"web.xml" cause the mapping to be discarded altogether?  This seems to be
what is happening here, but I don't understand WHY!

I thought that by providing a servlet mapping (JSP or any other) in web.xml
just overrode the default settings within the particular webapp ; as such, I
would have expected that copying the default web.xml would be harmless
(indeed, very useful in some cases, in order to provide different JSP
behaviour for different webapps under the same server..!).

Please explain !

Many thanks,
Chris




----- Original Message -----
From: "chris brown" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, April 23, 2001 3:12 PM
Subject: Basic question about web.xml


> I'm trying to create my own web.xml file for use in Tomcat.  I've read the
> doc, but I need help to understand what's going on exactly...
>
> I created a new document folder, and added the context mapping in
> server.xml.  I put a simple HTML file and a simple JSP file in the folder,
> and started up Tomcat.  The JSP compiled fine, and both it and the HTML
file
> displayed as intended in the navigator.
>
> I then copied the standard web.xml file from tomcat/conf into my new
> folder... but after restarting Tomcat, I got "HTTP 404 Not Found" errors
for
> the JSP only (although the JSP *does* appear in the directory listing).
If
> I rename "web.xml" as "_web.xml" (and restart Tomcat), no more problem
(but
> obviously, I can no longer configure the web app!), or if I comment out
all
> the default servlet mappings, it runs fine too.
>
> What is the problem?  As I say, I'm using nothing but copies of the
standard
> files, and none of the possible causes of an HTTP 404 error given in
> Tomcat's documentation correspond to my case.  Incidentally, I'm using
> Tomcat 3.1 on top of JDK1.3 on Windows NT4.
>
> Thanks in advance,
> Chris Brown
>
>
===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
> For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
>  http://java.sun.com/products/jsp/faq.html
>  http://www.esperanto.org.nz/jsp/jspfaq.html
>  http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
>  http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to