On 28 October 2010 07:11, asyiklah <[email protected]> wrote: > > Hi there! > > I'm using OpenEJB 3.1.3 embeded in Tomcat 5.5.26 and I use hibernate 3.6 as > a JPA provider. ... > > When I run tomcat with OpenEJB and my app war archives in it, the deployment > failed with exception stack trace: > <code> > 2010-10-27 18:13:35,374 - ERROR - Unable to deploy collapsed ear in war > /wma: Exception: Creating application failed: ... > Caused by: java.lang.NoClassDefFoundError: > javax/persistence/spi/ProviderUtil ... > Upon searching, I found the class javax/persistence/spi/ProviderUtil is part > of Java EE 6/JPA 2.0 spec, which is not supported by OpenEJB. But I dont > think in my app I use any JPA 2.0. I specifically mention in persistence.xml > of 1.0. I know hibernate 3.6 supports JPA 2.0. I don't know if hibernate's > Criteria API is part of JPA 2.0 but that shouldn't cause the problem bcause > I have specifically menitioned 1.0 in persistence.xml.
As far as I know, openejb 3.1.3 only has the apis for jpa1 and hibernate 3.6 expects the jpa 2.0 api to be present. I'm also eagerly awaiting jpa2 support in openejb. I've only had success using an older jpa1 hibernate. I've considered to start using openejb 3.2-SNAPSHOT which does have jpa2 support AFAIK. Or maybe try just use the newer openejb javaee api jar. -- <>< Marius ><>
