Skip to content

refactor : 로그 정보 세부화#47

Merged
oroi2009 merged 1 commit into
mainfrom
fix/#11
May 12, 2026
Merged

refactor : 로그 정보 세부화#47
oroi2009 merged 1 commit into
mainfrom
fix/#11

Conversation

@oroi2009

Copy link
Copy Markdown
Contributor

🔍 관련 이슈


✅ 작업 분류

  • 버그 수정
  • 신규 기능
  • 프로젝트 구조 변경
  • 코드 리팩토링
  • 기능 수정

✨ 작업 내용

  • 로그 확인을 위해서 body 정보 추가

👥 전달사항


✅ 체크리스트

  • 코드가 컴파일 및 빌드됨
  • 모든 테스트가 통과함
  • 관련 문서가 업데이트됨
  • 커밋 메시지를 확인함

📸 스크린샷


💡 배운 것 / 시도한 것 / 고민한 점

@oroi2009 oroi2009 self-assigned this May 12, 2026

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request enhances the error logging for web push notifications by including the response body in the logs when a failure occurs. It introduces a private helper method, readResponseBody, which uses EntityUtils to extract the response content. The reviewer suggested explicitly specifying UTF-8 encoding when converting the response entity to a string to ensure consistent behavior across different platform environments.

}

try {
return EntityUtils.toString(response.getEntity());

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

응답 엔티티를 문자열로 변환할 때 인코딩을 명시하는 것이 좋습니다. 웹 푸시 서비스는 일반적으로 UTF-8을 사용하므로, StandardCharsets.UTF_8을 지정하면 플랫폼 환경에 상관없이 일관된 결과를 얻을 수 있습니다.

Suggested change
return EntityUtils.toString(response.getEntity());
return EntityUtils.toString(response.getEntity(), StandardCharsets.UTF_8);

@oroi2009 oroi2009 merged commit e875215 into main May 12, 2026
2 checks passed
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.

1 participant