1.在 spring-mybatis.xml中配置 service里面就可以读取到了
<!-- 引入配置文件 -->
<context:property-placeholder location="classpath:*.properties" ignore-unresolvable="true"/>
2.同上,在spring-mvc.xml中配置 controller就可以读取到了
<!-- 引入配置文件 -->
<context:property-placeholder location="classpath:*.properties" ignore-unresolvable="true"/>