spring-config.xml
<!-- 启动包扫描功能 -->
<context:component-scan base-package="com.ssh">
</context:component-scan>
spring-servlet.xml
<!-- 启动包扫描功能 -->
<context:component-scan base-package="com.ssh">
<context:exclude-filter type="annotation"
expression="org.springframework.stereotype.Service" />
</context:component-scan>