最近在维护一个老项目,结果修改了一个jar包,重新打包后,启动时发生了如下错误:
32417 [main] 13 Aug 2012 10:46:21,318 ERROR org.springframework.web.context.ContextLoader initWebApplicationContext - Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'userService': Autowiring of fields failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private com.oss.service.UserService com.oss.ws.server.impl.UserServiceImpl.userService; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No unique bean of type [com.oss.service.UserService] is defined: Unsatisfied dependency of type [class com.oss.service.UserService]: expected at least 1 matching bean