From bfeca2cd7c418efe1df21d844f36a704794fec54 Mon Sep 17 00:00:00 2001 From: 疯狂的狮子Li <15040126243@163.com> Date: 星期一, 30 八月 2021 12:20:46 +0800 Subject: [PATCH] !84 全量保存或更新之前判断addList长度和updateList长度 Merge pull request !84 from 抓蛙师/dev --- ruoyi-oss/src/main/java/com/ruoyi/oss/factory/OssFactory.java | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/ruoyi-oss/src/main/java/com/ruoyi/oss/factory/OssFactory.java b/ruoyi-oss/src/main/java/com/ruoyi/oss/factory/OssFactory.java index 1290685..accbbcd 100644 --- a/ruoyi-oss/src/main/java/com/ruoyi/oss/factory/OssFactory.java +++ b/ruoyi-oss/src/main/java/com/ruoyi/oss/factory/OssFactory.java @@ -11,6 +11,7 @@ import com.ruoyi.oss.exception.OssException; import com.ruoyi.oss.properties.CloudStorageProperties; import com.ruoyi.oss.service.ICloudStorageStrategy; +import com.ruoyi.oss.service.abstractd.AbstractCloudStorageStrategy; import java.util.Date; import java.util.Map; @@ -68,7 +69,8 @@ return service; } // 鑾峰彇redis閰嶇疆淇℃伅 鍒涘缓瀵硅薄 骞剁紦瀛� - service = (ICloudStorageStrategy) ReflectUtils.newInstance(CloudServiceEnumd.getServiceClass(type), properties); + service = (ICloudStorageStrategy) ReflectUtils.newInstance(CloudServiceEnumd.getServiceClass(type)); + ((AbstractCloudStorageStrategy)service).init(properties); SERVICES.put(type, service); SERVICES_UPDATE_TIME.put(type, nowDate); return service; -- Gitblit v1.9.3