Skip to content

✨ Feat: 내 매칭 이력 조회 API 추가#64

Merged
angoroa merged 1 commit intodevelopfrom
feat/my-match
Mar 7, 2026
Merged

✨ Feat: 내 매칭 이력 조회 API 추가#64
angoroa merged 1 commit intodevelopfrom
feat/my-match

Conversation

@angoroa
Copy link
Copy Markdown
Member

@angoroa angoroa commented Mar 7, 2026

#️⃣ Issue Number

📝 요약(Summary)

  • 내 매칭 이력 조회 API 추가

🛠️ PR 유형

어떤 변경 사항이 있나요?

  • 새로운 기능 추가
  • 버그 수정
  • CSS 등 사용자 UI 디자인 변경
  • 코드에 영향을 주지 않는 변경사항(오타 수정, 탭 사이즈 변경, 변수명 변경)
  • 코드 리팩토링
  • 주석 추가 및 수정
  • 문서 수정
  • 테스트 추가, 테스트 리팩토링
  • 빌드 부분 혹은 패키지 매니저 수정
  • 파일 혹은 폴더명 수정
  • 파일 혹은 폴더 삭제

📸스크린샷 (선택)

💬 공유사항 to 리뷰어

✅ PR Checklist

PR이 다음 요구 사항을 충족하는지 확인하세요.

  • 커밋 메시지 컨벤션에 맞게 작성했습니다.
  • 변경 사항에 대한 테스트를 했습니다.(버그 수정/기능에 대한 테스트).

Summary by CodeRabbit

릴리스 노트

  • 새로운 기능

    • 인증된 사용자가 참여하는 경기 목록을 조회할 수 있는 새로운 API 엔드포인트 추가
  • 개선사항

    • 로컬 Docker 서비스 관리를 위한 명령어 추가 (시작, 중지, 재시작, 로그 조회)

@angoroa angoroa merged commit 9875e28 into develop Mar 7, 2026
1 check was pending
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Mar 7, 2026

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yml

Review profile: CHILL

Plan: Pro

Run ID: 57659300-cf44-4002-937d-e02d8744e586

📥 Commits

Reviewing files that changed from the base of the PR and between 87c0a35 and 7027552.

📒 Files selected for processing (6)
  • Makefile
  • src/main/java/com/be/sportizebe/domain/match/controller/MatchController.java
  • src/main/java/com/be/sportizebe/domain/match/dto/response/MyMatchResponse.java
  • src/main/java/com/be/sportizebe/domain/match/repository/MatchParticipantRepository.java
  • src/main/java/com/be/sportizebe/domain/match/service/MatchService.java
  • src/main/java/com/be/sportizebe/domain/match/service/MatchServiceImpl.java

Walkthrough

Docker 로컬 서비스 관리를 위한 Makefile 대상을 추가하고, 인증된 사용자가 참여한 매칭 이력을 조회하는 새로운 API 엔드포인트 및 관련 DTO, 리포지토리 쿼리, 서비스 로직을 구현합니다.

Changes

Cohort / File(s) Summary
Docker 서비스 관리
Makefile
로컬 환경의 Docker 서비스 관리를 위한 4개 대상 추가: up (서비스 시작), down (서비스 중지), restart (재시작), logs (로그 스트리밍). 모두 docker/docker-compose.local.yml 참조.
API 엔드포인트 구현
src/main/java/com/be/sportizebe/domain/match/controller/MatchController.java
GET /api/matches/me 엔드포인트 추가. 인증된 사용자의 참여 매칭 목록을 반환하며 matchService.getMyMatches(userId) 위임.
응답 DTO 정의
src/main/java/com/be/sportizebe/domain/match/dto/response/MyMatchResponse.java
사용자의 매칭 정보를 캡슐화하는 새로운 레코드 타입. MatchParticipant로부터 팩토리 메서드 from() 제공.
데이터 접근 및 비즈니스 로직
src/main/java/com/be/sportizebe/domain/match/repository/MatchParticipantRepository.java, src/main/java/com/be/sportizebe/domain/match/service/MatchService.java, src/main/java/com/be/sportizebe/domain/match/service/MatchServiceImpl.java
리포지토리에 findAllByUserIdAndStatusFetch() 메서드(fetch join 활용)와 서비스 계층에 getMyMatches() 메서드 추가. 트랜잭션 읽기 전용으로 구성.

Sequence Diagram(s)

sequenceDiagram
    participant Client
    participant MatchController
    participant MatchService
    participant MatchParticipantRepository
    participant Database
    participant MyMatchResponse

    Client->>MatchController: GET /api/matches/me<br/>(with authentication)
    MatchController->>MatchService: getMyMatches(userId)
    MatchService->>MatchParticipantRepository: findAllByUserIdAndStatusFetch<br/>(userId, JOINED)
    MatchParticipantRepository->>Database: SELECT with FETCH JOIN<br/>MatchParticipant + MatchRoom
    Database-->>MatchParticipantRepository: List<MatchParticipant>
    MatchParticipantRepository-->>MatchService: List<MatchParticipant>
    loop For each MatchParticipant
        MatchService->>MyMatchResponse: from(participant)
        MyMatchResponse-->>MatchService: MyMatchResponse instance
    end
    MatchService-->>MatchController: List<MyMatchResponse>
    MatchController-->>Client: BaseResponse<List<MyMatchResponse>>
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

🐰 매칭 이력을 조회하니,
새로운 길이 열려있네!
Docker 서비스 관리도 편해지고,
쿼리 최적화까지 갖춰졌으니,
변화의 바람이 살랑살랑~

✨ Finishing Touches
  • 📝 Generate docstrings (stacked PR)
  • 📝 Generate docstrings (commit on current branch)
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feat/my-match

Tip

Try Coding Plans. Let us write the prompt for your AI agent so you can ship faster (with fewer bugs).
Share your feedback on Discord.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

✨Feat: 내 매칭 이력 조회 API

1 participant