I managed to get JAXB to work as regular
java application. However, I can't get it to work in my
J2EE application.
I'm currently getting the following exception:-
java.lang.NoSuchMethodError: javax.xml.parsers.DocumentBuilderFactory.getSchema()Ljavax/xml/validation/Schema
By reading this site,
http://forum.java.sun.com/thread.jspa?threadID=642441&messageID=3787464 , it seems like it is loading older Xerces.class, and omitting the newer class in jaxb jars sitting in my /WEB-INF/lib.
To get my java app to work, I have to invoke the java launcher with -Djava.endorsed.dirs= option, so that it picks up the new class.
But, how do I solve the class loader issue with a J2EE project?
I know I could solve this problem by switching to jdk 1.5, but my project is deployed in WAS 6 which uses jdk 1.4.
Any tips would be grateful here.
Thanks.