You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Gu...@inexware.fr on 2001/04/30 16:18:24 UTC

[C2]org.xml.sax.SAXNotSupportedException

Hello,
It happens that I replaced jaxp.jar and parser.jar in $TOMCAT_HOME/lib by
crimson.jar (v1.1 from CVS) and its jaxp.jar. I made these changes to have
SAX 2 and to
do "streaming parsing" (it is impossible with Xerces...).
But this configuration does not work well with Cocoon (2) :
during Servlet initialization, Cocoon caught this exception :
org.xml.sax.SAXNotSupportedException: Property:
http://xml.org/sax/properties/lexical-handler
        at
org.apache.crimson.parser.XMLReaderImpl.setProperty(XMLReaderImpl.java:248)
        at
org.apache.cocoon.components.parser.JaxpParser.parse(JaxpParser.java:61)
        at org.apache.cocoon.Cocoon.configure(Cocoon.java:153)
        at org.apache.cocoon.Cocoon.initialize(Cocoon.java:137)
        at
org.apache.cocoon.servlet.CocoonServlet.createCocoon(CocoonServlet.java:525)
        at
org.apache.cocoon.servlet.CocoonServlet.init(CocoonServlet.java:150)
        at
org.apache.tomcat.core.ServletWrapper.doInit(ServletWrapper.java:317)
        ...
Cocoon tries to set a null lexical handler to Crimson, but Crimson does not
like it...
I don't know which one is wrong, Cocoon or Crimson but I choose to change
JaxpParser :

61,62c61,63
<         reader.setProperty
("http://xml.org/sax/properties/lexical-handler",
<                            super.lexicalHandler);
---
>         if (super.lexicalHandler != null)
>             reader.setProperty
("http://xml.org/sax/properties/lexical-handler",
>                                super.lexicalHandler);

Now all seems ok...

Best Regards.
Gwenn.

----
Garlic gum is not funny
                                          Bart's BlackBoard (The Simpsons)


---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>