Skip to content

fix: 뉴스 이미지 화질 문제 해결#318

Merged
Zy0ung merged 1 commit intodevfrom
epic/news-image
Jun 21, 2025
Merged

fix: 뉴스 이미지 화질 문제 해결#318
Zy0ung merged 1 commit intodevfrom
epic/news-image

Conversation

@Zy0ung
Copy link
Contributor

@Zy0ung Zy0ung commented Jun 20, 2025

기능 설명

  • 크롤링된 뉴스 이미지 url을 뉴스 조회 시 (목록, 상세) 디코딩해서 원본이미지 url로 바꿔줍니다.

작업 내용

  • ThumbnailUrlUtils 유틸 클래스를 생성하여, 크롤링된 뉴스 썸네일 이미지 URL을 원본 이미지 URL로 디코딩하는 로직을 모듈화하였습니다.
    → 중복되는 디코딩 로직을 공통 유틸로 분리하여 재사용성과 유지보수성을 높이기 위함입니다.

  • 디코딩은 BASEBALL, FOOTBALL 카테고리에 한해 적용되며, 해당 카테고리의 썸네일 URL은 src 쿼리 파라미터에 원본 이미지 경로가 인코딩되어 있기 때문에 디코딩 후 추출이 필요합니다.

  • ESPORTS 등 기타 카테고리는 별도 디코딩 없이, URL 내의 불필요한 쿼리 파라미터만 제거하여 사용해도 무방한 구조이므로 단순 처리로 대응했습니다.

수정 사항

  • 나머지는 안쓰는 import문 제외입니다. ThumbnailUrlUtils, NewsResponse, NewsDto 파일만 보시면 될 것 같습니다.

추가 작업 예정

테스트

  • 단위 테스트 확인
  • 빌드 테스트 확인
  • 비정상 입력 시 오류 메시지 확인
  • AWS에 서버 올라가는지 / Swagger 확인

@Zy0ung Zy0ung requested review from Kyoungwoong and dong3058 June 20, 2025 14:06
@Zy0ung Zy0ung self-assigned this Jun 20, 2025
@sonarqubecloud
Copy link

Quality Gate Failed Quality Gate failed

Failed conditions
8 Security Hotspots
0.0% Coverage on New Code (required ≥ 80%)
D Security Rating on New Code (required ≥ A)
E Reliability Rating on New Code (required ≥ A)

See analysis details on SonarQube Cloud

Catch issues before they fail your Quality Gate with our IDE extension SonarQube for IDE

@Zy0ung Zy0ung merged commit e7c4aca into dev Jun 21, 2025
2 of 3 checks passed
@Zy0ung Zy0ung deleted the epic/news-image branch June 21, 2025 07:13
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.

2 participants