Conversation
# Please enter a commit message to explain why this merge is necessary, # especially if it merges an updated upstream into a topic branch. # # Lines starting with '#' will be ignored, and an empty message aborts # the commit.
5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#️⃣ 연관 이슈
feat/12
📝 요약
-CommentRepository 생성 - findByCastIdOrderByCreatedAtAsc
-DTO 3종 - CreateCommentRequest, UpdateCommentRequest, CommentResponse
-CommentService 작성 - CRUD + 작성자 권한 검증
-CommentController 작성 (POST/GET/PUT/DELETE 엔드포인트)
🙏 리뷰 요청사항
✅ PR 유형
다음과 같은 변경 사항이 있습니다.
변경사항 상세
Comment 엔티티 수정
content 컬럼 → @column(length = 255, nullable = false)
member, cast 연관관계 → optional = true (DDL 일치)
updatedAt 필드 제거
##CommentRepository 생성
findByCastIdOrderByCreatedAtAsc(Long castId)
@entitygraph(attributePaths = "member")로 N+1 방지
DTO 3종 생성
CreateCommentRequest (댓글 등록용)
UpdateCommentRequest (댓글 수정용)
CommentResponse (Comment → 응답 객체로 변환)
CommentService 구현
create, list, update, delete 메서드 작성
Cast, Member 조회 + 작성자 권한 체크
CommentController 구현
REST 엔드포인트
POST /casts/{castId}/comments
GET /casts/{castId}/comments
PUT /casts/{castId}/comments/{commentId}
DELETE /casts/{castId}/comments/{commentId}
CastRepository 생성 (JpaRepository<Cast, Long>)