spring启动报错Error creating bean with name 'org.springframework.orm.hibernate5.HibernateTemplate#0' ...

Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.orm.hibernate5.HibernateTemplate#0' defined in class path resource [db-context.xml]: Cannot resolve reference to bean 'sessionFactory' while setting bean property 'sessionFactory'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'flyway' defined in class path resource [db-context.xml]: Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'org.flywaydb.core.api.configuration.Configuration' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {}
  

报错信息指出 flyway 上有问题,更新的最新jar有问题,无法使用,

		
		    org.flywaydb
		    flyway-core
		    [5.2.4,)
		

改使用旧的

		
		    org.flywaydb
		    flyway-core
		    [5.2.4]
		

 

你可能感兴趣的:(java,spring)