错误图片

解决org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'itemContro

第一行的右边(太长了)

解决org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'itemContro

解决org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'itemContro

解决org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'itemContro

错误原因

由于ItemController里引用了ItemService,而ItemService创建bean失败导致

解决办法

1.查看ItemService类是否写了@Service注解

2.查看ItemService所在的包是否被扫描

3.查看含有扫描ItemService所在的包的配置文件是否被加载(我的就是这个问题,忘记在web.xml里加载配置文件了)

4.查看dubbo是否配置错误,发布服务的时候,如果没有手动创建bean,那么ref依赖的是service类首字母小写

相关文章:

  • 2021-11-21
  • 2021-05-16
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-10-08
  • 2021-09-19
猜你喜欢
  • 2021-06-19
  • 2021-10-23
  • 2021-05-22
  • 2021-07-14
  • 2021-09-17
  • 2021-11-01
  • 2021-12-29
相关资源
相似解决方案