From 4d8e0af7a54798e123833a4548aae8be3712b175 Mon Sep 17 00:00:00 2001 From: LamGC Date: Wed, 23 Sep 2020 13:53:41 +0800 Subject: [PATCH] =?UTF-8?q?[Change]=20CacheStore-redis=20=E8=B0=83?= =?UTF-8?q?=E6=95=B4=20Factory=20=E5=AF=B9=E8=8E=B7=E5=8F=96=E5=B0=9A?= =?UTF-8?q?=E6=9C=AA=E5=AE=8C=E6=88=90=E7=BB=84=E4=BB=B6=E7=9A=84=E5=8F=8D?= =?UTF-8?q?=E9=A6=88=E6=96=B9=E5=BC=8F;?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [Change] RedisCacheStoreFactory 调整 List 和 Set 的行为(返回 null 改为抛出异常); --- .../lamgc/cgj/bot/cache/redis/RedisCacheStoreFactory.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ContentGrabbingJi-CacheStore-redis/src/main/java/net/lamgc/cgj/bot/cache/redis/RedisCacheStoreFactory.java b/ContentGrabbingJi-CacheStore-redis/src/main/java/net/lamgc/cgj/bot/cache/redis/RedisCacheStoreFactory.java index 79df6b2..bf28934 100644 --- a/ContentGrabbingJi-CacheStore-redis/src/main/java/net/lamgc/cgj/bot/cache/redis/RedisCacheStoreFactory.java +++ b/ContentGrabbingJi-CacheStore-redis/src/main/java/net/lamgc/cgj/bot/cache/redis/RedisCacheStoreFactory.java @@ -19,6 +19,7 @@ package net.lamgc.cgj.bot.cache.redis; import net.lamgc.cgj.bot.cache.*; import net.lamgc.cgj.bot.cache.convert.StringConverter; +import net.lamgc.cgj.bot.cache.exception.GetCacheStoreException; /** * @@ -33,12 +34,12 @@ public class RedisCacheStoreFactory implements CacheStoreFactory { @Override public ListCacheStore newListCacheStore(String identify, StringConverter converter) { - return null; + throw new GetCacheStoreException("No corresponding implementation"); } @Override public SetCacheStore newSetCacheStore(String identify, StringConverter converter) { - return null; + throw new GetCacheStoreException("No corresponding implementation"); } @Override