Domain name for API request: postgres.intl.tencentcloudapi.com.
This API is used to modify the read-only instance weight.
A maximum of 100 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: ModifyReadOnlyDBInstanceWeight. |
| Version | Yes | String | Common Params. The value used for this API: 2017-03-12. |
| Region | Yes | String | Common Params. For more information, please see the list of regions supported by the product. This API only supports: ap-bangkok, ap-beijing, ap-chengdu, ap-chongqing, ap-guangzhou, ap-hongkong, ap-jakarta, ap-nanjing, ap-seoul, ap-shanghai, ap-shanghai-fsi, ap-shenzhen-fsi, ap-singapore, ap-tokyo, eu-frankfurt, na-ashburn, na-siliconvalley, sa-saopaulo. |
| DBInstanceId | Yes | String | Instance ID. obtain through the api DescribeDBInstances. |
| ReadOnlyGroupId | Yes | String | ReadOnlyGroupId. specifies the read-only group ID, which can be obtained through the api DescribeReadOnlyGroups. |
| Weight | Yes | Integer | Specifies the traffic weight of the read-only instance in the read-only group. valid values: 1-50. |
| Parameter Name | Type | Description |
|---|---|---|
| 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: postgres.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: ModifyReadOnlyDBInstanceWeight
<Common request parameters>
{
"ReadOnlyGroupId": "pgrogp-test",
"DBInstanceId": "pgro-e0tfm161",
"Weight": 1
}
{
"Response": {
"RequestId": "d43b2a9f-070c-480b-a0bb-7c210428cfe8"
}
}
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.CamAuthFailed | CAM authentication failed. |
| FailedOperation.CamSigAndAuthError | Authentication failed. Please try again later. If the problem persists, please contact customer service. |
| FailedOperation.DatabaseAccessError | Failed to access database management service. Please try again later. If the problem persists, please contact customer service. |
| FailedOperation.FailedOperationError | Operation failed. Please try again later. |
| FailedOperation.IllegalROInstanceNum | Invalid number of read-only replicas. |
| FailedOperation.ROGroupMasterInstanceNotRight | The primary instance information of the RO group is not matched. |
| FailedOperation.ROGroupNotFoundError | The RO group does not exist. |
| InstanceNotExist | The current instance does not exist. |
| InternalError.InternalHttpServerError | An exception occurred while executing the request. |
| InvalidInstanceStatus | Incorrect instance status. |
| InvalidParameterValue.InvalidParameterValueError | Incorrect parameter value |
| InvalidParameterValue.InvalidReadOnlyGroupStatus | RO group in incorrect status |
| InvalidParameterValue.ParameterHandleError | Failed to process the parameter. Please check if the parameter value is valid. |
| InvalidParameterValue.ReadOnlyGroupNotExist | The RO group does not exist. |
| OperationDenied.CamDeniedError | This operation cannot be performed. |
| OperationDenied.InstanceStatusLimitOpError | This operation cannot be performed on an instance in this status. |
| OperationDenied.ROGroupStatusError | This operation cannot be performed on an RO group in this status. |
| ResourceNotFound.InstanceNotFoundError | The instance does not exist. |
| ResourceUnavailable.InvalidInstanceStatus | Incorrect instance status. |
Was this page helpful?
You can also Contact sales or Submit a Ticket for help.
Help us improve! Rate your documentation experience in 5 mins.
Feedback