From ec5ca0a08faaf6e69f83d292b3ec909294a7dc39 Mon Sep 17 00:00:00 2001 From: 秋辞未寒 <545073804@qq.com> Date: 星期五, 03 一月 2025 09:44:39 +0800 Subject: [PATCH] fix 修复 redisson发号器未初始化发号器步长导致过期时间未生效的问题 --- ruoyi-common/ruoyi-common-redis/src/main/java/org/dromara/common/redis/manager/CaffeineCacheDecorator.java | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/ruoyi-common/ruoyi-common-redis/src/main/java/org/dromara/common/redis/manager/CaffeineCacheDecorator.java b/ruoyi-common/ruoyi-common-redis/src/main/java/org/dromara/common/redis/manager/CaffeineCacheDecorator.java index 793e21f..6e83df1 100644 --- a/ruoyi-common/ruoyi-common-redis/src/main/java/org/dromara/common/redis/manager/CaffeineCacheDecorator.java +++ b/ruoyi-common/ruoyi-common-redis/src/main/java/org/dromara/common/redis/manager/CaffeineCacheDecorator.java @@ -44,6 +44,7 @@ } @SuppressWarnings("unchecked") + @Override public <T> T get(Object key, Class<T> type) { Object o = CAFFEINE.get(getUniqueKey(key), k -> cache.get(key, type)); return (T) o; @@ -55,6 +56,7 @@ cache.put(key, value); } + @Override public ValueWrapper putIfAbsent(Object key, Object value) { CAFFEINE.invalidate(getUniqueKey(key)); return cache.putIfAbsent(key, value); @@ -65,6 +67,7 @@ evictIfPresent(key); } + @Override public boolean evictIfPresent(Object key) { boolean b = cache.evictIfPresent(key); if (b) { @@ -78,6 +81,7 @@ cache.clear(); } + @Override public boolean invalidate() { return cache.invalidate(); } -- Gitblit v1.9.3