Add BackupStorageType.

This commit is contained in:
sdk-team
2020-03-09 21:03:03 +08:00
parent 0f47a4c427
commit 320af597ca
5 changed files with 21 additions and 4 deletions

View File

@@ -31,21 +31,21 @@ DbsClient::DbsClient(const Credentials &credentials, const ClientConfiguration &
RpcServiceClient(SERVICE_NAME, std::make_shared<SimpleCredentialsProvider>(credentials), configuration)
{
auto locationClient = std::make_shared<LocationClient>(credentials, configuration);
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "cbs");
}
DbsClient::DbsClient(const std::shared_ptr<CredentialsProvider>& credentialsProvider, const ClientConfiguration & configuration) :
RpcServiceClient(SERVICE_NAME, credentialsProvider, configuration)
{
auto locationClient = std::make_shared<LocationClient>(credentialsProvider, configuration);
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "cbs");
}
DbsClient::DbsClient(const std::string & accessKeyId, const std::string & accessKeySecret, const ClientConfiguration & configuration) :
RpcServiceClient(SERVICE_NAME, std::make_shared<SimpleCredentialsProvider>(accessKeyId, accessKeySecret), configuration)
{
auto locationClient = std::make_shared<LocationClient>(accessKeyId, accessKeySecret, configuration);
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "cbs");
}
DbsClient::~DbsClient()

View File

@@ -148,6 +148,17 @@ void ConfigureBackupPlanRequest::setEnableBackupLog(bool enableBackupLog)
setParameter("EnableBackupLog", enableBackupLog ? "true" : "false");
}
std::string ConfigureBackupPlanRequest::getBackupStorageType()const
{
return backupStorageType_;
}
void ConfigureBackupPlanRequest::setBackupStorageType(const std::string& backupStorageType)
{
backupStorageType_ = backupStorageType;
setParameter("BackupStorageType", backupStorageType);
}
int ConfigureBackupPlanRequest::getDuplicationArchivePeriod()const
{
return duplicationArchivePeriod_;