mybatis的mapper注入失败

因为处在两个不同的资源文件夹下:

导致classpath无法加载其中一些文件,所以修改为classpath*后顺利进行。

    <!-- 加载spring容器 -->
    <!-- needed for ContextLoaderListener -->
    <context-param>
        <param-name>contextConfigLocation</param-name>
        <param-value>classpath*:spring/applicationContext*.xml</param-value>
    </context-param>

    <!-- Bootstraps the root web application context before servlet initialization -->
    <listener>
        <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
    </listener>

错误如下

 

posted @ 2017-10-20 12:26  lamsey16  阅读(665)  评论(0编辑  收藏  举报