You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Domingo Aguilera <do...@sinergia.com.mx> on 2001/07/20 02:43:07 UTC

XML question

I am trying to run the struts-example that is included in nightly build ( 18
july )

Tomcat can't run because there's a problem when trying to run the digester
duties.

README file states that :

"Download and install an XML parser that is compatible with the Java
API...."

I am trying Xerces 1.4.1.  Is this ok ?

Should I place the xerces.jar under
$TOMCAT_HOME/webapps/struts-example/WEB-INF/lib ?

or it has to be added to classpath in tomcat.sh ?

One more... is there anything else that I have to include besides xerces.jar
? ( I mean crimson.jar , jaxp.jar, etc. )


Domingo Aguilera
Chief Technical Officer
Sinergia Servicios,S.C.

www.sinergia.com.mx


Re: XML question

Posted by Robert Egan <ju...@dnai.com>.
Hi Domingo,

These notes may or may not help with your problem.

******************************************************************************************

  =================================
                            Release Notes
                            =============

$Id: RELEASE-NOTES-4.0-B5.txt,v 1.1 2001/05/11 05:55:11 craigmcc Exp $

................................
.......................................................

Tomcat 4.0 and XML Parsers:
--------------------------
Previous versions of Tomcat 4.0 exposed the XML parser used by Jasper (the
JAXP/1.1 reference implementation)
to web applications.  This is no longer
the case, because Jasper loads its parser with a new class loader instead.

Keep the following points in mind when considering how to use XML parsers in
Tomcat 4.0 and your web applications:
If you wish to make the JAXP/1.1 RI XML parser available to all web
applications,
simply move the "jaxp.jar" and "crimson.jar" files from the
"$TOMCAT_HOME/jasper" directory
to the "$TOMCAT_HOME/lib" directory.
If you wish to make another XML parser that is JAXP/1.1-compatible available to
all web applications,
install that parser into the
  "$TOMCAT_HOME/lib" directory and remove "jaxp.jar" and "crimson.jar"
from the "$TOMCAT_HOME/jasper" directory.  It has been reported that Xerces
1.3.1 can be used in this fashion,
but 2.x alpha releases can not be.
If you wish to use an XML parser (such as Xerces) in the WEB-INF/lib directory
of your web application,
this should now be possible, because of the modified JAXP 1.1 parser mentioned
below.
WARNING:  Tomcat 4.0 now ships with a modified version of the JAXP/1.1
(Final) "jaxp.jar" and "crimson.jar"
files in the "jasper" subdirectory.
The "sealed" attribute has been removed from the manifest file for these two
JARs,
to avoid "package sealing violation" errors that were caused by them in a JDK
1.3 environment.
You MUST NOT replace these files with a different (or later) release of JAXP,
unless that later
release has had the sealed attribute removed, or you will encounter "package
sealing violation" errors
when trying to use a different XML parser in a web application.
*********************************************************************************

Good luck,
Rob


Domingo Aguilera wrote:

> I am trying to run the struts-example that is included in nightly build ( 18
> july )
>
> Tomcat can't run because there's a problem when trying to run the digester
> duties.
>
> README file states that :
>
> "Download and install an XML parser that is compatible with the Java
> API...."
>
> I am trying Xerces 1.4.1.  Is this ok ?
>
> Should I place the xerces.jar under
> $TOMCAT_HOME/webapps/struts-example/WEB-INF/lib ?
>
> or it has to be added to classpath in tomcat.sh ?
>
> One more... is there anything else that I have to include besides xerces.jar
> ? ( I mean crimson.jar , jaxp.jar, etc. )
>
> Domingo Aguilera
> Chief Technical Officer
> Sinergia Servicios,S.C.
>
> www.sinergia.com.mx