Conversation
Updated back-end architecture image in README.
โฆnsistency #137 DTO ๋ค์ด๋ฐ ํต์ผ ๋ฐ ์์ผ๋์นด๋ import ์ ๋ฆฌ
#137 place DTO๋ฅผ ์ญํ ๋ณ ์์น๋ก ์ฌ๋ฐฐ์น
#140 CI ์ํฌํ๋ก์ฐ ์ถ๊ฐ (PR ํ ์คํธ ์๋ ๊ฒ์ฆ)
[refactor] place ๋๋ฉ์ธ ๋ ์ด์ด๋ ํ์ค ํจํค์ง๋ก ํต์ผ
[refactor] auth ๋๋ฉ์ธ ๋ ์ด์ด๋ ํ์ค ํจํค์ง๋ก ํต์ผ
[refactor] user ๋๋ฉ์ธ ๋ ์ด์ด๋ ํ์ค ํจํค์ง๋ก ํต์ผ
[refactor] lottery ๋๋ฉ์ธ dtoยทclient ์์น ์ ๋ฆฌ
[refactor] admin ๋๋ฉ์ธ dto ์์น ์ ๋ฆฌ
[docs] CLAUDE.md ์์ฑ
- ๋ฏธ์ฌ์ฉ ์์ธ ํด๋์ค 4๊ฐ ์ญ์ (PlaceAlreadyExistsException,
PlaceRegistrationException, ValidationException, ExceptionUtils)
- GlobalExceptionHandler ๋ก๊ทธ ๋ ๋ฒจ์ ์ํ์ฝ๋๋ก ๋ถ๊ธฐ
(5xx๋ error+์คํํธ๋ ์ด์ค, 4xx๋ warn์ผ๋ก ๋ฎ์ถฐ ๋ก๊ทธ ์ค์ผ ๋ฐฉ์ง)
- ์๋ฌ ์๋ต์ machine-readable code ํ๋ ์ถ๊ฐ (ErrorInfo = {code, message})
- ๋ฏธ์ฌ์ฉ error(String, String) ์ค๋ฒ๋ก๋ ์ ๊ฑฐ,
error(ErrorCode) โ error(ErrorCode, message) ์์์ผ๋ก ์ค๋ณต ์ ๊ฑฐ
#153 ์์ธ ์ฒ๋ฆฌ ์ ๋ฆฌ ๋ฐ GlobalExceptionHandler ํ์คํ
- HttpClientConfig ์ ๊ท: RestClientCustomizer/WebClientCustomizer๋ก connect 2s / read 5s ํ์์์์ ์๋ ๊ตฌ์ฑ ๋น๋์ ์ค์ ์ ์ฉ - KakaoApiClient๋ฅผ RestClient.Builder ์ฃผ์ ๋ฐฉ์์ผ๋ก ๋ณ๊ฒฝํด ์ปค์คํฐ๋ง์ด์ ํ์์์์ด ์ ์ฉ๋๋๋ก ํจ (no-arg ์์ฒด๋น๋ ์์ฑ์ ์ ๊ฑฐ) - Discord/KakaoLogin WebClient๋ ์ฃผ์ ๋ ๋น๋๋ก ํ์์์ ์๋ ์์
โฆeout #155 ์ธ๋ถ API ํธ์ถ์ ๊ณตํต ํ์์์ ์ค์ ์ถ๊ฐ
- PlaceRepository์ incrementLikeCount/decrementLikeCount @Modifying ์ฟผ๋ฆฌ ์ถ๊ฐ (๊ธฐ์กด incrementViewCount์ ๋์ผ ํจํด, decrement๋ likeCount > 0 ์กฐ๊ฑด์ผ๋ก 0 ๋ฏธ๋ง ๋ฐฉ์ง) - PlaceLikeService์ addLike/removeLike๊ฐ ์ํฐํฐ in-memory ์ฆ๊ฐ ๋์ ์์์ ์ฟผ๋ฆฌ ์ฌ์ฉ - ์๋ก ๋ค๋ฅธ ์ฌ์ฉ์๊ฐ ๋์์ ๊ฐ์ ๋ง์ง์ ์ข์์ํ ๋ ์ฆ๊ฐ๋ถ์ด ์ ์ค๋๋ ๋ฌธ์ ํด๊ฒฐ - ์ด์ ์ฌ์ฉ๋์ง ์๋ Place.incrementLikeCount/decrementLikeCount ์ ๊ฑฐ - ๋์์ฑ ํ๊ท ๋ฐฉ์ง ํ ์คํธ(PlaceLikeServiceConcurrencyTest) ์ถ๊ฐ
- ์ค๋ ๋ํ ํฌ๊ธฐ๋ฅผ ์ฌ์ฉ์ ์(20)๋ก ๋ง์ถฐ ์ค์ 20-way ๋์์ฑ ๋ณด์ฅ (๊ธฐ์กด 16์ผ๋ก๋ ์ต๋ 16-way) - doneLatch.await์ ํ์์์(10s) + ์๋ฃ ์ฌ๋ถ ๊ฒ์ฆ์ผ๋ก CI ๋ฌดํ ๋๊ธฐ ๋ฐฉ์ง - ์์ปค ์ค๋ ๋ ์์ธ๋ฅผ ์์งํด ๊ฒ์ฆํ์ฌ ์์ธ๊ฐ ํ ์คํธ ์คํจ๋ก ์ด์ด์ง๋๋ก ๊ฐ์ (log.error๋ก ์คํํธ๋ ์ด์ค ๋จ๊ธฐ๊ณ failures ํ๋ก ํ์ )
#157 ์ข์์ ์ ๋์์ฑ(lost-update) ์์์ UPDATE๋ก ํด๊ฒฐ
- ์ค๋ ์กฐํ ๋ฐ์ดํฐ๊ฐ ๋ถ์กฑํ ์๋ฒฝ/์ ํธ๋ํฝ ๊ตฌ๊ฐ์ ๋น ๋ญํน์ด ๋์ค๋ ๋ฌธ์ ์์ - getDailyRankingByViews๋ฅผ ํด๋ฐฑ ์ฒด์ธ์ผ๋ก ๋ณ๊ฒฝ (์ค๋ 3๊ณณ ์ด์ โ ์ด์ 3๊ณณ ์ด์ โ ์ ์ฒด ๋์ ์กฐํ์) - ๋์ ์กฐํ์ ๋ญํน ์ฟผ๋ฆฌ findTopByCampusOrderByViewCount ์ถ๊ฐ - ๋ญํน ๋ฉ์๋ ๊ณตํต ๋ก์ง์ buildRankingResponse ํฌํผ๋ก ์ถ์ถ - ์ค๋์ ๋ง์ง ํด๋ฐฑ ์๋๋ฆฌ์ค ํตํฉ ํ ์คํธ ์ถ๊ฐ
#50 ์ค๋์ ๋ง์ง ์กฐํ์ ๋ญํน ๋น ๊ฐ ๋ฐํ ๋ฌธ์ ํด๋ฐฑ์ผ๋ก ํด๊ฒฐ
- common/analytics: EventType/TargetType, EventLog(BaseEntity), AnalyticsEvent(record), AnalyticsRecorder(๋ฐํ ํฌํผ), AnalyticsEventListener(๋น๋๊ธฐ AFTER_COMMIT ์ ์ฌ), EventLogRepository, properties JSON ์ปจ๋ฒํฐ - ๊ธฐ์กด ApplicationEvent + @async @TransactionalEventListener ํจํด ์ฌ์ฌ์ฉ - fire-and-forget: ์ ์ฌ ์คํจ๊ฐ ๋น์ฆ๋์ค ํธ๋์ญ์ ์ ์ํฅ ์์
- JSON ์ปจ๋ฒํฐ ์ง๋ ฌํ/์ญ์ง๋ ฌํ - ๋ฆฌ์ค๋ ์ ์ฌยทํ๋ ๋งคํยทproperties ์๋ณต - ์ปค๋ฐ ์ ์ ์ฌ / ๋กค๋ฐฑ ์ ๋ฏธ์ ์ฌ(AFTER_COMMIT) ํตํฉ ๊ฒ์ฆ
- prod(validate) ๋ฐฐํฌ ์ ์๋ ์์ฑ์ฉ CREATE TABLE - DAU/์ ๊ท๊ฐ์ /์ฝํธํธ ๋ฆฌํ ์ /๋ฑ๋กโ์น์ธโ์๋ชจ ํผ๋ ์ง๊ณ ์ฟผ๋ฆฌ
[feature] ๋น์ฆ๋์ค ์ด๋ฒคํธ ๋ก๊น ๊ธฐ๋ฐ ๊ตฌ์ถ
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.
release v1.1.0
๊ทธ๋์ ๋ฒ์ ์ ์ฉ ์์ด ๋ฐฐํฌํด์๊ธฐ ๋๋ฌธ์ ์์๋ก v1.1.0 ์ ์