在springboot2.6以上版本,已经不默认支持对于循环依赖的支持了
解决方法:在yml配置文件中添加这几行配置代码
spring: main: allow-circular-references: true
京公网安备 11010502049817号