-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Emerson,

emerson cargnin wrote:
| I saw that in the server.xml web.xml validation is disabled. And with
| the comment:
|
| Note: XML Schema validation will not work with Xerces 2.2
|
| The thing is, I can't see any xerces library inside tomcat. I have
| xerces 2.4 on my app, but I believe it doesn't matter my webapp lib.

Xerces might be bundled with your JRE. I have Sun 1.5.0_13-b05 on
GNU/Linux, and I can see that:

SAXParser is implemented by class
com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl
DocumentBuilder is implemented by class
com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl

This looks like a re-packaged version of Xerces. I couldn't poke at the
org.apache.xerces.impl.Version (or even
com.sun.org.apache.xerces.impl.Version) to gee what version is being
used. This page
(http://java.sun.com/j2se/1.5.0/docs/guide/xml/jaxp/JAXP-Compatibility_150.html)
suggests that the 1.5 implementation includes a JAXP implementation
"based on Apache Xerces", but doesn't mention which version or what
changes they made :(

| Even in examples webapp it fails
|
| 13-Jun-2008 14:06:05 org.apache.catalina.core.StandardContext start
| SEVERE: Context [/examples] startup failed due to previous errors
| java.lang.NullPointerException
|         at
org.apache.xerces.impl.dv.dtd.DTDDVFactoryImpl.getBuiltInDV(Unknown
| Source)

This fails when you enable validation in the <Host> that contains the
exmaples webapp? Hmm... you may be running into the "will not work with
Xerces 2.2" problem.

If you're concerned about your webapp matching the schema, then you
could always run your web.xml file through another tool that will
validate it separately from the deployment. It's non-ideal, but at least
it should work.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkhbxVoACgkQ9CaO5/Lv0PAbZwCgi8LD0vXJhot60ALPFDwh55Ln
LMoAoJG6XL5di3YDLNv66/H7DYy7JNLm
=Hwvh
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

  • Validation emerson cargnin
    • Re: Validation Christopher Schultz

Reply via email to