0
点赞
收藏
分享

微信扫一扫

Error creating bean with name 'sqlSessionFactory' defined in class path resource 报错解决

小龟老师 2022-08-11 阅读 35

报错:

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.apache.ibatis.session.SqlSessionFactory]: Factory method 'sqlSessionFactory' threw exception; nested exception is java.io.FileNotFoundException: class path resource [mybatis/SqlMapConfig.xml] cannot be opened because it does not exist

Error creating bean with name

 

 

 

解决:

在    Application 上加注解:

1 @EnableAutoConfiguration(exclude={DataSourceAutoConfiguration.class})

Error creating bean with name

 

 




举报

相关推荐

0 条评论