-
1. Re: Issue in Eclipselink JPA support on wildfly 10.1
smarlow Aug 31, 2016 3:01 PM (in response to samyomar82)What happens if you add the class to the persistence.xml?
class>com.unilever.replenishment.model.entities.ReplItem</class>
-
2. Re: Issue in Eclipselink JPA support on wildfly 10.1
vmrnkv Dec 31, 2016 3:44 AM (in response to smarlow)Hi Scott, I have the same problem and using of class helps. But I have a lot of entities and in general I do not want to list all of them. Do you know how to solve the original issue?
-
3. Re: Issue in Eclipselink JPA support on wildfly 10.1
samyomar82 Jan 11, 2017 3:49 PM (in response to samyomar82)I confirm that it works when I add
class>com.unilever.replenishment.model.entities.ReplItem</class>
in persistence unit, but its not a practical solution for a huge number of entity classes.
Any solution or workaround ?
-
4. Re: Issue in Eclipselink JPA support on wildfly 10.1
smarlow Jan 12, 2017 10:37 AM (in response to samyomar82)Good to know that works around the failure. That gives us a clue that EclipseLink cannot discover the entity classes for some reason. I'm not sure why.
https://github.com/wildfly/wildfly/blob/master/testsuite/compat/src/test/java/org/jboss/as/test/compat/jpa/eclipselink/EclipseLinkSharedModuleProviderTestCase.java#L52 shows that we aren't using the "class" workaround in our (very simple) EclipseLink unit test that ensures that EclipseLink works at all with each release of WildFly. The WildFly unit test is using EclipseLink version 2.6.3. Which version of EclipseLink are you using?
It may be that you didn't set the EclipseLink system property ("
eclipselink.archive.factory"
value=
"org.jipijapa.eclipselink.JBossArchiveFactoryImpl"
) as mentioned here. -
5. Re: Issue in Eclipselink JPA support on wildfly 10.1
vmrnkv Jan 13, 2017 3:11 PM (in response to smarlow)Thank you, it works for me.
As a result I have:
modules/system/layers/base/org/eclipse/persistence/main/module.xml
<module xmlns="urn:jboss:module:1.3" name="org.eclipse.persistence"> <properties> <property name="jboss.api" value="private"/> </properties> <resources> <resource-root path="jipijapa-eclipselink-10.1.0.Final.jar"/> <resource-root path="eclipselink-2.6.4.jar"/> <filter> <exclude path="javax/**" /> </filter> </resources> <dependencies> <module name="asm.asm"/> <module name="javax.api"/> <module name="javax.annotation.api"/> <module name="javax.enterprise.api"/> <module name="javax.persistence.api"/> <module name="javax.transaction.api"/> <module name="javax.validation.api"/> <module name="javax.xml.bind.api"/> <module name="org.antlr"/> <module name="org.dom4j"/> <module name="org.javassist"/> <module name="org.jboss.as.jpa.spi"/> <module name="org.jboss.logging"/> <module name="org.jboss.vfs"/> </dependencies> </module>
pom.xml in my project:
<dependency> <groupId>org.eclipse.persistence</groupId> <artifactId>eclipselink</artifactId> <version>2.6.4</version> <scope>provided</scope> </dependency>
standalone-full.xml
<system-properties> <property name="eclipselink.archive.factory" value="org.jipijapa.eclipselink.JBossArchiveFactoryImpl"/> </system-properties>