Reviewed-by: Boka, Ladislav <ladislav.boka@t-systems.com> Co-authored-by: Ru, Li Yi <liyiru7@huawei.com> Co-committed-by: Ru, Li Yi <liyiru7@huawei.com>
15 KiB
Modifying Parameters of a Specified DB Instance
Function
This API is used to modify parameters in the parameter template of a specified DB instance. Before calling this API:
- Learn how to authenticate this API.
- Understand the API in Using APIs.
- Obtain the required region and endpoint.
Constraints
The values of the modified parameters must be within the default value range of the specified database version.
URI
- URI format
PUT https://{Endpoint}/v3/{project_id}/instances/{instance_id}/configurations
- Example
https://gaussdb.eu-de.otc.t-systems.com/v3/0483b6b16e954cb88930a360d2c4e663/instances/dsfae23fsfdsae3435in01/configurations
- Parameter description
Table 1 Parameter description Name
Mandatory
Description
project_id
Yes
Project ID of a tenant in a region.
To obtain this value, see Obtaining a Project ID.
instance_id
Yes
DB instance ID.
Request
- Parameter description
Table 2 Parameter description Name
Mandatory
Type
Description
values
Yes
Map<String,String>
Parameter values defined by users based on the default parameter templates.
Example: For failed_login_attempts: 4, failed_login_attempts indicates the parameter name, and 4 indicated the changed parameter value.
Example Request
- Changing the value of failed_login_attempts to 4 (The change is applied without a DB instance reboot.)
{ "values": { "failed_login_attempts": "4" } }
- Changing the value of track_activity_query_size to 2048 and the value of max_replication_slots to 25 (The changes are applied after the DB instance is rebooted.)
{ "values": { "track_activity_query_size": "2048", "max_replication_slots": "30" } }
Response
- Normal response
Table 3 Parameter description Name
Type
Description
restart_required
Boolean
Whether a reboot is required.
- true: A reboot is required.
- false: A reboot is not required.
- Example normal response
- A reboot is not required.
{ "restart_required": false }
- A reboot is required.
{ "restart_required": true }
- A reboot is not required.
- Abnormal response
For details, see Abnormal Request Results.
Status Code
- Normal
- Abnormal
For details, see Status Codes.
Error Code
For details, see Error Codes.