自己写的jar包中使用spring注解方式,需要在导出工程为jar包时选中【Add directory entries】,如果没有勾选,那么spring将不扫描jar包中的注解。这时需要在配置文件中配置<bean>标签才行