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

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

@@ -79,7 +79,7 @@ public class TencentServiceImpl implements FileService {
Region region = new Region(regionName);
ClientConfig clientConfig = new ClientConfig(region);
cosClient = new COSClient(cred, clientConfig);
isInitialized = true;
isInitialized = testConnection();
} catch (Exception e) {
log.debug(StorageTypeEnum.TENCENT.getDescription() + "初始化异常, 已跳过");
}