Queries whether the data of an ApsaraDB for MongoDB instance can be restored.
Operation description
This operation is applicable to replica set instances and sharded cluster instances.
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action
policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- The required resource types are displayed in bold characters.
- If the permissions cannot be granted at the resource level,
All Resources
is used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
dds:CheckRecoveryCondition | get |
|
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
SourceDBInstance | string | Yes | The ID of the source instance. | dds-bp1378**** |
DatabaseNames | string | No | The name of the source database. The value is a JSON array. Note
If you do not specify this parameter, all databases are restored by default.
| ["db1","db2"] |
RestoreTime | string | No | The point in time to which the instance is restored. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC. Note
| 2022-08-22T08:00:00Z |
BackupId | string | No | The backup ID. Note
| 5664**** |
ResourceGroupId | string | No | The ID of the resource group to which the instance belongs. | sg-bp179**** |
SrcRegion | string | No | The region where the source instance resides. Note
| cn-beijing |
DestRegion | string | No | The region of the backup set used for the cross-region backup and restoration. Note
This parameter is required when you set the RestoreType parameter to 3.
| cn-hangzhou |
RestoreType | string | No | The restoration type. Note
| 0 |
InstanceType | string | No | The instance architecture. Valid values:
Note
| replicate |
EngineVersion | string | No | The database engine version of the instance.
| 4.2 |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "D563A3E7-6010-45FE-A0CD-9283414C9657",
"DBInstanceName": "dds-bp1378****",
"IsValid": true
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
400 | InvalidMeta.WrongFormat | Meta information is wrong formatter. | - |
400 | InvalidRestoreTime.Format | Specified restore time is not valid. | The specified RestoreTime value is invalid. |
403 | InvalidDBName | The specified database name is not allowed. | The specified database name is invalid. |
403 | InvalidMeta.TooLarge | Meta information is too large. | The metadata is too large. |
403 | SingleDBRestore.BackupSetNotSupport | This backup set do not support this operation. | Single-database recovery is not supported for the specified time point or backup file. |
403 | IncorrectDBInstanceType | Current DB instance type does not support this operation. | This operation is not supported for the specified instance type. |
403 | IncorrectEngineVersion | Current engine version does not support operations. | - |
403 | InvalidBackupLogStatus | Current backup log enable status does not support this operation. | The operation is not supported when log backup is enabled. |
403 | IncorrectBackupSetState | Current backup set state does not support operations.. | - |
404 | InvalidBackupSetID.NotFound | Specifiedbackup set ID does not exist. | - |
404 | InvalidBackup.NotFound | Theavailable backup does not exist in recovery time. | No backup set is available during the specified recovery period. |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2024-10-29 | The Error code has changed. The request parameters of the API has changed | View Change Details |