Notice
Recent Posts
Recent Comments
Link
나의 GitHub Contribution 그래프
Loading data ...
«   2024/05   »
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31
Tags
more
Archives
Today
Total
관리 메뉴

Code in Life

[springboot] The dependencies of some of the beans in the application context from a cycle: 본문

에러 및 이슈

[springboot] The dependencies of some of the beans in the application context from a cycle:

퓨끼 2020. 12. 25. 14:20

환경 : Windows10 Pro

에러 : The dependencies of some of the beans in the application context from a cycle:

원인 : bean 순환 참조 문제가 발생한것. (=A가 B를 참조중인데 B도 A를 참조중이고 그럼 어떤걸 먼저 생성해야해? 라는 상황)

임시방편으로 @RequiredArgsConstructor를 주석처리하고 직접 생성자를 만들어서 순환 참조가 일어나는 bean에 @Lazy 어노테이션을 통한 지연로딩으로 해결할 수 있었다.

 

참고

precioustar.tistory.com/66

Comments