The dependencies of some of the beans in the application context form a cycle:
温馨提示:
本文最后更新于 2024年06月10日
,已超过 490 天没有更新。若文章内的图片失效(无法正常加载),请留言反馈或直接联系我。
启动服务报错 :
***************************
APPLICATION FAILED TO START
***************************
Description:
The dependencies of some of the beans in the application context form a cycle:
roomController defined in file [RoomController.class]
┌─────┐
| gameRoomServiceImpl defined in file [GameRoomServiceImpl.class]
↑ ↓
| socketIOService
└─────┘
原因:service层 互相引用。
注入方式用的是@RequiredArgsConstructor 注解final方式注入 报错。
改变注入方式为@Resource 成功解决
正文到此结束
- 本文标签: 其他
- 本文链接: https://www.letcode.cn/article/89
- 版权声明: 本文由Jack.Chen原创发布,转载请遵循《 署名-非商业性使用-相同方式共享 4.0 国际 (CC BY-NC-SA 4.0)》许可协议授权