Hibernate 5.2.7 - java.lang.NoSuchMethodError: org.hibernate.engine.spi.SessionFactoryImplementor.getProperties()Ljava/util/Map;

限于喜欢 提交于 2019-11-30 11:45:20

This problem is caused by having an old, incompatible copy of the JPA API on the classpath.

Specifically:

  • javax.persistence:persistence-api:1.0.2

Conflicts with the right version of the JPA 2.1 API:

  • org.hibernate.javax.persistence:hibernate-jpa-2.1-api:1.0.0.Final

Unfortunately Maven 3 is still unable to handle re-distributions of the same artifacts, which are sometimes necessary.

What version of the Gradle do you have?

I ask, because I have the same error which occurs after upgrade Gradle from 3.5 to 4.3. The same Hibernate version (5.2.9), the same Spring Boot (1.5.8) but in Gradle 3.5. - OK, 4.3 fail.

I've tested and latest version working fine was for me 3.5.1. I've tested versions from 4.0 to 4.4-rc-6 (latest at this moment).

distributionUrl=https\://services.gradle.org/distributions/gradle-3.5.1-all.zip
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!