Error starting spring boot "An attempt was made to call a method that does not exist"
You should not specify the version of Hibernate to use as the spring-boot-starter-data-jpa
dependency takes care of that.
If you run mvn dependency:tree | grep hibernate
, you see that 2 versions of hibernate are included:
16:20 $ mvn dependency:tree | grep hibernate
[INFO] | | \- org.hibernate.validator:hibernate-validator:jar:6.0.17.Final:compile
[INFO] | +- org.hibernate:hibernate-core:jar:5.4.6.Final:compile
[INFO] +- org.hibernate.orm:hibernate-core:jar:6.0.0.Alpha2:compile
[INFO] | +- org.hibernate.common:hibernate-commons-annotations:jar:5.1.0.Final:compile
[INFO] +- org.hibernate:hibernate-entitymanager:jar:5.4.8.Final:compile
It seems the group id changed from org.hibernate
to org.hibernate.orm
, that is why Maven does not notice it is the same library.
Also the hibernate-entitymanager
dependency can be removed.
Delete your .m2 folder in c:\users\.m2 and then run maven install it will fix your classpath problem