You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by Magnus ?or Torfason <ma...@handtolvur.is> on 2000/07/16 19:12:38 UTC

Xerces vs. com.sun.xml

I was just looking through the Tomcat distribution and noticed that it is
distributed with the com.sun.xml classes, but not Xerces.  Why is this
(considering that both Xerces and Tomcat are Apache projects)?

magnus


Re: Xerces vs. com.sun.xml

Posted by Costin Manolache <co...@eng.sun.com>.
Magnus ?or Torfason wrote:

> I was just looking through the Tomcat distribution and noticed that it is
> distributed with the com.sun.xml classes, but not Xerces.  Why is this
> (considering that both Xerces and Tomcat are Apache projects)?

One reason is "historic" - that's the parser that was used initially.
The current release uses JAXP - so any parser would work.

I tried to use xerces, but that version had a strange problem - even
if tomcat implements resolveEntity(), xerces didn't seem to use it.
I found some internal APIs and I'm sure there is a simple way
to turn it off, but that would mean to use xerces internals.
I haven't tested with the latest version, but if you are on the
online you can use any version of xerces that supports jaxp.

A third reason is the size, of course. Tomcat does use an XML
parser for configuration, but the parser was bigger than tomcat
itself. A bit too much for just reading the config.

Costin