You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by "Proetel, Ingo" <ip...@SELECTICA.com> on 2000/10/07 00:52:50 UTC

Tomcat 4 problems (with JDK1.3 and some dtd)

Hi,

I just tried to use Tomcat 4 but I ran into two problems:

1. I'm using it on jdk1.3 and it kept complaining that it did not find
sun.tools.javac.Main. I found out that sun renamed the package to
com.sun.tools.javac.Main.
Is there a better way to fix this than just putting a jdk1.2.2 tools.jar
into the classpath ?

2. While parsing some xml files (actually one of the web.xml files that come
with tomcat) it says that it can not find
http://java.sun.com/j2ee/dtds/web-app_2_3.dtd. I confirmed this and found
that http://java.sun.com/j2ee/dtds/web-app_2.2.dtd exists. Is it save to
change this link in the web.xml paths ?

Thanks
ingo

Re: Tomcat 4 problems (with JDK1.3 and some dtd)

Posted by "Craig R. McClanahan" <Cr...@eng.sun.com>.
"Proetel, Ingo" wrote:

> Hi,
>
> I just tried to use Tomcat 4 but I ran into two problems:
>
> 1. I'm using it on jdk1.3 and it kept complaining that it did not find
> sun.tools.javac.Main. I found out that sun renamed the package to
> com.sun.tools.javac.Main.
> Is there a better way to fix this than just putting a jdk1.2.2 tools.jar
> into the classpath ?
>

In my two 1.3 environments (Linux with the 1.3 FCS release, and Windows98), the
Tomcat 4.0 milestone 1 release worked out of the box -- including being able to
compile and run JSP pages.  Looking inside the tools.jar file, I see that
"sun.tools.javac.Main" still exists.

What platform (OS and JDK) are you running?

>
> 2. While parsing some xml files (actually one of the web.xml files that come
> with tomcat) it says that it can not find
> http://java.sun.com/j2ee/dtds/web-app_2_3.dtd. I confirmed this and found
> that http://java.sun.com/j2ee/dtds/web-app_2.2.dtd exists. Is it save to
> change this link in the web.xml paths ?
>

This is very strange.

Tomcat 4.0 includes an internal copy of the 2.3 DTD, which is registered with
the parser so that it doesn't try to go out to the network (the official 2.3 DTD
won't be published until the spec goes final).  All of the webapps that ship
with 4.0-m1 use the correct DTD public identifiers, so the local copy should be
used.  And it does so, out of the box, on my two 1.3 environments.

In general, it is not safe to switch back to the 2.2 feature if you are using
any of the new 2.3 features like filters or application event listeners (as does
the "examples" webapp in 4.0-m1).

Did you change anything about the standard startup scripts?  Is there anything
in your $JAVA_HOME/jre/lib/ext directory that might mess up the XML parser being
used (Xerces is included with Tomcat 4.0-m1 and it's required at the moment).?

What we need to do is figure out what is different about your environment that
affects the operation of Tomcat.

>
> Thanks
> ingo

Craig

====================
See you at ApacheCon Europe <http://www.apachecon.com>!
Session VS01 (23-Oct 13h00-17h00):  Sun Technical Briefing
Session T06  (24-Oct 14h00-15h00):  Migrating Apache JServ
                                    Applications to Tomcat



Re: Tomcat 4 problems (with JDK1.3 and some dtd)

Posted by kenneth topp <ca...@prodigy.net>.
On Fri, 6 Oct 2000, Proetel, Ingo wrote:

> Hi,
> 
> I just tried to use Tomcat 4 but I ran into two problems:
> 
> 1. I'm using it on jdk1.3 and it kept complaining that it did not find
> sun.tools.javac.Main. I found out that sun renamed the package to
> com.sun.tools.javac.Main.
> Is there a better way to fix this than just putting a jdk1.2.2 tools.jar
> into the classpath ?

checking two 1.3.0 jdk's for linux show sun.tools.javac.Main.. Perhaps
your classpath is being reset somewhere?
 
$ unzip -l /opt/jdk/Sun-1.3.0FCS/lib/tools.jar | grep javac | grep Main
    13088  09-18-00 18:12   sun/tools/javac/Main.class
      533  09-18-00 18:14   com/sun/tools/javac/Main.class
     7571  09-18-00 18:14   com/sun/tools/javac/v8/Main.class

$ unzip -l /opt/jdk/IBM-1.3.0/lib/tools.jar | grep javac | grep Main
    13437  08-15-00 02:31   sun/tools/javac/Main.class
     7620  08-15-00 02:31   com/sun/tools/javac/v8/Main.class
      533  08-15-00 02:31   com/sun/tools/javac/Main.class



> 2. While parsing some xml files (actually one of the web.xml files that come
> with tomcat) it says that it can not find
> http://java.sun.com/j2ee/dtds/web-app_2_3.dtd. I confirmed this and found
> that http://java.sun.com/j2ee/dtds/web-app_2.2.dtd exists. Is it save to
> change this link in the web.xml paths ?

reading this posting:

http://archives2.real-time.com/pipermail/tomcat-devel/2000-August/004803.html

It would seem that you shouldn't have this problem anymore.  In any case,
you should be able to cut and pase a 2.3 dtd and put it somewhere
friendly (like on your webserver).


On a related note, I'm completely lost with tomcat's cvs.  Could someone
clue me in to which branches are active?  I see like ten branches, and on:

  http://jakarta.apache.org/cvsweb/index.cgi/jakarta-tomcat/

I cannot make heads or tails of it?  I'm looking for something like:

 branch name/ tomcat version/ dependent packages / dependent pacakges versions

This would indeed make things more friendly for people to jump into the
source (at least it would be for me).

Thanks,

Kenneth Topp

> 
> Thanks
> ingo
>