Domain name for API request: cdb.intl.tencentcloudapi.com.
This API is used to update the information of a TencentDB RO group, such as configuring a read-only instance removal policy in case of excessive delay, setting read weights of read-only instances, and setting the replication delay.
A maximum of 20 requests can be initiated per second for this API.
The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.
| Parameter Name | Required | Type | Description |
|---|---|---|---|
| Action | Yes | String | Common Params. The value used for this API: ModifyRoGroupInfo. |
| Version | Yes | String | Common Params. The value used for this API: 2017-03-20. |
| Region | Yes | String | Common Params. For more information, please see the list of regions supported by the product. |
| RoGroupId | Yes | String | ID of the RO group, which can be obtained through the DescribeRoGroups API. |
| RoGroupInfo | No | RoGroupAttr | RO group details. |
| RoWeightValues.N | No | Array of RoWeightValue | Weight of instances in the RO group. If modification is needed to set the weight mode of the RO group to user-defined mode (custom), this parameter must be set, and the weight value of each read-only instance needs to be set. The RO instance ID can be obtained through the DescribeRoGroups API. |
| IsBalanceRoLoad | No | Integer | Whether to rebalance the loads of read-only replicas in the RO group. Valid values: 1 (yes), 0 (no). Default value: 0. If this parameter is set to 1, connections to the read-only replicas in the RO group will be interrupted transiently. Please ensure that your application has a reconnection mechanism. |
| Parameter Name | Type | Description |
|---|---|---|
| AsyncRequestId | String | Asynchronous Task ID. |
| RequestId | String | The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. |
POST / HTTP/1.1
Host: cdb.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: ModifyRoGroupInfo
<Common request parameters>
{
"RoGroupId": "cdbrg-iup41a4t",
"RoGroupInfo": {
"RoOfflineDelay": 1,
"MinRoInGroup": 1,
"RoMaxDelayTime": 10
}
}
{
"Response": {
"RequestId": "6EF60BEC-0242-43AF-BB20-270359FB54A7",
"AsyncRequestId": "a6040589-3b098df5-b551d9e5-81c6bfdc"
}
}
POST / HTTP/1.1
Host: cdb.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: ModifyRoGroupInfo
<Common request parameters>
{
"RoWeightValues": [
{
"InstanceId": "cdbr0-test1234",
"Weight": 70
},
{
"InstanceId": "cdbr0-iup41a4t",
"Weight": 30
}
],
"IsBalanceRoLoad": 1,
"RoGroupId": "cdbrg-iup41a4t",
"RoGroupInfo": {
"WeightMode": "custom"
}
}
{
"Response": {
"RequestId": "6EF60BEC-0242-43AF-BB20-270359FB54Ad",
"AsyncRequestId": "a6040589-3b098df5-b551d9e5-81c6bfd1"
}
}
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.
The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.
| Error Code | Description |
|---|---|
| FailedOperation.DescribeProxyGroupError | Failed to query database proxy. |
| FailedOperation.StatusConflict | Task status conflict. |
| InternalError.DBRecordNotExistError | The database instance does not exist. |
| InternalError.DatabaseAccessError | Internal database error. |
| InternalError.TaskFrameError | Async task error. |
| InternalError.UnknownError | Unknown error |
| InvalidParameter | Parameter error. |
| InvalidParameter.InstanceNotFound | The instance does not exist. |
| InvalidParameterValue.DataConvertError | Data conversion failed. |
| InvalidParameterValue.InvalidParameterValueError | Invalid parameter value |
| MissingParameter.MissingParamError | Required parameters are missing. |
| OperationDenied.ConflictRoStatus | The operation is not allowed as the RO group contains an invalid read-only instance. |
| OperationDenied.ConflictStatus | The configuration of read-only group is being modified. Please do not make repeated requests. |
| OperationDenied.DelayReplicationRunning | The operation is not allowed during the delayed replication. |
| OperationDenied.InstanceLockerConflict | Instance locks are in conflict. Please try again later. |
| ResourceNotFound.CdbInstanceNotFoundError | The instance cannot be found. Please check whether your instance status is normal. |
フィードバック