[jdom-interest] JDOM and TOMCAT

Brett McLaughlin brett.mclaughlin at lutris.com
Tue Aug 15 06:56:48 PDT 2000


Adam Leggett wrote:
> 
> 
> 
> Brett McLaughlin wrote:
> 
> > Remove xerces_1_0_3 - Cocoon should work fine with the xerces.jar
> > that
> > comes with JDOM.
> >
> > -Brett
> >
> 
> Brett,
> 
> Tried that already - Cocoon does'nt seem to like xerces.jar from JDOM.
> 
> Cocoon throws :
> 
> org.xml.sax.SAXParseException: File "[My Filename]" not found.

Oh, yeah.... Xerces 1.1.x changed from java.net.URL (allowing files to
look like c:\foo\bar.xml) to a custom class (requiring files to look
like file:///c:/foo/bar.xml).

Hmmm... and I guess SAX 2 wasn't fully implemented in Xerces 1.0.3,
which is why you get the JDOM error. That's actually sort of sticky...
post to Cocoon-users and see what is the status on getting up to the
newer Xerces (it should just be a file link change), or if there is a
CVS version that supports it. Citing SAX 2 support as a requirement
might help...

JDOM might work with Xerces 1.0.3, though, so you could also try that...

-Brett

>  at
> org.apache.cocoon.parser.AbstractParser.fatalError(AbstractParser.java:105)
> 
>  at
> org.apache.xerces.framework.XMLParser.reportError(XMLParser.java:998)
>  at
> org.apache.xerces.readers.DefaultEntityHandler.startReadingFromDocument(DefaultEntityHandler.java:499)
> 
>  at
> org.apache.xerces.framework.XMLParser.parseSomeSetup(XMLParser.java:303)
> 
>  at org.apache.xerces.framework.XMLParser.parse(XMLParser.java:860)
>  at org.apache.cocoon.parser.XercesParser.parse(XercesParser.java:84)
>  at
> org.apache.cocoon.parser.AbstractParser.parse(AbstractParser.java:83)
>  at
> org.apache.cocoon.producer.ProducerFromFile.getDocument(ProducerFromFile.java:78)
> 
>  at org.apache.cocoon.Engine.handle(Engine.java, Compiled Code)
>  at org.apache.cocoon.Cocoon.service(Cocoon.java:167)
>  at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
>  at
> org.apache.tomcat.core.ServletWrapper.handleRequest(ServletWrapper.java,
> Compiled Code)
>  at
> org.apache.tomcat.core.ContextManager.service(ContextManager.java:559)
> 
>  at
> org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:160)
> 
>  at
> org.apache.tomcat.service.TcpConnectionThread.run(SimpleTcpEndpoint.java:338)
> 
>  at java.lang.Thread.run(Thread.java:479)
> 
> 
> However using Xerces_1_0_3 it finds my xml file no problem
> 
> Any ideas? Can I force Cocoon to use the JDom Xerces or vice versa?
> 
> Adam
> 

-- 
Brett McLaughlin, Enhydra Strategist
Lutris Technologies, Inc. 
1200 Pacific Avenue, Suite 300 
Santa Cruz, CA 95060 USA 
http://www.lutris.com
http://www.enhydra.org



More information about the jdom-interest mailing list