Hi Quintin, I ran into this problem once I changed my configuration to run openEJB over JPA2.
David had warned me about this. Seems like some code is missing somewhere due to the change of specs in JPA2. INFO - Using 'openejb.deployments.classpath.include=com.desj.visa.*' INFO - Using 'openejb.deployments.classpath.exclude=.*/com\.ibm\.ws\.[^/]*.jar(!/)?' INFO - Using 'openejb.deployments.classpath.filter.descriptors=true' WARN - Inspecting classpath for applications: 51 urls. WARN - ADJUST THE EXCLUDE/INCLUDE!!!. Current settings: openejb.deployments.classpath.exclude='.*/com\.ibm\.ws\.[^/]*.jar(!/)?', openejb.deployments.classpath.include='com.desj.visa.*' INFO - Found ClientModule in classpath: F:\Workspaces\wks_jsf\CGESrvTest\lib\javassist-3.9.0.GA.jar INFO - Found ClientModule in classpath: F:\Workspaces\wks_jsf\CGESrvTest\lib\openjpa-2.0.0-SNAPSHOT.jar INFO - Found ClientModule in classpath: F:\Workspaces\wks_jsf\CGESrvTest\lib\xml-resolver-1.2.jar INFO - Found EjbModule in classpath: F:\Workspaces\wks_jsf\CGEEJB\ejbModule INFO - Found ClientModule in classpath: F:\Workspaces\wks_jsf\CGESrvTest\lib\serializer-2.7.1.jar WARN - Searched 51 classpath urls in 9656 milliseconds. Average 189 milliseconds per url. WARN - Consider adjusting your openejb.deployments.classpath.exclude and openejb.deployments.classpath.include settings. Current settings: exclude='.*/com\.ibm\.ws\.[^/]*.jar(!/)?', include='com.desj.visa.*' INFO - Beginning load: F:\Workspaces\wks_jsf\CGESrvTest\lib\javassist-3.9.0.GA.jar INFO - Beginning load: F:\Workspaces\wks_jsf\CGESrvTest\lib\openjpa-2.0.0-SNAPSHOT.jar INFO - Beginning load: F:\Workspaces\wks_jsf\CGESrvTest\lib\xml-resolver-1.2.jar INFO - Beginning load: F:\Workspaces\wks_jsf\CGEEJB\ejbModule INFO - Beginning load: F:\Workspaces\wks_jsf\CGESrvTest\lib\serializer-2.7.1.jar INFO - Configuring enterprise application: classpath.ear INFO - Configuring Service(id=Default Stateless Container, type=Container, provider-id=Default Stateless Container) INFO - Auto-creating a container for bean CGEServiceImpl: Container(type=STATELESS, id=Default Stateless Container) INFO - Configuring PersistenceUnit(name=cge, provider=org.hibernate.ejb.HibernatePersistence) INFO - Auto-creating a Resource with id 'db2x070NonJta' of type 'DataSource for 'cge'. INFO - Configuring Service(id=db2x070NonJta, type=Resource, provider-id=db2x070) INFO - Adjusting PersistenceUnit cge <jta-data-source> to Resource ID 'db2x070' from 'null' INFO - Adjusting PersistenceUnit cge <non-jta-data-source> to Resource ID 'db2x070NonJta' from 'null' INFO - Using 'openejb.validation.output.level=VERBOSE' INFO - Enterprise application "classpath.ear" loaded. INFO - Assembling app: classpath.ear INFO - PersistenceUnit(name=cge, provider=org.hibernate.ejb.HibernatePersistence) SLF4J: Class path contains multiple SLF4J bindings. SLF4J: Found binding in [jar:file:/F:/Workspaces/wks_jsf/CGESrvTest/lib/slf4j-jdk14-1.5.8.jar!/org/slf4j/impl/StaticLoggerBinder.class] SLF4J: Found binding in [jar:file:/F:/Workspaces/wks_jsf/CGESrvTest/lib/slf4j-log4j12-1.5.8.jar!/org/slf4j/impl/StaticLoggerBinder.class] SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation. 13-Nov-2009 3:46:54 PM org.hibernate.cfg.annotations.Version <clinit> INFO: Hibernate Annotations 3.5.0.Beta1 13-Nov-2009 3:46:54 PM org.hibernate.cfg.Environment <clinit> INFO: Hibernate 3.5.0-Beta-2 13-Nov-2009 3:46:54 PM org.hibernate.cfg.Environment <clinit> INFO: hibernate.properties not found 13-Nov-2009 3:46:54 PM org.hibernate.cfg.Environment buildBytecodeProvider INFO: Bytecode provider name : javassist 13-Nov-2009 3:46:54 PM org.hibernate.cfg.Environment <clinit> INFO: using JDK 1.4 java.sql.Timestamp handling 13-Nov-2009 3:46:54 PM org.hibernate.annotations.common.Version <clinit> INFO: Hibernate Commons Annotations 3.2.0-SNAPSHOT 13-Nov-2009 3:46:54 PM org.hibernate.ejb.Version <clinit> INFO: Hibernate EntityManager 3.5.0.Beta1 13-Nov-2009 3:46:54 PM org.hibernate.ejb.Ejb3Configuration configure INFO: Processing PersistenceUnitInfo [ name: cge ...] URL: file:/F:/Workspaces/wks_jsf/CGEEJB/ejbModule/ META-INF/orm.xml **/*.hbm.xml 13-Nov-2009 3:46:54 PM org.hibernate.cfg.Configuration configure INFO: configuring from resource: com/desj/visa/srv/cge/orm/config/hibernate.cfg.xml 13-Nov-2009 3:46:54 PM org.hibernate.cfg.Configuration getConfigurationInputStream INFO: Configuration resource: com/desj/visa/srv/cge/orm/config/hibernate.cfg.xml 13-Nov-2009 3:46:54 PM org.hibernate.cfg.Configuration doConfigure INFO: Configured SessionFactory: null 13-Nov-2009 3:46:54 PM org.hibernate.cfg.AnnotationBinder bindClass INFO: Binding entity from annotated class: com.desj.visa.srv.cge.beans.Application 13-Nov-2009 3:46:54 PM org.hibernate.cfg.annotations.EntityBinder bindTable INFO: Bind entity com.desj.visa.srv.cge.beans.Application on table TAPPLICATION 13-Nov-2009 3:46:54 PM org.hibernate.cfg.AnnotationBinder bindClass INFO: Binding entity from annotated class: com.desj.visa.srv.cge.beans.Environnement 13-Nov-2009 3:46:54 PM org.hibernate.cfg.annotations.EntityBinder bindTable INFO: Bind entity com.desj.visa.srv.cge.beans.Environnement on table TENVIRONNEMENT 13-Nov-2009 3:46:54 PM org.hibernate.cfg.AnnotationBinder bindClass INFO: Binding entity from annotated class: com.desj.visa.srv.cge.beans.Parametre 13-Nov-2009 3:46:54 PM org.hibernate.cfg.annotations.EntityBinder bindTable INFO: Bind entity com.desj.visa.srv.cge.beans.Parametre on table TPARAMETRE 13-Nov-2009 3:46:54 PM org.hibernate.cfg.AnnotationBinder bindClass INFO: Binding entity from annotated class: com.desj.visa.srv.cge.beans.Projet 13-Nov-2009 3:46:54 PM org.hibernate.cfg.annotations.EntityBinder bindTable INFO: Bind entity com.desj.visa.srv.cge.beans.Projet on table TPROJET 13-Nov-2009 3:46:54 PM org.hibernate.cfg.AnnotationConfiguration applyHibernateValidatorLegacyConstraintsOnDDL INFO: Hibernate Validator not found: ignoring INFO - Undeploying app: classpath.ear ERROR - Application could not be deployed: classpath.ear org.apache.openejb.OpenEJBException: Creating application failed: classpath.ear: Absent Code attribute in method that is not native or abstract in class file javax/validation/Validation at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:666) at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:449) at org.apache.openejb.assembler.classic.Assembler.buildContainerSystem(Assembler.java:367) at org.apache.openejb.assembler.classic.Assembler.build(Assembler.java:279) at org.apache.openejb.OpenEJB$Instance.<init>(OpenEJB.java:137) at org.apache.openejb.OpenEJB.init(OpenEJB.java:286) at org.apache.openejb.OpenEJB.init(OpenEJB.java:265) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.apache.openejb.loader.OpenEJBInstance.init(OpenEJBInstance.java:36) at org.apache.openejb.client.LocalInitialContextFactory.init(LocalInitialContextFactory.java:71) at org.apache.openejb.client.LocalInitialContextFactory.init(LocalInitialContextFactory.java:53) at org.apache.openejb.client.LocalInitialContextFactory.getInitialContext(LocalInitialContextFactory.java:42) at javax.naming.spi.NamingManager.getInitialContext(Unknown Source) at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source) at javax.naming.InitialContext.init(Unknown Source) at javax.naming.InitialContext.<init>(Unknown Source) at com.desj.visa.app.cge.tests.CGEServiceTest.setUp(CGEServiceTest.java:34) at junit.framework.TestCase.runBare(TestCase.java:125) at junit.framework.TestResult$1.protect(TestResult.java:106) at junit.framework.TestResult.runProtected(TestResult.java:124) at junit.framework.TestResult.run(TestResult.java:109) at junit.framework.TestCase.run(TestCase.java:118) at junit.framework.TestSuite.runTest(TestSuite.java:208) at junit.framework.TestSuite.run(TestSuite.java:203) at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130) at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196) Caused by: java.lang.ClassFormatError: Absent Code attribute in method that is not native or abstract in class file javax/validation/Validation at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(Unknown Source) at java.security.SecureClassLoader.defineClass(Unknown Source) at java.net.URLClassLoader.defineClass(Unknown Source) at java.net.URLClassLoader.access$000(Unknown Source) at java.net.URLClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClassInternal(Unknown Source) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Unknown Source) at org.hibernate.util.ReflectHelper.classForName(ReflectHelper.java:170) at org.hibernate.cfg.beanvalidation.BeanValidationActivator.applyDDL(BeanValidationActivator.java:76) at org.hibernate.cfg.AnnotationConfiguration.applyBeanValidationConstraintsOnDDL(AnnotationConfiguration.java:438) at org.hibernate.cfg.AnnotationConfiguration.applyConstraintsToDDL(AnnotationConfiguration.java:390) at org.hibernate.cfg.AnnotationConfiguration.secondPassCompile(AnnotationConfiguration.java:376) at org.hibernate.cfg.Configuration.buildMappings(Configuration.java:1188) at org.hibernate.ejb.Ejb3Configuration.buildMappings(Ejb3Configuration.java:1291) at org.hibernate.ejb.EventListenerConfigurator.configure(EventListenerConfigurator.java:195) at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:919) at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:523) at org.hibernate.ejb.HibernatePersistence.createContainerEntityManagerFactory(HibernatePersistence.java:157) at org.apache.openejb.assembler.classic.PersistenceBuilder.createEntityManagerFactory(PersistenceBuilder.java:184) at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:489) ... 32 more -- View this message in context: http://old.nabble.com/OutOfMemory-doing-a-JUnit-using-OpenEJB-Embedded-tp26289066p26371834.html Sent from the OpenEJB User mailing list archive at Nabble.com.
