If jpa dependency version in pom.xml is not compatible with springboot version, this error will occur.
try removing the version in jpa dependency