Querying the DR Switchover Configurations of Instances
Function
This API is used to query the DR switchover configurations of instances.
Constraints
This API can be used only on GeminiDB Cassandra instances.
Authorization Information
Each account has permissions to call all APIs, but IAM users must have the required permissions specifically assigned.
- If you are using role/policy-based authorization, see the required permissions in Permissions and Supported Actions.
- If you are using identity policy-based authorization, the following identity policy-based permissions are required.
Action
Access Level
Resource Type (*: required)
Condition Key
Alias
Dependencies
gaussdbfornosql:instance:listDisasterSettings
List
-
-
nosql:dr:listDisasterRecoverySettings
-
URI
GET /v3/{project_id}/instances/disaster-recovery/settings
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| project_id | Yes | String | Definition Project ID of a tenant in a region. To obtain this value, see Obtaining a Project ID. Constraints N/A Range The value contains 32 characters. Only letters and digits are allowed. Default Value N/A |
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| instance_id | No | String | Definition Instance ID, which can be obtained by calling the API described in Querying Instances and Details. If you do not have an instance, call the API described in Creating an Instance to create one. Constraints N/A Range N/A Default Value N/A |
| offset | No | Integer | Definition Index offset If offset is set to N, the query starts from the N+1 piece of data. The default value is 0, which indicates that the query starts from the first piece of data. Constraints The value must be a non-negative number. Range Non-negative integer Default Value 0 |
| limit | No | Integer | Definition Maximum records to be queried Constraints N/A Range 1–50 Default Value 50. If this parameter is not transferred, the first 50 records are queried by default. |
Request Parameters
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| X-Auth-Token | Yes | String | Definition User token You can obtain the token by calling the IAM API by following Obtaining a User Token Through Password Authentication. Constraints N/A Range N/A Default Value N/A |
Response Parameters
Status code: 200
| Parameter | Type | Description |
|---|---|---|
| disaster_recovery_settings | Array of SwitchoverRatio objects | Definition Faulty nodes to be taken over |
| total_count | Integer | Definition Total number of records Range N/A |
| Parameter | Type | Description |
|---|---|---|
| instance_id | String | Definition Instance ID, which can be obtained by calling the API described in Querying Instances and Details. If you do not have an instance, call the API described in Creating an Instance to create one. Range N/A |
| switchover_ratio | Integer | Definition Percentage of faulty nodes to trigger a DR switchover Range
|
| sync_delay | Long | Definition Data synchronization delay of the DR instance, in seconds. If the synchronization delay between the DR instance and the primary instance exceeds this value, no DR switchover will be triggered. By default, the delay is not checked. Range N/A |
Example Requests
- Querying DR switchover configurations (default: 50 instances)
GET https://{endpoint}/v3/0549b4a43100d4f32f51c01c2fe4acdb/instances/disaster-recovery/settings - Querying DR switchover configurations
GET https://{endpoint}/v3/0549b4a43100d4f32f51c01c2fe4acdb/instances/disaster-recovery/settings?offset=0&limit=50&instance_id=d74162b942604190b991d1c39772a66ain06&instance_id=e74162b942604190b991d1c39772a66ain06
Example Responses
Status code: 200
Success
{
"total_count" : 4,
"disaster_recovery_settings" : [ {
"instance_id" : "d74162b942604190b991d1c39772a66ain06",
"switchover_ratio" : 50
}, {
"instance_id" : "e74162b942604190b991d1c39772a66ain06",
"switchover_ratio" : 100
}, {
"instance_id" : "d863b72d8d05457b93fb519cefe8278din06",
"switchover_ratio" : 60,
"sync_delay" : 300000
}, {
"instance_id" : "6f64151731604cad99fb97c449158758in06",
"switchover_ratio" : 80,
"sync_delay" : 600000
} ]
} Status Codes
For details, see Status Codes.
Error Codes
For details, see Error Codes.
What is your overall rating for this page?
Thank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot