From 55f8585ea868bb49c9aa934d0446bcd968283424 Mon Sep 17 00:00:00 2001 From: YunaiV Date: Sat, 9 Sep 2023 10:34:58 +0800 Subject: [PATCH] =?UTF-8?q?=E5=90=8C=E6=AD=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../framework/tenant/core/redis/TenantRedisCacheManager.java | 3 ++- .../yudao/framework/redis/core/TimeoutRedisCacheManager.java | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/yudao-framework/yudao-spring-boot-starter-biz-tenant/src/main/java/cn/iocoder/yudao/framework/tenant/core/redis/TenantRedisCacheManager.java b/yudao-framework/yudao-spring-boot-starter-biz-tenant/src/main/java/cn/iocoder/yudao/framework/tenant/core/redis/TenantRedisCacheManager.java index 8058b2f54..240b9209f 100644 --- a/yudao-framework/yudao-spring-boot-starter-biz-tenant/src/main/java/cn/iocoder/yudao/framework/tenant/core/redis/TenantRedisCacheManager.java +++ b/yudao-framework/yudao-spring-boot-starter-biz-tenant/src/main/java/cn/iocoder/yudao/framework/tenant/core/redis/TenantRedisCacheManager.java @@ -1,5 +1,6 @@ package cn.iocoder.yudao.framework.tenant.core.redis; +import cn.iocoder.yudao.framework.redis.core.TimeoutRedisCacheManager; import cn.iocoder.yudao.framework.tenant.core.context.TenantContextHolder; import lombok.extern.slf4j.Slf4j; import org.springframework.cache.Cache; @@ -15,7 +16,7 @@ import org.springframework.data.redis.cache.RedisCacheWriter; * @author airhead */ @Slf4j -public class TenantRedisCacheManager extends RedisCacheManager { +public class TenantRedisCacheManager extends TimeoutRedisCacheManager { public TenantRedisCacheManager(RedisCacheWriter cacheWriter, RedisCacheConfiguration defaultCacheConfiguration) { diff --git a/yudao-framework/yudao-spring-boot-starter-redis/src/main/java/cn/iocoder/yudao/framework/redis/core/TimeoutRedisCacheManager.java b/yudao-framework/yudao-spring-boot-starter-redis/src/main/java/cn/iocoder/yudao/framework/redis/core/TimeoutRedisCacheManager.java index bf34fc081..3e40c0be6 100644 --- a/yudao-framework/yudao-spring-boot-starter-redis/src/main/java/cn/iocoder/yudao/framework/redis/core/TimeoutRedisCacheManager.java +++ b/yudao-framework/yudao-spring-boot-starter-redis/src/main/java/cn/iocoder/yudao/framework/redis/core/TimeoutRedisCacheManager.java @@ -45,7 +45,7 @@ public class TimeoutRedisCacheManager extends RedisCacheManager { Duration duration = parseDuration(names[1]); cacheConfig = cacheConfig.entryTtl(duration); } - return super.createRedisCache(names[0], cacheConfig); + return super.createRedisCache(name, cacheConfig); } /**