|
|
@ -33,9 +33,12 @@ public class OssFactory {
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
public static void init() {
|
|
|
|
public static void init() {
|
|
|
|
log.info("初始化OSS工厂");
|
|
|
|
log.info("初始化OSS工厂");
|
|
|
|
RedisUtils.subscribe(OssConstant.CACHE_CONFIG_KEY, String.class, msg -> {
|
|
|
|
RedisUtils.subscribe(OssConstant.CACHE_CONFIG_KEY, String.class, type -> {
|
|
|
|
refreshService(msg);
|
|
|
|
// 没有的实例不处理
|
|
|
|
log.info("订阅刷新OSS配置 => " + msg);
|
|
|
|
if (SERVICES.containsKey(type)) {
|
|
|
|
|
|
|
|
refreshService(type);
|
|
|
|
|
|
|
|
log.info("订阅刷新OSS配置 => " + type);
|
|
|
|
|
|
|
|
}
|
|
|
|
});
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|