例外[EclipseLink-28019](Eclipse Persistence Services - 2.5.0.v20130507-3faac2b):

时间:2013-09-04 18:04:06

标签: exception jpa eclipselink

我正在使用glassfish 4来部署我的应用,但我遇到以下错误:

can not Deploy myapplication
deploy is failing = Error occurred during deployment: Exception while deploying the app [MyApplication]: Exception [EclipseLink-28019] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.EntityManagerSetupException
Exception Description: Deployment of PersistenceUnit [PU] failed. Close all factories for this PersistenceUnit.
Internal Exception: Exception [EclipseLink-0] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.IntegrityException
Descriptor Exceptions:
-------------------------------------------------- -------

Runtime Exceptions:
-------------------------------------------------- -------

java.lang.NullPointerException
. Please see server.log for more details.

并且还不能理解这个问题的原因或解决方法。 细节是我使用以下依赖JPA实现:

依赖 的groupId> org.eclipse.persistence groupId artifactId eclipselink artifactId 版本> 2.4.0版本  依赖

和javax.persistence-2.0.4.v201112161009.jar

2 个答案:

答案 0 :(得分:0)

我遇到此错误的一个场景是当有一个抽象的JPA实体,其下面没有具体的类。确保扩展所有抽象JPA实体以创建具体的JPA实体。

答案 1 :(得分:0)

将eclipselink从2.6.5升级到2.7时,我遇到了类似的问题。

因为我的POM.xml在下面有一行,所以我必须将其删除,然后将新版本添加到2.7.4 artifactId eclipselink 到最新版本的问题已解决。

   <dependency>
        <groupId>org.eclipse.persistence</groupId>
        <artifactId>org.eclipse.persistence.jpa.modelgen.processor</artifactId>
        <version>2.6.5</version>
        <scope>provided</scope>
    </dependency>
相关问题