feat(content): 시리즈 상세의 언어 감지와 번역을 동기로 완료한다

This commit is contained in:
2026-11-17 14:35:15 +09:00
parent 9cadaa919b
commit 536a5a6fe5
6 changed files with 621 additions and 50 deletions
@@ -3,6 +3,9 @@ package kr.co.vividnext.sodalive.content
import kr.co.vividnext.sodalive.aws.cloudfront.AudioContentCloudFront
import kr.co.vividnext.sodalive.aws.s3.S3Uploader
import kr.co.vividnext.sodalive.configs.QueryDslConfig
import kr.co.vividnext.sodalive.content.series.ContentSeriesController
import kr.co.vividnext.sodalive.content.series.ContentSeriesDetailTranslationService
import kr.co.vividnext.sodalive.content.series.ContentSeriesService
import kr.co.vividnext.sodalive.content.theme.AudioContentThemeQueryRepository
import kr.co.vividnext.sodalive.explorer.ExplorerQueryRepository
import kr.co.vividnext.sodalive.i18n.Lang
@@ -66,7 +69,8 @@ import javax.servlet.http.HttpServletResponse
TranslationJobScheduler::class, ResourceTranslationJobScheduler::class,
TranslationReadModelMaterializer::class, LanguageDetectionCacheService::class,
AudioContentDetailTranslationService::class, TranslationMemoryService::class, TranslationJobWorker::class,
LanguageDetectListener::class
LanguageDetectListener::class, ContentSeriesController::class, ContentSeriesService::class,
ContentSeriesDetailTranslationService::class
)
@MockBean(
classes = [
@@ -141,7 +145,13 @@ class DetailTranslationProvider : TranslationProvider, LanguageDetectionProvider
calls.incrementAndGet()
beforeTranslate()
check(!fail) { "provider unavailable" }
val translations = mapOf("원문 제목" to "English title", "원문 설명" to "English detail", "#힐링" to "#Healing")
val translations = mapOf(
"원문 제목" to "English title",
"원문 설명" to "English detail",
"#힐링" to "#Healing",
"#힐링, #차분" to "#Healing, #Calm",
"수정 제목" to "Edited title"
)
return TranslateResult(request.texts.map(translations::getValue))
}
}