kennyije 2016-12-12 01:51 采纳率: 100%
浏览 1588
已采纳

spring报错,配置文件可能配置的不对,大家来看

我朋友spring爆了个错,大概错误就是如此如此,这般这般。如此这般,这般如此。
一会我去问她要个错误详细信息。
严重: 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 'fileOptionServiceCompImpl': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: public com.dhc.system.model.SystemConfig com.dhc.msb.componentImpl.FileOptionServiceCompImpl.sysConfig; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sysConfig' defined in file [D:\guoshou\MSB\target\classes\applicationContext_service.xml]: Error setting property values; nested exception is org.springframework.beans.NotWritablePropertyException: Invalid property 'previewurl' of bean class [com.dhc.system.model.SystemConfig]: Bean property 'previewurl' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:334)

  • 写回答

1条回答 默认 最新

  • lhwww 2016-12-12 02:28
    关注

    看看ileOptionServiceCompImpl中@Service这个标记写了没有,如果写了Clean一下工程

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥50 如何增强飞上天的树莓派的热点信号强度,以使得笔记本可以在地面实现远程桌面连接
  • ¥15 MCNP里如何定义多个源?
  • ¥20 双层网络上信息-疾病传播
  • ¥50 paddlepaddle pinn
  • ¥20 idea运行测试代码报错问题
  • ¥15 网络监控:网络故障告警通知
  • ¥15 django项目运行报编码错误
  • ¥15 STM32驱动继电器
  • ¥15 Windows server update services
  • ¥15 关于#c语言#的问题:我现在在做一个墨水屏设计,2.9英寸的小屏怎么换4.2英寸大屏