[Beginner's Corner] - Classloading trouble with EJB3 and EclipseLink
by Matti Hansson
Matti Hansson [http://community.jboss.org/people/aznan] created the discussion
"Classloading trouble with EJB3 and EclipseLink"
To view the discussion, visit: http://community.jboss.org/message/563351#563351
--------------------------------------------------------------
Hi!
I'm working on a project that is using EclipseLink 2.1.1 for OR- and OX-mapping. When I try to deploy on JBoss 4.2.3.GA I get the following error:
java.lang.LinkageError: loader constraint violation: loader (instance of org/jboss/web/tomcat/service/WebCtxLoader$ENCLoader) previously initiated loading for a different type with name "javax/persistence/LockModeType"
Turns out the EclipseLink jar, which is included in the project war file, has an enum javax.persistence.LockModeType, and another enum with the same name can be found in ejb3-persistence.jar in the JBoss' server lib. This is the jboss-web.xml:
<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE jboss-web PUBLIC -//JBoss//DTD Web Application 4.2//EN http://www.jboss.org/j2ee/dtd/jboss-web_4_2.dtd><jboss-web> <context-root>my-project</context-root> <class-loading java2ClassLoadingCompliance="false"> <loader-repository> my-project:archive=my-project <loader-repository-config>java2ParentDelegation=false</loader-repository-config> </loader-repository> </class-loading></jboss-web>
But it doesn't seem to do much good. Please help!
/Matti
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/563351#563351]
Start a new discussion in Beginner's Corner at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 5 months
[jBPM] - Exceptions with hibernate session mappings in 4.5.SNAPSHOT
by Stefano Cancedda
Stefano Cancedda [http://community.jboss.org/people/festano1] created the discussion
"Exceptions with hibernate session mappings in 4.5.SNAPSHOT"
To view the discussion, visit: http://community.jboss.org/message/562829#562829
--------------------------------------------------------------
hi,
yesterday I've updated the JBPM snapshot of my pom to 4.5-SNAPSHOT. now all my tests are falling always during hibernate session startup! The exception occurs during the mapping validation:
09:19:40,204 FIN | http://community.jboss.org/message/562829#562829 Exceptions with hibernate session mappings in 4.5.SNAPSHOT eagerly initializing org.jbpm.pvm.internal.id.DatabaseIdComposer
09:19:40,225 INF | http://community.jboss.org/message/562829#562829 Exceptions with hibernate session mappings in 4.5.SNAPSHOT Hibernate 3.3.1.GA
09:19:40,228 INF | http://community.jboss.org/message/562829#562829 Exceptions with hibernate session mappings in 4.5.SNAPSHOT hibernate.properties not found
09:19:40,261 INF | http://community.jboss.org/message/562829#562829 Exceptions with hibernate session mappings in 4.5.SNAPSHOT Bytecode provider name : javassist
09:19:40,266 INF | http://community.jboss.org/message/562829#562829 Exceptions with hibernate session mappings in 4.5.SNAPSHOT using JDK 1.4 java.sql.Timestamp handling
09:19:40,324 INF | http://community.jboss.org/message/562829#562829 Exceptions with hibernate session mappings in 4.5.SNAPSHOT configuring from resource: jbpm.hibernate.cfg.xml
09:19:40,325 INF | http://community.jboss.org/message/562829#562829 Exceptions with hibernate session mappings in 4.5.SNAPSHOT Configuration resource: jbpm.hibernate.cfg.xml
09:19:40,417 INF | http://community.jboss.org/message/562829#562829 Exceptions with hibernate session mappings in 4.5.SNAPSHOT Reading mappings from resource : jbpm.repository.hbm.xml
09:19:40,583 INF | http://community.jboss.org/message/562829#562829 Exceptions with hibernate session mappings in 4.5.SNAPSHOT Reading mappings from resource : jbpm.execution.hbm.xml
09:19:40,715 INF | http://community.jboss.org/message/562829#562829 Exceptions with hibernate session mappings in 4.5.SNAPSHOT Reading mappings from resource : jbpm.history.hbm.xml
09:19:40,763 INF | http://community.jboss.org/message/562829#562829 Exceptions with hibernate session mappings in 4.5.SNAPSHOT Reading mappings from resource : jbpm.task.hbm.xml
09:19:40,794 INF | http://community.jboss.org/message/562829#562829 Exceptions with hibernate session mappings in 4.5.SNAPSHOT Reading mappings from resource : jbpm.identity.hbm.xml
09:19:40,841 INF | http://community.jboss.org/message/562829#562829 Exceptions with hibernate session mappings in 4.5.SNAPSHOT Configured SessionFactory: null
0.0.1. EXCEPTION ###########################################
09:19:40,849 INF | http://community.jboss.org/message/562829#562829 Exceptions with hibernate session mappings in 4.5.SNAPSHOT exception while executing command org.jbpm.pvm.internal.cmd.CheckDbCmd@b4cbc5
Caused by: org.hibernate.MappingException: property mapping has wrong number of columns: org.jbpm.pvm.internal.history.model.HistoryVariableUpdateImpl.oldValue type: object
at org.hibernate.mapping.PersistentClass.validate(PersistentClass.java:459)
at org.hibernate.mapping.SingleTableSubclass.validate(SingleTableSubclass.java:66)
at org.hibernate.cfg.Configuration.validate(Configuration.java:1135)
at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1320)
at org.hibernate.cfg.AnnotationConfiguration.buildSessionFactory(AnnotationConfiguration.java:867)
at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:669)
... 57 more
I've executed test with hsqldb in-memory and table generation (using JbpmTestCase as base-class), and also with the full test architecture of my project (Spring-test-framework classes with SpringJUnit4ClassRunner, EntityManager as SessionFactory passed to SpringProcessEngine, and local datasource connection with remote Oracle10g database containing jBPM schema -running on xubuntu os).
It's nothing wrong with classes, as far i can see, and the error happens also with fresh generated tables.
Any hints?
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/562829#562829]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 5 months