From ae864908949ffbe74a7a17db4292d6ba01fbbb39 Mon Sep 17 00:00:00 2001 From: Miseong Kim Date: Thu, 17 Oct 2024 23:47:31 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20v2=20=EC=BA=90=EC=8B=9C=20evict=20?= =?UTF-8?q?=EC=84=A4=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/nexters/bottles/api/admin/facade/AdminFacade.kt | 3 +++ .../bottles/app/bottle/service/BottleCachingService.kt | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/api/src/main/kotlin/com/nexters/bottles/api/admin/facade/AdminFacade.kt b/api/src/main/kotlin/com/nexters/bottles/api/admin/facade/AdminFacade.kt index 99bd4ef..b1b44a2 100644 --- a/api/src/main/kotlin/com/nexters/bottles/api/admin/facade/AdminFacade.kt +++ b/api/src/main/kotlin/com/nexters/bottles/api/admin/facade/AdminFacade.kt @@ -130,6 +130,9 @@ class AdminFacade( CacheEvict(PING_PONG_BOTTLE_LIST, key = "1"), CacheEvict(PING_PONG_BOTTLE_LIST, key = "2"), CacheEvict(PING_PONG_BOTTLE_LIST, key = "9"), + CacheEvict(PING_PONG_BOTTLE_LIST, key = "1 + '-v2'"), + CacheEvict(PING_PONG_BOTTLE_LIST, key = "2 + '-v2'"), + CacheEvict(PING_PONG_BOTTLE_LIST, key = "9 + '-v2'"), ] ) fun forceCleanUp() { diff --git a/app/src/main/kotlin/com/nexters/bottles/app/bottle/service/BottleCachingService.kt b/app/src/main/kotlin/com/nexters/bottles/app/bottle/service/BottleCachingService.kt index df6d0a9..31d2375 100644 --- a/app/src/main/kotlin/com/nexters/bottles/app/bottle/service/BottleCachingService.kt +++ b/app/src/main/kotlin/com/nexters/bottles/app/bottle/service/BottleCachingService.kt @@ -31,7 +31,9 @@ class BottleCachingService( @Caching( evict = [ CacheEvict(PING_PONG_BOTTLE_LIST, key = "#sourceUserId"), - CacheEvict(PING_PONG_BOTTLE_LIST, key = "#targetUserId") + CacheEvict(PING_PONG_BOTTLE_LIST, key = "#targetUserId"), + CacheEvict(PING_PONG_BOTTLE_LIST, key = "#sourceUserId + '-v2'"), + CacheEvict(PING_PONG_BOTTLE_LIST, key = "#targetUserId + '-v2'"), ] ) fun evictPingPongList(sourceUserId: Long, targetUserId: Long) {