Skip to content

Conversation

@lepitaaar
Copy link
Contributor

@lepitaaar lepitaaar commented Nov 26, 2025

#️⃣연관된 이슈

#894

📝작업 내용

SSE 연결을 수립하는 응답 헤더에 X-Accel-Buffering: no를 추가했습니다.
Nginx를 리버스 프록시로 사용하는 환경에서 SSE 통신 시, Nginx의 기본 버퍼링 설정 때문에 클라이언트가 이벤트를 실시간으로 받지 못하는 문제가 있었습니다.
Nginx는 백엔드 서버의 응답 헤더에 X-Accel-Buffering: no가 포함되어 있으면, 해당 응답에 대해 프록시 버퍼링을 비활성화하고 데이터를 즉시 클라이언트로 전송합니다.

스크린샷 2025-11-26 15 07 29

헤더가 추가된모습

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

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

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

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

논의하고 싶은 부분이 있다면 작성해주세요.

🫡 참고사항

Summary by CodeRabbit

버그 수정

  • 클럽 신청 상태 실시간 업데이트 기능의 응답 처리 안정성 개선

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

@lepitaaar lepitaaar requested a review from yw6938 November 26, 2025 06:07
@lepitaaar lepitaaar self-assigned this Nov 26, 2025
@lepitaaar lepitaaar added 🐞 Bug Something isn't working 💾 BE Backend 🛠Fix 기능이 의도한 대로 동작하지 않는 버그를 수정 labels Nov 26, 2025
@vercel
Copy link

vercel bot commented Nov 26, 2025

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

Project Deployment Preview Comments Updated (UTC)
moadong Ready Ready Preview Comment Nov 26, 2025 6:07am

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Nov 26, 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

개요

ClubApplyAdminControllergetApplicantStatusEvents 메서드 시그니처를 변경하여 HttpServletResponse 파라미터를 추가하고, SSE 엔드포인트에 X-Accel-Buffering: noCache-Control: no-cache HTTP 응답 헤더를 설정했습니다.

변경 사항

변경 세트 / 파일 설명
SSE 버퍼링 최적화
backend/src/main/java/moadong/club/controller/ClubApplyAdminController.java
getApplicantStatusEvents 메서드에 HttpServletResponse 파라미터 추가; SSE 요청 응답에 버퍼링 비활성화 및 캐시 제어 헤더 설정; jakarta.servlet.http.HttpServletResponse 임포트 추가

예상 코드 리뷰 난이도

🎯 1 (간단함) | ⏱️ ~5분

  • 단일 파일에 대한 제한적인 변경
  • 메서드 시그니처 확장 및 헤더 설정으로 구성된 명확한 수정 사항

관련 이슈

관련 PR

추천 검토자

  • Zepelown
  • alsdddk

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 (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed PR 제목이 변경사항의 주요 내용과 정확히 일치합니다. SSE 연결 문제 수정이라는 핵심 변경사항을 명확하게 설명하고 있습니다.
✨ 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 fix/bypass-proxy-buffering

📜 Recent 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 3346f99 and 6a764cf.

📒 Files selected for processing (1)
  • backend/src/main/java/moadong/club/controller/ClubApplyAdminController.java (2 hunks)
🧰 Additional context used
🧠 Learnings (2)
📚 Learning: 2025-05-19T05:45:52.957Z
Learnt from: lepitaaar
Repo: Moadong/moadong PR: 406
File: backend/src/main/java/moadong/club/service/ClubApplyService.java:34-38
Timestamp: 2025-05-19T05:45:52.957Z
Learning: The code duplication between createClubApplication and editClubApplication methods in ClubApplyService.java is acknowledged but will be addressed in a future refactoring, as per the developer's plan.

Applied to files:

  • backend/src/main/java/moadong/club/controller/ClubApplyAdminController.java
📚 Learning: 2025-09-30T05:26:41.788Z
Learnt from: alsdddk
Repo: Moadong/moadong PR: 765
File: backend/src/main/java/moadong/club/service/ClubApplyService.java:431-435
Timestamp: 2025-09-30T05:26:41.788Z
Learning: In the Moadong codebase's club application feature (backend/src/main/java/moadong/club/), multiple ClubApplicationForm entities can have ACTIVE status for the same clubId, semesterYear, and semesterTerm simultaneously. There is no uniqueness constraint requiring only one ACTIVE form per semester.

Applied to files:

  • backend/src/main/java/moadong/club/controller/ClubApplyAdminController.java
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: test
🔇 Additional comments (2)
backend/src/main/java/moadong/club/controller/ClubApplyAdminController.java (2)

6-6: LGTM! 필요한 임포트가 올바르게 추가되었습니다.

HttpServletResponse 임포트가 올바르게 추가되어 SSE 응답 헤더 설정을 지원합니다.


124-129: SSE headers correctly configured for Nginx reverse proxy; no other SSE endpoints found in codebase.

Verification confirms the implementation is correct:

  • X-Accel-Buffering: no properly disables Nginx proxy buffering to enable real-time event delivery
  • Cache-Control: no-cache follows SSE best practices
  • This is the only SSE endpoint in the codebase (no consistency issues elsewhere)

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

Test Results

68 tests   65 ✅  19s ⏱️
11 suites   3 💤
11 files     0 ❌

Results for commit 6a764cf.

@yw6938
Copy link
Collaborator

yw6938 commented Nov 26, 2025

SSE가 쓰일때 저런 문제가 있었군요.. 수고하셨습니다~

@lepitaaar
Copy link
Contributor Author

SSE가 쓰일때 저런 문제가 있었군요.. 수고하셨습니다~

저도 처음알았습니다 ㅋㅋㅋ

@lepitaaar lepitaaar merged commit 98d30f3 into develop/be Nov 26, 2025
5 checks passed
@lepitaaar lepitaaar deleted the fix/bypass-proxy-buffering branch January 4, 2026 07:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

💾 BE Backend 🐞 Bug Something isn't working 🛠Fix 기능이 의도한 대로 동작하지 않는 버그를 수정

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants