初始化存储引擎后, 增加测试连接机制

This commit is contained in:
zhaojun1998
2019-12-25 21:57:22 +08:00
parent e334acd508
commit b65ccc95e2
10 changed files with 23 additions and 14 deletions

View File

@@ -75,7 +75,7 @@ public class HuaweiServiceImpl implements FileService {
bucketName = stringStorageConfigMap.get(BUCKET_NAME_KEY).getValue();
domain = stringStorageConfigMap.get(DOMAIN_KEY).getValue();
obsClient = new ObsClient(accessKey, secretKey, endPoint);
isInitialized = true;
isInitialized = testConnection();
} catch (Exception e) {
log.debug(StorageTypeEnum.HUAWEI.getDescription() + "初始化异常, 已跳过");
}