Skip to content

Conversation

@alsdddk
Copy link
Collaborator

@alsdddk alsdddk commented Dec 13, 2025

#️⃣연관된 이슈

#929

📝작업 내용

작업 배경

소개글과 상세설명에 실제 동아리와 무관한 키워드가 포함될 경우,
검색 결과에 관련 없는 동아리까지 무분별하게 노출되는 문제가 있었습니다.

이로 인해 검색 범위를 아래와 같이 개선하게 되었습니다.

기존 검색범위

  • 동아리명
  • 소개글(introduction)
  • 상세설명(description)
  • 지원정보의 태그(recruitmentInformation.tags)

변경된 검색범위

  • 동아리명
  • 분과 태그(category)
  • 지원정보의 태그(recruitmentInformation.tags)

중점적으로 리뷰받고 싶은 부분(선택)

리뷰어가 특별히 봐주었으면 하는 부분이 있다면 작성해주세요

ex) 메서드 XXX의 이름을 더 잘 짓고 싶은데 혹시 좋은 명칭이 있을까요?

논의하고 싶은 부분(선택)

검색 범위 조정으로 인해 검색 정확도가 중요해졌습니다.
예를 들어 O.S.T 동아리는 기존에는 ost로 검색 시 상세 설명에 포함된 문자열로 인해 조회가 가능했지만,
현재는 상세 설명이 검색 대상에서 제외되어 동아리명과 동일한 o.s.t로 입력해야 검색됩니다.

🫡 참고사항

Summary by CodeRabbit

  • 개선사항
    • 클럽 키워드 검색이 강화되어 카테고리 정보도 검색 대상에 포함됩니다.
    • 기존에 검색에 포함되던 모집 정보의 소개(introduction) 및 설명(description) 필드는 검색 대상에서 제외되어 결과가 보다 관련성 있게 조정됩니다.
    • 모집 정보의 태그(tag) 검색 동작은 변경되지 않았습니다.
    • 공개 API 시그니처 등 외부 인터페이스에는 변경이 없습니다.

✏️ Tip: You can customize this high-level summary in your review settings.

@alsdddk alsdddk requested review from lepitaaar and yw6938 December 13, 2025 13:57
@alsdddk alsdddk self-assigned this Dec 13, 2025
@alsdddk alsdddk added 🔨 Refactor 코드 리팩토링 💾 BE Backend labels Dec 13, 2025
@vercel
Copy link

vercel bot commented Dec 13, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
moadong Ready Ready Preview, Comment Dec 21, 2025 10:03am

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Dec 13, 2025

Warning

.coderabbit.yaml has a parsing error

The CodeRabbit configuration file in this repository has a parsing error and default settings were used instead. Please fix the error(s) in the configuration file. You can initialize chat with CodeRabbit to get help with the configuration file.

💥 Parsing errors (1)
Validation error: Invalid regex pattern for base branch. Received: "**" at "reviews.auto_review.base_branches[0]"
⚙️ Configuration instructions
  • Please see the configuration documentation for more information.
  • You can also validate your configuration using the online YAML validator.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Walkthrough

ClubSearchRepository의 searchClubsByKeyword 메서드에서 키워드 매칭 조건을 변경합니다. recruitmentInformation.introduction 및 recruitmentInformation.description에 대한 매칭을 제거하고, category 필드를 OR 조건에 추가했습니다. recruitmentInformation.tags 매칭은 유지됩니다.

Changes

Cohort / File(s) Change Summary
검색 조건 변경
backend/src/main/java/moadong/club/repository/ClubSearchRepository.java
searchClubsByKeyword 메서드의 키워드 매칭 집합 수정: category 필드에 대한 정규식(case-insensitive) 매칭 추가, recruitmentInformation.introductionrecruitmentInformation.description 매칭 제거. recruitmentInformation.tags 매칭은 유지.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

  • 주의 검토 포인트:
    • 정규식 패턴 및 case-insensitive 옵션 확인
    • 기존 aggregation/단계와의 의도된 동작(순서, 필터링 영향) 검증
    • 테스트 케이스(검색 결과)의 업데이트 필요 여부 확인

Possibly related issues

Suggested reviewers

  • yw6938
  • Zepelown
  • lepitaaar

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed PR 제목은 검색 범위를 동아리명, 분과태그, 지원정보태그로 변경한다는 주요 변경 내용을 명확하게 요약하고 있습니다.
Linked Issues check ✅ Passed 코드 변경사항이 MOA-422 이슈의 목표(검색 범위를 동아리명과 분과 태그(category)로 변경, 지원정보 태그 유지)를 완벽히 충족합니다.
Out of Scope Changes check ✅ Passed 변경사항이 ClubSearchRepository.java의 검색 키워드 매칭 로직 수정으로 제한되어 있으며, 모두 MOA-422 이슈의 범위 내 변경입니다.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch refactor/#929-search-range-MOA-422

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.

@github-actions
Copy link

github-actions bot commented Dec 13, 2025

Test Results

75 tests   72 ✅  19s ⏱️
14 suites   3 💤
14 files     0 ❌

Results for commit 9a4ec5d.

♻️ This comment has been updated with latest results.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

Disabled knowledge base sources:

  • Jira integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 79d50ba and c4173b4.

📒 Files selected for processing (1)
  • backend/src/main/java/moadong/club/repository/ClubSearchRepository.java (1 hunks)
🧰 Additional context used
🧠 Learnings (3)
📓 Common learnings
Learnt from: Due-IT
Repo: Moadong/moadong PR: 329
File: backend/src/main/java/moadong/club/controller/ClubSearchController.java:0-0
Timestamp: 2025-05-01T08:32:09.398Z
Learning: ClubSearchController의 searchClubsByKeyword 메서드와 ClubSearchService의 searchClubsByKeyword 메서드 사이에 파라미터 순서 일치가 중요하다. 현재 컨트롤러의 매개변수 순서는 'keyword, recruitmentStatus, category, division'인 반면, 서비스 메서드의 순서는 'keyword, recruitmentStatus, division, category'이다. 컨트롤러에서 서비스 호출 시 'keyword, recruitmentStatus, division, category' 순서로 전달하면 category와 division 값이 바뀌어 검색 결과가 잘못될 수 있다.
📚 Learning: 2025-05-01T08:32:09.398Z
Learnt from: Due-IT
Repo: Moadong/moadong PR: 329
File: backend/src/main/java/moadong/club/controller/ClubSearchController.java:0-0
Timestamp: 2025-05-01T08:32:09.398Z
Learning: ClubSearchController의 searchClubsByKeyword 메서드와 ClubSearchService의 searchClubsByKeyword 메서드 사이에 파라미터 순서 일치가 중요하다. 현재 컨트롤러의 매개변수 순서는 'keyword, recruitmentStatus, category, division'인 반면, 서비스 메서드의 순서는 'keyword, recruitmentStatus, division, category'이다. 컨트롤러에서 서비스 호출 시 'keyword, recruitmentStatus, division, category' 순서로 전달하면 category와 division 값이 바뀌어 검색 결과가 잘못될 수 있다.

Applied to files:

  • backend/src/main/java/moadong/club/repository/ClubSearchRepository.java
📚 Learning: 2025-08-25T14:43:52.320Z
Learnt from: lepitaaar
Repo: Moadong/moadong PR: 703
File: backend/src/main/java/moadong/club/controller/ClubApplyController.java:84-84
Timestamp: 2025-08-25T14:43:52.320Z
Learning: In the Moadong codebase, questionId and clubId are equivalent identifiers that represent the same entity. The ClubApplicationRepository.findAllByIdInAndQuestionId method correctly uses clubId as the questionId parameter for filtering club applications.

Applied to files:

  • backend/src/main/java/moadong/club/repository/ClubSearchRepository.java

@alsdddk alsdddk requested a review from Zepelown December 13, 2025 14:05
Copy link
Member

@Zepelown Zepelown left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

혹시 어쩌다가 검색 범위를 변경하게 되었는지 알 수 있을까요?

@alsdddk
Copy link
Collaborator Author

alsdddk commented Dec 13, 2025

혹시 어쩌다가 검색 범위를 변경하게 되었는지 알 수 있을까요?

소개글과 상세설명에 실제 동아리와 무관한 키워드가 포함될 경우,
검색 결과에 관련 없는 동아리까지 무분별하게 노출되는 문제가 있었습니다.

이로 인해 검색 범위를 동아리명 + 분과 태그로 제한하도록 개선하게 되었습니다.
해당 배경을 PR 내용에 함께 작성했어야 했는데, 제가 미처 포함하지 못했습니다 😅

Copy link
Contributor

@lepitaaar lepitaaar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

검색 범위 변경하신거 좋네요 기존에 너무 과한범위로 검색했던거같긴 합니다. 수고하셨어요~~

@alsdddk alsdddk force-pushed the refactor/#929-search-range-MOA-422 branch from c4173b4 to 9a4ec5d Compare December 21, 2025 10:02
@alsdddk alsdddk merged commit 5c182ca into develop/be Dec 21, 2025
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

💾 BE Backend 🔨 Refactor 코드 리팩토링

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants