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


    报错:

    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

    解决:

    在    Application 上加注解:

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

    参考文档:

    https://www.cnblogs.com/shifu8005/p/9873271.html

  • 相关阅读:
    MySQL多表查询
    多表关联
    MySQL数据类型 约束
    初识数据库
    socker server和 event
    os 模块 和 os模块下的path模块
    sys 模块
    time 模块
    目录规范

  • 原文地址:https://www.cnblogs.com/whycai/p/13121230.html
Copyright © 2020-2023  润新知