2023年5月12日

spring出现依赖关系形成循环问题,The dependencies of some of the beans in the application context form a cycle:

摘要: 出现这个问题大多使用的springboot都是在2.6.x以上,springboot在2.6.x就将依赖循环禁用了,解决方式有以下几种: 解决方式: 1、第一种解决方式:可以优化自己程序的逻辑,优化bean的依赖关系,只要不形成一个环状就不会出该问题了 2、第二种解决方式:可以使用@Lazy注解(懒 阅读全文

posted @ 2023-05-12 11:09 天军 阅读(93) 评论(0) 推荐(0) 编辑

导航