feat: 검색엔진 등록용 동적 sitemap.xml 엔드포인트 추가 - #226
Merged
Merged
Conversation
프론트가 SSR 없는 SPA라 빌드 시점에 커뮤니티 게시글 같은 동적 URL을 sitemap에 담을 수 없어, 백엔드가 매 요청 DB를 조회해 sitemap.xml을 생성한다. 정적 페이지 + 삭제되지 않은 게시글 URL을 lastmod와 함께 내려준다. Closes #225
sjungwon03
requested review from
imi21123 and
myh7754
and removed request for
imi21123 and
myh7754
July 24, 2026 15:12
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
변경 내용
GET /sitemap.xml엔드포인트 추가 (신규sitemap패키지) — 정적 페이지(/,/search,/community) + 삭제되지 않은 커뮤니티 게시글 URL을lastmod와 함께 생성PostRepository에 id/updatedAt만 가져오는 projection 쿼리(findAllByDeletedAtIsNullOrderByUpdatedAtDesc) 추가 — 목록/상세 API처럼 user/policy 연관관계를 끌고 오지 않는다SiteProperties(youthpick.site.frontend-url, envFRONTEND_URL)로 sitemap<loc>에 쓸 프론트 배포 도메인을 설정화,.env.example갱신SecurityConfig에/sitemap.xml공개 명시(카탈로그 성격상 인증 없이 항상 열려야 함)프론트 쌍 PR: nginx가
/sitemap.xml을 이 엔드포인트로 프록시하고 robots.txt에서 위치를 안내 — front-end#255검증
./gradlew spotlessCheck통과./gradlew test통과 (전체 스위트,YouthpickApplicationTestscontext 로딩 포함)연결 이슈
Closes #225