Switches or rolls back the task that migrates data from ApsaraDB for RDS to Apsara PolarDB.

  • Migrate data from ApsaraDB for RDS to Apsara PolarDB.
  • Roll back data migration from Apsara PolarDB to ApsaraDB for RDS.
Note Before you call this operation, make sure that an upgrade task is created for the cluster. You can call the CreateDBCluster operation to create an upgrade task. Set the CreationOption parameter to MigrationFromRDS. For more information, see Create a ApsaraDB PolarDB MySQL-compatible edition cluster by using the Migration from RDS method.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String No ModifyDBClusterMigration

The operation that you want to perform. Set the value to ModifyDBClusterMigration.

DBClusterId String Yes pc-**************

The ID of the Apsara PolarDB cluster.

NewMasterInstanceId String Yes pc-**************

The ID of the new instance or new cluster. Valid values:

  • To perform a data migration, enter the ID of the Apsara PolarDB cluster.
  • To perform a migration rollback, enter the ID of the ApsaraDB for RDS instance.
SourceRDSDBInstanceId String Yes rm-************

The ID of the source ApsaraDB for RDS instance.

RegionId String No cn-hangzhou

The region ID of the cluster.

SwapConnectionString String No false

Specifies whether to interchange the endpoints of the instances. Valid values:

  • true: interchanges the endpoints. If you select this option, you do not need the change the endpoint in your applications.
  • false: does not interchange the endpoints. If you select this option, you must specify the endpoint of the PolarDB cluster in your applications.

Default value: false.

Response parameters

Parameter Type Example Description
RequestId String A1B303A5-653F-4AEE-A598-023FF9******

The ID of the request.

Examples

Sample request

http(s)://polardb.aliyuncs.com/? Action=ModifyDBClusterMigration
&DBClusterId=pc-**************
&NewMasterInstanceId=pc-**************
&SourceRDSDBInstanceId=rm-************
&<Common request parameters>

Sample success responses

XML format

<ModifyDBClusterMigrationResponse>  
  <RequestId>A1B303A5-653F-4AEE-A598-023FF9******</RequestId>
</ModifyDBClusterMigrationResponse>

JSON format

{
  "RequestId": "A1B303A5-653F-4AEE-A598-023FF9******"
}

Error codes

For a list of error codes, visit the API Error Center.