Paul- <br>If you still are unable to figure out what's going on, feel free to zip up your simple test app and I'll take a look at it. <br><br>-Rick <br><blockquote class="quote light-black dark-border-color"><div class="quote light-border-color"> <div class="quote-author" style="font-weight: bold;">Paul Copeland wrote:</div> <div class="quote-message shrinkable-quote">Hi Rick - <br><br>Thanks. As I mentioned the openjpa example hellojpa also works for me <br>WITHOUT the xerces jar. But my very simple test app does not work with <br>xerces. However, I found out that if I add these two properties to my <br>runtime ant task then I do NOT need the xerces jar. <br><br> <sysproperty key="javax.xml.parsers.SAXParserFactory" <br>value="com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl"/> <br> <sysproperty key="javax.xml.parsers.DocumentBuilderFactory" <br>value="com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl"/> <br><br>There is some classloader subtlety that I don't fully understand here. <br><br>- Paul <br><br>On 3/23/2009 8:17 AM, Rick Curtis wrote: <br>> Paul - <br>> I quickly looked through the javadoc for the <br>> <a href="http://java.sun.com/javase/6/docs/api/javax/xml/parsers/SAXParserFactory.html#newInstance(" target="_top" rel="nofollow">http://java.sun.com/javase/6/docs/api/javax/xml/parsers/SAXParserFactory.html#newInstance(</a>) <br>> SAXParserFactory and I'm thinking that your problem is something specific <br>> to your environment.? I was able to run the examples on my box without <br>> adding xercesImpl.jar to my classpath. With my JSE1.6 install, <br>> SAXParserFactoryImpl is found in the [java_home]\lib\rt.jar. <br>> <br>> -Rick <br>> <br>> Paul Copeland wrote: <br>> <br>>> More info on this. I upgraded to Java SE 1.6.0_12 and I still need the <br>>> same jars (including xerces). <br>>> <br>>> Using OpenJPA 1.2 - <br>>> <br>>> 1) Only two jars are needed to compile my (very simple) test application - <br>>> <br>>> - openjpa-1.2.0.jar <br>>> - geronimo-jta_1.1_spec-1.1.jar <br>>> <br>>> 2) At runtime (standalone, not in a container) I also need these jars <br>>> (plus JDBC driver of course) - <br>>> <br>>> - serp-1.13.1.jar <br>>> - geronimo-jta_1.1_spec-1.1.jar <br>>> - commons-collections-3.2.jar <br>>> - commons-lang-2.1.jar <br>>> - xercesImpl.jar <br>>> <br>>> 3) When I build and run the apache-openjpa-1.2.0/examples/hellojpa <br>>> (Derby example) I do NOT need xerces. <br>>> .... <br>>> <br>>> <br>> <br>> <br></div> </div></blockquote>
-- View this message in context: http://n2.nabble.com/Questions-about--classpath-for-OpenJPA-tp2504942p2522760.html Sent from the OpenJPA Users mailing list archive at Nabble.com.
