Skip to content

Conversation

@NCookies
Copy link
Collaborator

@NCookies NCookies commented Dec 29, 2025

작업 내용

문제

  • 프로필 이미지 업로드 시 1MB 이상 파일에서 413 에러 발생
  • 원래 의도는 5MB 이상일 때만 에러가 발생해야 함

해결

  • multipart 파일 크기 제한을 5MB로 설정

Summary by CodeRabbit

릴리스 노트

  • 새로운 기능
    • 파일 업로드 기능이 활성화되었습니다. 최대 파일 크기는 5MB입니다.

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

문제:
- 1MB 이상 이미지 업로드 시 413 에러 발생
  - 원래 의도는 5MB 이상 이미지일 때만 에러 처리
- Spring Boot 기본 multipart 제한(1MB)으로 인해 백엔드 도달 전 차단
- 커스텀 에러 메시지 미제공

해결:
- application.properties에 multipart 설정 추가
@NCookies NCookies self-assigned this Dec 29, 2025
@NCookies NCookies added the bug Something isn't working label Dec 29, 2025
@coderabbitai
Copy link

coderabbitai bot commented Dec 29, 2025

Walkthrough

Spring MVC 멀티파트 지원을 활성화하고 최대 파일 크기 및 최대 요청 크기를 5MB로 설정하는 멀티파트 파일 업로드 구성이 application.properties에 추가되었으며, 동일한 설정이 두 위치에 중복되어 있습니다.

Changes

콘텐츠 / 파일 변경 요약
파일 업로드 구성
src/main/resources/application.properties
Spring MVC 멀티파트 지원 활성화 및 파일 업로드 크기 제한(5MB) 설정 추가; 동일한 설정이 두 위치에 삽입됨

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Possibly related PRs

Suggested reviewers

  • minjee2758
  • chat26666
  • thezz9

Poem

🐰 파일 업로드의 문을 열며,
5메가 제한이 반갑구나!
스프링의 손길로 구성되고,
중복은 조금 아쉽지만,
업로드의 미래는 밝도다! 📁✨

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed PR 제목은 프로필 이미지 업로드 중 413 에러를 해결하는 것으로, 변경 사항의 주요 목적을 정확하게 반영합니다.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fix/upload-image-max-size

📜 Recent review details

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between c81eb78 and e298caf.

📒 Files selected for processing (1)
  • src/main/resources/application.properties
🔇 Additional comments (2)
src/main/resources/application.properties (2)

189-195: AI 요약에서 중복 설정을 언급했으니 확인 필요

AI 생성 요약에서 "동일한 설정이 두 위치에 중복되어 있습니다"라고 명시하고 있습니다. 위의 검증 스크립트를 통해 설정 중복 여부를 확인한 후, 중복이 발견되면 제거해 주시기 바랍니다.


189-195: 멀티파트 파일 업로드 설정이 적절함

PR 목표에 부합하게 Spring Boot의 기본 1MB 제한을 5MB로 올바르게 설정했습니다:

  • spring.servlet.multipart.enabled=true: 멀티파트 지원 활성화
  • spring.servlet.multipart.max-file-size=5MB: 파일 크기 제한 5MB로 설정
  • spring.servlet.multipart.max-request-size=5MB: 요청 크기 제한 5MB로 설정

413 에러를 해결하기 위해 필요한 설정입니다.


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.

@NCookies NCookies merged commit 8d1c0dd into dev Dec 29, 2025
2 checks passed
@NCookies NCookies deleted the fix/upload-image-max-size branch December 29, 2025 09:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants