Return-Path: Mailing-List: contact tomcat-dev-help@jakarta.apache.org; run by ezmlm Delivered-To: mailing list tomcat-dev@jakarta.apache.org Received: (qmail 22863 invoked from network); 4 Aug 2000 16:30:55 -0000 Received: from lukla.sun.com (192.18.98.31) by locus.apache.org with SMTP; 4 Aug 2000 16:30:55 -0000 Received: from gw.netbeans.com ([129.156.76.1]) by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id KAA27206 for ; Fri, 4 Aug 2000 10:30:48 -0600 (MDT) Received: from nbmailsrv.netbeans.com (mail.netbeans.com [212.24.138.130]) by gw.netbeans.com (8.9.3/8.9.3) with ESMTP id SAA16630 for ; Fri, 4 Aug 2000 18:30:43 +0200 Received: by mail.netbeans.com with Internet Mail Service (5.5.2448.0) id ; Fri, 4 Aug 2000 18:40:23 +0200 Message-ID: <10F82FC788E0D311AB820060083EAE1E081739@mail.netbeans.com> From: Petr Jiricka To: "'tomcat-dev@jakarta.apache.org'" Subject: RE: FW: two different versions of web.dtd and other issues Date: Fri, 4 Aug 2000 18:40:22 +0200 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2448.0) Content-Type: text/plain; charset="windows-1252" X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N > > I noticed that there are two different versions of web.dtd > all over Tomcat > > source/build/dist directories: one of size 16039 seems to > be included in > > Tomcat code, the other of size 15911 seems to be included in user > > directories. Can you please explain what's the difference > and what has > > changed ? > > I don't know why they are different. > > org/apache/tomcat/resources/web.dtd is read to validate > web.xml files. It has > no other role in tomcat configuration. > > conf/web.dtd is not used by tomcat - I haven't removed it > because maybe users > want to read it or use (possible) xml editors and they may > need the DTD. > It was supposed to be "constant" - i.e. the one defined in > the spec ( in > general DTDs are not supposed to change without a different > URI and version). > It seems this one is not so constant :-) Well, that happens, I guess. Servlet API classes are not so constant either (I remember a change just after the 3.1 release). I think I'll just use the version from org/apache/tomcat/resources/web.dtd. > > > > Another issue: I heard that conf/web.xml is not used now as > a default > > web.xml. What's the status of this file ? Is it *ever* used > ? Or is it > > something like "it is only used if ...." ? Either way, it > seems broken > > anyhow, as "org.apache.jasper.runtime.JspServlet" is out of > date, now it > > should be org.apache.jasper.servlet.JspServlet. Shouldn't > conf/web.xml be > > removed ? > > No, it is not used. The code was quite complex ( some properties were > overriden, some appened ). Until we have something we can > understand I think > it's better to leave it commented ( the code is still there). > Also, it is much > better to have only one config file - server.xml. Thanks, that's what I needed to know. Another - related - question: is the user *required* to have a web.xml for each web app, or is it optional ? I am assuming it is meant to be optional - see the bugfix I just commited. > > All configuration is done now in server.xml. Some of the > things from web.xml ( > mime types ) are now hardcoded ( but it is easy to enhance > server.xml to add > new defaults). > Jasper is hardcoded, but you can use the app. web.xml if you > want to change > it, and server.xml will also allow this. That's exactly what I wanted to do - replace the default JspServlet by our enhanced version. I don't want to modify web.xml for each web app, I want to somehow set it "globally" using server.xml. So I thought the solution would be to have a context interceptor which adds a ServletWrapper and mapping. Now, the default JspServlet is set by WebXMLInterceptor - is it possible to somehow override these settings ? Do I need to put my interceptor before of after WebXMLInterceptor ? Thanks Petr > > > > Costin > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org > For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org >