7 Replies Latest reply on Apr 22, 2013 10:42 AM by rlu

    Upgrade JBoss AS 7.1.1.Final to JBoss EAP 6.1.0 Alpha

    rlu Newbie

      Hello,

       

      maybe i'm posting in wrong group but issue occurs during migration to JBoss EAP 6.1.0.Alpha.

      My application runs fine in JBoss AS 7.1.1.Final under Oracle JDK 1.6.0_33 using Oracle DB. jdbc adapter is installed as module in JBoss AS.

      Today I tried to deploy this application in JBoss EAP 6.1.0.Alpha an got following exception:

       

      13:32:53,625 ERROR [org.hibernate.bytecode.internal.javassist.JavassistClassTransformer] (ServerService Thread Pool -- 19) HHH000373: Unable to transform class: cannot find a.b.EnumClass

      13:32:53,626 WARN  [org.jboss.modules] (ServerService Thread Pool -- 19) Failed to define class a.b.EntityClass in Module "deployment.app-ear.ear.app-ejb-0.3.0-SNAPSHOT.jar:main" from Service Module Loader: java.lang.ClassFormatError: Unable to transform class: cannot find a.b.EnumClass

          at org.jboss.modules.ModuleClassLoader.defineClass(ModuleClassLoader.java:396) [jboss-modules.jar:1.2.0.CR1]

          at org.jboss.modules.ModuleClassLoader.loadClassLocal(ModuleClassLoader.java:254) [jboss-modules.jar:1.2.0.CR1]

          at org.jboss.modules.ModuleClassLoader$1.loadClassLocal(ModuleClassLoader.java:73) [jboss-modules.jar:1.2.0.CR1]

          at org.jboss.modules.Module.loadModuleClass(Module.java:518) [jboss-modules.jar:1.2.0.CR1]

          at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:182) [jboss-modules.jar:1.2.0.CR1]

          at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468) [jboss-modules.jar:1.2.0.CR1]

          at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:456) [jboss-modules.jar:1.2.0.CR1]

          at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:398) [jboss-modules.jar:1.2.0.CR1]

          at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:120) [jboss-modules.jar:1.2.0.CR1]

          at org.hibernate.internal.util.ReflectHelper.classForName(ReflectHelper.java:165) [hibernate-core-4.2.0.CR1.jar:4.2.0.CR1]

          at org.hibernate.ejb.Ejb3Configuration.classForName(Ejb3Configuration.java:1318) [hibernate-entitymanager-4.2.0.CR1.jar:4.2.0.CR1]

          at org.hibernate.ejb.Ejb3Configuration.addNamedAnnotatedClasses(Ejb3Configuration.java:1390) [hibernate-entitymanager-4.2.0.CR1.jar:4.2.0.CR1]

          at org.hibernate.ejb.Ejb3Configuration.addClassesToSessionFactory(Ejb3Configuration.java:1184) [hibernate-entitymanager-4.2.0.CR1.jar:4.2.0.CR1]

          at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:1048) [hibernate-entitymanager-4.2.0.CR1.jar:4.2.0.CR1]

          at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:693) [hibernate-entitymanager-4.2.0.CR1.jar:4.2.0.CR1]

          at org.hibernate.ejb.HibernatePersistence.createContainerEntityManagerFactory(HibernatePersistence.java:73) [hibernate-entitymanager-4.2.0.CR1.jar:4.2.0.CR1]

          at org.jboss.as.jpa.service.PersistenceUnitServiceImpl.createContainerEntityManagerFactory(PersistenceUnitServiceImpl.java:200) [jboss-as-jpa-7.2.0.Alpha1-redhat-4.jar:7.2.0.Alpha1-redhat-4]

          at org.jboss.as.jpa.service.PersistenceUnitServiceImpl.access$600(PersistenceUnitServiceImpl.java:57) [jboss-as-jpa-7.2.0.Alpha1-redhat-4.jar:7.2.0.Alpha1-redhat-4]

          at org.jboss.as.jpa.service.PersistenceUnitServiceImpl$1.run(PersistenceUnitServiceImpl.java:99) [jboss-as-jpa-7.2.0.Alpha1-redhat-4.jar:7.2.0.Alpha1-redhat-4]

          at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [rt.jar:1.6.0_33]

          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [rt.jar:1.6.0_33]

          at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_33]

          at org.jboss.threads.JBossThread.run(JBossThread.java:122)

      Caused by: java.lang.instrument.IllegalClassFormatException: Unable to transform class: cannot find a.b.EnumClass

          at org.hibernate.ejb.instrument.InterceptFieldClassFileTransformer.transform(InterceptFieldClassFileTransformer.java:79) [hibernate-entitymanager-4.2.0.CR1.jar:4.2.0.CR1]

          at org.jboss.as.jpa.classloader.JPADelegatingClassFileTransformer.transform(JPADelegatingClassFileTransformer.java:48) [jboss-as-jpa-7.2.0.Alpha1-redhat-4.jar:7.2.0.Alpha1-redhat-4]

          at org.jboss.as.server.deployment.module.DelegatingClassFileTransformer.transform(DelegatingClassFileTransformer.java:60)

          at org.jboss.modules.ModuleClassLoader.defineClass(ModuleClassLoader.java:394) [jboss-modules.jar:1.2.0.CR1]

          ... 22 more

       

      Where EnumClass is an Enum and used as field in EntityClass.

      Deployment Error is following:

      JBAS014777:   Services which failed to start:      service jboss.persistenceunit."app-ear.ear/app-ejb-0.3.0-SNAPSHOT .jar#primary": org.jboss.msc.service.StartException in service jboss.persistenceunit."app-ear.ear/app-ejb-0.3.0-SNAP HOT.jar#primary": javax.persistence.PersistenceException: [PersistenceUnit: primary] class or package not found

      ERROR [org.jboss.as] (Controller Boot Thread) JBAS015875: JBoss EAP 6.1.0.Alpha1 (AS 7.2.0.Alpha1-redhat-4) started (with errors) in 11678ms - Started 260 of 456 services (103 services failed or missing dependencies, 92 services are passive or on-demand)