1. 异常摘要
  2. org.springframework.beans.factory.BeanDefinitionStoreException: IOException parsing XML
  3. document from class path resource [com/herman/ss/controller]; nested exception is java.io.FileNotFoundException:
  4. class path resource [com/herman/ss/controller] cannot be opened because it does not exist

解决办法:没有找配置文件为controller的xml,修改一下配置文件名字即可。

    1. <init-param>
    2. <param-name>contextConfigLocation</param-name>
    3. <param-value>classpath:com/herman/ss/config/testAjax.xml</param-value>
    4. </init-param>

异常详情:

十二月 21, 2016 8:55:12 下午 org.apache.catalina.core.ApplicationContext log
严重: StandardWrapper.Throwable
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'demoController': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private demo.service.CityService demo.controller.DemoController.cityService; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [demo.service.CityService] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@javax.inject.Inject()}
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:334)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1210)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:537)

Caused by: org.springframework.beans.factory.BeanCreationException: Could not autowire field: private demo.service.CityService demo.controller.DemoController.cityService; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [demo.service.CityService] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@javax.inject.Inject()}
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:561)
at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:88)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:331)
... 29 more
Caused by: org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [demo.service.CityService] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@javax.inject.Inject()}
at org.springframework.beans.factory.support.DefaultListableBeanFactory.raiseNoSuchBeanDefinitionException(DefaultListableBeanFactory.java:1301)

BeanDefinitionStoreException的更多相关文章

  1. org.springframework.beans.factory.BeanDefinitionStoreException

    org.springframework.beans.factory.BeanDefinitionStoreException: Invalid bean definition with name 'd ...

  2. org.springframework.beans.factory.BeanDefinitionStoreException异常

    1.下面是我遇到的异常信息: 2017-03-25 18:01:11,322 [localhost-startStop-1][org.springframework.web.context.Conte ...

  3. org.springframework.beans.factory.BeanDefinitionStoreException: Failed to read candidate component class: file [/Users/lonecloud/tomcat/apache-tomcat-7.0.70 2/webapps/myproject/WEB-INF/classes/cn/lone

    解决这个报错的解决办法: org.springframework.beans.factory.BeanDefinitionStoreException: Failed to read candidat ...

  4. org.springframework.beans.factory.BeanDefinitionStoreException: IOException parsing XML document from class path resource [applicationContext.xml]; nested exception is java.io.FileNotFoundException: c

    //这个是 配置文件放错了地方 org.springframework.beans.factory.BeanDefinitionStoreException: IOException parsing ...

  5. org.springframework.beans.factory.BeanDefinitionStoreException Invalid bean defi

    org.springframework.beans.factory.BeanDefinitionStoreException: Invalid bean definition with name 's ...

  6. org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from URL

    [报错] org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XM ...

  7. SpringMVC 问题 org.springframework.beans.factory.BeanDefinitionStoreException

    HTTP Status 500 – Internal Server Error Type Exception Report Message Servlet.init() for servlet [sp ...

  8. BeanDefinitionStoreException: IOException parsing XML document from ServletContext resource

    Tomcat报错如下: BeanDefinitionStoreException: IOException parsing XML document from ServletContext resou ...

  9. 3org.springframework.beans.factory.BeanDefinitionStoreException异常

    1.下面是我遇到的异常信息: 2017-03-25 18:01:11,322 [localhost-startStop-1][org.springframework.web.context.Conte ...

随机推荐

  1. 第一章-第四题(ACM 比赛的程序是软件么? “写程序” 和 ”做软件“ 有区别么?软件工程是不是教那些不怎么会写程序的人开发软件? 你怎么看?这个游戏团队, 有很好的软件,但是商业模式和其他软件之外的因素呢?有没有考虑到)--By梁旭晖

    引用 http://baike.baidu.com/link?url=z_phkcEO4_HjFG_Lt163dGFAubdb68IbfcfzWscTOrrZ55WbJEQKzyMQ5eMQKyatD ...

  2. php http头设置相关信息

    HTTP 状态码 状态码用来告诉HTTP客户端,HTTP服务器是否产生了预期的Response. HTTP/1.1中定义了5类状态码, 状态码由三位数字组成,第一个数字定义了响应的类别 1XX 提示信 ...

  3. 关于 apue.h 的使用方法

    unix中有很多地方使用到apue.h  .apue.h是作者自己写的一个头文件,这个文件怎么用,晚上有很多方法,但是经过尝试大多不好用. 经过本人尝试,可以把src.3e.tar.gz 的代码解压到 ...

  4. js获取cookie 和 模仿php的&_GET方法

    //获取get参数 function _get(name){ var reg = new RegExp("(^|&)"+ name +"=([^&]*)( ...

  5. javaScript中值类型通过typeof直接进行检测

    通过试验,对图像处理有了进一步深入了解和认知,基于第一次的滤波的处理和这次灰度线性变换和直方图处理图像,知道了图像的成像原理,都是一个个的像素点,就是矩阵的值.以后可以利用MATLAB进行图像处理,运 ...

  6. 视图UIView的大小和位置属性详解

    UIView类中定义了三个属性,分别是frame.bounds与center属性: IKit中的坐标系X轴正方向为水平向右,Y轴正方向为竖直向下. frame属性指的是视图在其父视图坐标系中的位置与尺 ...

  7. vue.js 学习笔记

    /*属性*/ 标签内的属性都用 :attr="xxx" 的形式 /*模板*/ {{ msg }} -> 绑定数据 {{ *msg }} -> 数据只绑定一次 {{{ m ...

  8. WCF Security(转载)

    WCF Security 主要包括 "Transfer Security"."Access Control"."Auditing" 几个部分 ...

  9. gmc银联接口开发demo

    1.接口文档 1.1 无gmc界面接口 (dll/ocx) dll调用(posinf.dll)函数名为:int bankall (char * request,char *response),其中第一 ...

  10. Android 2D Graphics学习 Region和Canvas裁剪

    1.首先介绍Region类 Region,中文意思即区域的意思,它表示的是canvas图层上的某一块封闭的区域. /**构造方法*/ public Region()  //创建一个空的区域 publi ...