fix 修复 OssFactory 并发多创建实例问题

2.X
疯狂的狮子Li 1 year ago
parent 76f5addd22
commit c847ad726c

@ -39,7 +39,7 @@ public class OssFactory {
/**
*
*/
public static OssClient instance(String configKey) {
public static synchronized OssClient instance(String configKey) {
String json = CacheUtils.get(CacheNames.SYS_OSS_CONFIG, configKey);
if (json == null) {
throw new OssException("系统异常, '" + configKey + "'配置信息不存在!");

Loading…
Cancel
Save