startDBInstanceAutomatedBackupsReplication method
Enables replication of automated backups to a different AWS Region.
For more information, see Replicating Automated Backups to Another AWS Region in the Amazon RDS User Guide.
May throw DBInstanceNotFoundFault. May throw InvalidDBInstanceStateFault. May throw KMSKeyNotAccessibleFault. May throw DBInstanceAutomatedBackupQuotaExceededFault. May throw StorageTypeNotSupportedFault.
Parameter sourceDBInstanceArn
:
The Amazon Resource Name (ARN) of the source DB instance for the
replicated automated backups, for example,
arn:aws:rds:us-west-2:123456789012:db:mydatabase
.
Parameter backupRetentionPeriod
:
The retention period for the replicated automated backups.
Parameter kmsKeyId
:
The AWS KMS key identifier for encryption of the replicated automated
backups. The KMS key ID is the Amazon Resource Name (ARN) for the KMS
encryption key in the destination AWS Region, for example,
arn:aws:kms:us-east-1:123456789012:key/AKIAIOSFODNN7EXAMPLE
.
Parameter preSignedUrl
:
A URL that contains a Signature Version 4 signed request for the
StartDBInstanceAutomatedBackupsReplication action to be called in the AWS
Region of the source DB instance. The presigned URL must be a valid
request for the StartDBInstanceAutomatedBackupsReplication API action that
can be executed in the AWS Region that contains the source DB instance.
Implementation
Future<StartDBInstanceAutomatedBackupsReplicationResult>
startDBInstanceAutomatedBackupsReplication({
required String sourceDBInstanceArn,
int? backupRetentionPeriod,
String? kmsKeyId,
String? preSignedUrl,
}) async {
ArgumentError.checkNotNull(sourceDBInstanceArn, 'sourceDBInstanceArn');
final $request = <String, dynamic>{};
$request['SourceDBInstanceArn'] = sourceDBInstanceArn;
backupRetentionPeriod
?.also((arg) => $request['BackupRetentionPeriod'] = arg);
kmsKeyId?.also((arg) => $request['KmsKeyId'] = arg);
preSignedUrl?.also((arg) => $request['PreSignedUrl'] = arg);
final $result = await _protocol.send(
$request,
action: 'StartDBInstanceAutomatedBackupsReplication',
version: '2014-10-31',
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
shape: shapes['StartDBInstanceAutomatedBackupsReplicationMessage'],
shapes: shapes,
resultWrapper: 'StartDBInstanceAutomatedBackupsReplicationResult',
);
return StartDBInstanceAutomatedBackupsReplicationResult.fromXml($result);
}