[jdom-interest] Wierd SAX Error. Does anyone have ideas

Laurent Bihanic laurent.bihanic at atosorigin.com
Mon Jun 17 01:05:45 PDT 2002


Hi,

Prior to beta 8, JDOM's SAXBuilder used to memorise the SAX parser class and, 
when asked to parse another document, allocate the new parser instance using 
the no-arg constructor. This appeared to be a problem with WebLogic's JAXP 
implementation.
To fix the problem, do not reuse SAXBuilder objects or update to JDOM Beta 8.

Laurent

Ladhani, Dilip wrote:
> Hi guys,
>  
> I have been working with this xml for a while. I kinda get 2 huge xml strings (over the internet) that I have to parse. I have been working with the first one and everything seems fine. I can parse it and do stuff.
> However when I started using the second one, I started getting SAX errors?? Here's what I do
>  
> SAXBuilder builder = new SAXBuilder();
>  
> Document doc = builder.build(new StringReader(productXML)); // productXML is the xml string
> Element eABC = doc.getRootElement();
>  
> // I work with this element and manipulate it, works perfectly
> // Now the second xml
>  
> Document doc = builder.build(new StringReader(reportXML)); // Error occurs here
> Element eABC = doc.getRootElement();
>  
>  
> The error occurs right where marked. Here's the description 
> "org.jdom.JDOMException: Error in building: SAX2 driver class weblogic.xml.jaxp.RegistryXMLReader loaded but cannot be instantiated
>  (no empty public constructor?)"
>  
>  
> I even tried using Document doc2 for the second string, still doesn't work.
>  
> What's the problem???
> 
> Thank you for your time.




More information about the jdom-interest mailing list