Проблема
Перевели проект с spring boot 1.2.6 на 1.3.1. При старте приложения начала падать ошибка:
org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'xxxEntityManagerFactory' defined in class xxx.xxx: Unsatisfied dependency expressed through constructor argument with index 0 of type [org.springframework.boot.autoconfigure.orm.jpa.EntityManagerFactoryBuilder]: : No qualifying bean of type [org.springframework.boot.autoconfigure.orm.jpa.EntityManagerFactoryBuilder] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {}; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [org.springframework.boot.autoconfigure.orm.jpa.EntityManagerFactoryBuilder] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {}
at org.springframework.beans.factory.support.ConstructorResolver.createArgumentArray(ConstructorResolver.java:749)
at ...
Решение
В Spring Boot 1.3.1 вместо
org.springframework.boot.autoconfigure.orm.jpa.EntityManagerFactoryBuilderнужно использовать
org.springframework.boot.orm.jpa.EntityManagerFactoryBuilder.