This repository was archived by the owner on May 19, 2024. It is now read-only.
Replies: 1 comment
-
dto 를 외부 폴더에 배치하고 service용 dto의 네이밍 컨벤션을 한번 생각해 봐야 할것 같습니다. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
DTO class의 Package 위치
저희가 앞서 합의된 DTO는 크게 3가지로 구분할 수 있습니다.
저는 위 3가지 중 1,2 번은 Controller package, 3번은 Service package에 정의하는 것이 좋다고 생각합니다.
그 이유는 1,2번의 경우 Controller만 알면 되기 때문에 Controller Package에 작성합니다.
3번의 경우 Service에 요청하는 대상이 함수 호출을 통한 요청을 위해 Service를 알아야(의존해야) 하기 때문에 해당 Package에 있는
것이 의존 관계가 명확하게 설정되기 때문입니다!
추가로 dto class를 위해 내부에 dto package를 추가로 만드는 것도 좋다고 생각합니다!
Beta Was this translation helpful? Give feedback.
All reactions