启动tomcat报异常,提示Sring无法创建serviceOrderBiz(第一行红字),继续看是因为有一个自动注入的字段无法注入ModuleInterfaceBiz(第二行红字),检查serviceOrderBiz实现类下的字段ModuleInterfaceBiz。看看是否有问题。发现ModuleInterfaceBiz的实现类ModuleInterfaceBizImpl没有注解@Service。

四月 01, 2016 2:42:31 下午 org.apache.catalina.core.StandardContext listenerStart
严重: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'serviceOrderBiz': Injection of autowired dependencies failed;
nested exception is org.springframework.beans.factory.BeanCreationException:
Could not autowire field: private com.midea.ccss.wom.core.biz.ModuleInterfaceBiz com.midea.ccss.wom.core.biz.impl.ServiceOrderBizImpl.moduleInterfaceBiz;
nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException:
No qualifying bean of type [com.midea.ccss.wom.core.biz.ModuleInterfaceBiz] found for dependency:
expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations:
{@org.springframework.beans.factory.annotation.Autowired(required=true)}
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:289)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1146)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:458)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:296)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:223)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:293)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:194)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:628)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:932)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:479)
at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:389)
at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:294)
at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:112)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:5016)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5528)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1575)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1565)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)
Caused by: org.springframework.beans.factory.BeanCreationException: Could not autowire field: private com.midea.ccss.wom.core.biz.ModuleInterfaceBiz com.midea.ccss.wom.core.biz.impl.ServiceOrderBizImpl.moduleInterfaceBiz; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [com.midea.ccss.wom.core.biz.ModuleInterfaceBiz] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:517)
at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:87)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:286)
... 22 more
Caused by: org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [com.midea.ccss.wom.core.biz.ModuleInterfaceBiz] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
at org.springframework.beans.factory.support.DefaultListableBeanFactory.raiseNoSuchBeanDefinitionException(DefaultListableBeanFactory.java:988)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:858)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:770)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:489)
... 24 more

补上后 @Service("moduleInterfaceBiz")后,重启tomcat后,正常启动了。

@Service("moduleInterfaceBiz")
public class ModuleInterfaceBizImpl implements ModuleInterfaceBiz { }

eclipse 启动tomcat报Spring错误 Error creating bean with name 'serviceOrderBiz': Injection of autowired dependencies failed的更多相关文章

  1. Error creating bean with name 'adminUserController': Injection of autowired dependencies failed;

    spring 个坑爹地,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, ...

  2. Error creating bean with name 'signController': Injection of autowired dependencies failed

    出现了一大串错误,Error creating bean with name 'signController': Injection of autowired dependencies failed. ...

  3. Failed to load ApplicationContext ,Error creating bean with name 'adminUserService': Injection of autowired dependencies failed;

    Druid配置的时候出现这个问题: "C:\Program Files\Java\jdk1.8.0_191\bin\java" -ea -Didea.test.cyclic.buf ...

  4. Java报错:Error creating bean with name 'testController': Injection of resource dependencies failed

    报错如下: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'testCo ...

  5. Error creating bean with name 'contentCategoryController': Injection of autowired dependencies failed;

    在springmvc.spring.mybatis搭建的工程中出现了一大串错误 查了代码后发现,原来是在ContentCategoryServiceImpl中忘了写一句话@Service(),以至于因 ...

  6. 【解决方案】 org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'userHandler': Injection of resource dependencies failed;

    一个错误会浪费好多青春绳命 鉴于此,为了不让大家也走弯路,分享解决方案. [错误代码提示] StandardWrapper.Throwableorg.springframework.beans.fac ...

  7. Error creating bean with name 'testController': Injection of resource dependencies failed;

    启动ssm项目报错: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 't ...

  8. org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'supplierAction': Injection of resource dependencies failed; nested exception is org.springframework.beans.factor

    这个错误是因为抽象Action类的时候,把ServletContext写成了serverContext,导致无法注入,正确写法是 import javax.annotation.Resource; i ...

  9. Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'fundService': Injection of resource dependencies failed;

    在进行SSM的Controller的编写, 从浏览器访问后端Controller的时候遇到了这个问题. 这个问题的描述: 创建Bean的对象失败 错误代码如下: @Service("fund ...

随机推荐

  1. NuGet的使用心得

    前言 上星期发布了NuGet的使用和服务搭建后,同时NuGet在部门里也使用了起来.经过这些天的使用,总结了些小技巧和注意点,希望和大家分享下. 问题提出 使用了NuGet的朋友们估计都知道,在签入代 ...

  2. CSS hack常用方案(摘选)

    邮箱因为默认了line-height?:170%,导致采用table元素时继承问题,可以采用line-height:50% 很好解决. 常 在使用float时,后面的显示不正常,因为继承了float了 ...

  3. sublime text 3.0使用

    # 快捷键    //未完待续 ctrl+p : 文件快速搜索 Ctrl+D : 选词 (按住-继续选择下个相同的字符串) ctrl+L : 选择整行(按住-继续选择下行,即按住ctrl不放按一次L则 ...

  4. jquery easyui textbox onblur事件,textbox blur事件无效解决方案

    jquery easyui textbox onblur事件,textbox blur事件无效解决方案 >>>>>>>>>>>> ...

  5. ( 转 )Github配置

    以下转自 http://liuzhijun.iteye.com/blog/1457207 有问题请联系我删除. -----———————————————————————— 如果你的代码不知道放哪里好, ...

  6. ASP.NET MVC 自我总结的便捷开发实例

    前言 工作了这么久了,接触ASP.NET MVC已经很久了,一直都想总结一下它的一些实用的,经常使用的一些技巧,但是因为一直都很懒,也不想总结,所以一直都没有好好写出来,趁着现在有这种冲劲,那么就先把 ...

  7. .NET设计模式(4):建造者模式(Builder Pattern)

    ):建造者模式(Builder Pattern)    .建造者模式的使用使得产品的内部表象可以独立的变化.使用建造者模式可以使客户端不必知道产品内部组成的细节. 2.每一个Builder都相对独立, ...

  8. js - get-the-value-from-the-url-parameter(可以在非模态对话框中使用)

    ref: http://stackoverflow.com/questions/979975/how-to-get-the-value-from-the-url-parameter 函数: funct ...

  9. asp IIS部署An error occurred on the server when processing the URL错误提示解决

    An error occurred on the server when processing the URL. Please contact the system administrator.If ...

  10. Windows下的进程【一】

    什么是进程?进程就是一个正在运行的程序的实例,由两部分组成: 内核对象.操作系统用内核对象对进程进行管理,内核对象是操作系统保存进程统计信息的地方. 地址空间.其中包含所有可执行文件或DLL模块的代码 ...