当我尝试执行以下代码时,我将Play 2.6.7应用程序升级为可以播放2.7.0-R8,并得到JPAApi的错误“未知字段'* _._ ebean_intercept'在'字段列表'中”“ >
jpaApi.withTransaction(entityManager -> {
Query query = entityManager.createQuery(hql, modelClass);
return query.getResultList();
});
我的依赖性:
persistence.xml
<persistence xmlns="http://xmlns.jcp.org/xml/ns/persistence"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/persistence http://xmlns.jcp.org/xml/ns/persistence/persistence_2_1.xsd"
version="2.1">
<persistence-unit name="defaultPersistenceUnit" transaction-type="RESOURCE_LOCAL">
<provider>org.hibernate.jpa.HibernatePersistenceProvider</provider>
<non-jta-data-source>DefaultDS</non-jta-data-source>
<properties>
<property name="hibernate.dialect" value="org.hibernate.dialect.MySQLDialect"/>
</properties>
</persistence-unit>
</persistence>
请帮助!
答案 0 :(得分:1)
尝试将Ebean
升级到最新版本