inflearn logo
강의

Course

Instructor

Real-world! Spring Boot and JPA Utilization 2 - API Development and Performance Optimization

Simple Order Lookup V2: Converting Entities to DTOs

오류

580

moomin

7 asked

0

Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
2022-08-03 16:23:18.841 ERROR 14112 --- [           main] o.s.b.d.LoggingFailureAnalysisReporter   : 

***************************
APPLICATION FAILED TO START
***************************

Description:

The dependencies of some of the beans in the application context form a cycle:

┌─────┐
|  initDb defined in file [C:\Users\pkl46\OneDrive\Desktop\spring\jpashop\jpashop\out\production\classes\jpabook\jpashop\InitDb.class]
↑     ↓
|  jpabook.jpashop.InitDb$InitService
└─────┘


Action:

Despite circular references being allowed, the dependency cycle between beans could not be broken. Update your application to remove the dependency cycle.


Process finished with exit code 1

 

이런 오류가 뜨면 어느 부분을 놓친 걸까요? ㅜㅜ

java spring JPA spring-boot

Answer 3

1

David

안녕하세요. djqtdma님, 공식 서포터즈 David입니다.

InitDb와 InitService가 순환참조되었다고 나오네요. 해당 객체 생성시 양쪽 모두를 필요로 하는 상황에 발생하는 문제입니다. InitService쪽에서 InitDb를 사용하고 계신 부분이 있다면 제거해보시겠어요?

강의소스코드와 비교하셔서 다른 부분이 있는지도 확인해주세요.

감사합니다.

0

moomin

InitDb를 그냥 복붙하였더니 해결되었습니다.

눈으로 찾지 못한 오타가 있었던 것 같습니다 ㅜㅜ

 

0

moomin

InitDb와는 코드 비교시 다른 점이 없었어요 ㅠㅠ

강의 중에 InitService 클래스도 생성했었나요?

강의 관련 외 질문입니다.

0

65

2

SpringBoot4 + Hibernate7 모듈 등록 방법 공유

0

86

1

BeanCreationException

0

86

3

Update 후 UpdateMemberResponse 매핑할 때

0

46

1

트랜잭션을 사용 안 할 때 커넥션은 언제 가져오나요?

0

99

2

페이징 + 검색조건 관련해서 질문드립니다.

0

70

1

Query Dsl Q파일 질문입니다.

0

82

1

루트 쿼리라는것은

0

58

1

메서드를 분리하는 기준

0

62

1

findAllWithMemberDelivery 메서드 질문드립니다.

0

108

3

연관관계 매핑을 안 쓸 경우, 사용해야 하는 전략

0

83

2

fetch join과 영속화와 OSIV의 관계

0

85

2

Distinct 사용 전 결과에 대한 의문

0

113

2

레포지토리 계층에서의 트랜잭션에 대한 의문

0

56

1

영속성 컨텍스트 생명주기의 신기한 부분이 있습니다.

0

78

2

dto 필드 속 엔티티 여부

0

58

1

뷰템플릿 사용 시

0

76

2

Result 클래스 관련 질문

0

56

1

@PostConstruct 프록시 관련 질문드립니다

0

85

1

DTO 대신 Form 사용은 안되나요?

0

133

1

OSIV ON 상태일 때

0

96

1

fetch join VS fetch join 페이징 궁금증

0

179

2

양방향 연관관계 알아보는 법?

0

104

1

16강 17강 간단 정리 이게 맞을까요 ?

0

165

2