cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From (Steven Cummings)
Subject Xerces SAXParser does not implement XMLReader?
Date Thu, 13 Jun 2002 17:06:18 GMT
I'm having a problem lately with using Xerces-J 2.0.1 lately under Tomcat that I never seemed
to have before. Perhaps it's the version that is incorrect because it seems that Tomcat used
Xerces before. The weird thing about this problem is that it doesn't always show up in similiar
test cases. I came across it while tring to set up Cocoon 2.0.2.

On my WinXP machine running Tomcat 4.0.3, Xerces 2.0.1, using the xml-api.jar from Xalan-2.3.1,
and the latest cocoon, I can get the front cocoon page to run, but a lot of the samples bomb
out with exception messages (I don't have one on hand now unfortunately).

On a RedHat 6.2 box, using JDK 1.3.1, Tomcat 4.0.3, and the same cocoon/xerces/xalan configuration,
I get the following error even when tring to access the root of the cocoon webapp:

type fatal

message SAX2 driver class org.apache.xerces.parsers.SAXParser does not implement XMLReader

description java.lang.ClassCastException: org.apache.xerces.parsers.StandardParserConfiguration

sender org.apache.cocoon.servlet.CocoonServlet

source Cocoon servlet


java.lang.ClassCastException: org.apache.xerces.parsers.StandardParserConfiguration
    at org.xml.sax.helpers.XMLReaderFactory.createXMLReader(Unknown Source)
    at org.xml.sax.helpers.XMLReaderFactory.createXMLReader(Unknown Source)
    at org.apache.cocoon.components.language.markup.AbstractMarkupLanguage.generateCode(
    at org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.generateResource(
    at org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.createResource(
    at org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.load(



I looked through the Xerces sources, and it does seem to be the case that the xerces SAXParser
from 2.0.1 does not implement XMLReader, even through inheritance. So apparently Tomcat wants
to use it through JAXP, and my main question is why does this error only show up part of the
time. Is there an incompatibility with Tomcat 4.0.X and the latest Xerces? Sorry for the post
to multiple lists, but I'm not yet sure of where the problem really lies. Thank you!


Steven Cummings <>
Columbia, MO

Your favorite stores, helpful shopping tools and great gift ideas. Experience the convenience
of buying online with Shop@Netscape!

Get your own FREE, personal Netscape Mail account today at

Please check that your question  has not already been answered in the
FAQ before posting.     <>

To unsubscribe, e-mail:     <>
For additional commands, e-mail:   <>

View raw message