Upgrading the Database Patch
API Description
This API is used to upgrade the database patch version.
Restrictions
- This API is not available to frozen or abnormal instances.
- This API is not available if there are abnormal instance nodes.
- View field patch_available in the result returned by the API for querying instance details and check whether a minor version upgrade is supported.
- Perform an upgrade during off-peak hours.
URI
- URI format
POST https://{Endpoint}/v3/{project_id}/instances/{instance_id}/db-upgrade
- URI example
https://dds.cn-north-1.myhuaweicloud.com/v3/054e292c9880d4992f02c0196d3ea468/instances/054e292c9880d4992f02c0196d3ein02/db-upgrade
Table 1 Request parameters Name
Mandatory
Type
Description
project_id
Yes
String
Project ID of a tenant in a region. To obtain the project ID, see Obtaining a Project ID.
instance_id
Yes
String
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 a DB Instance to create one.
Requests
- Request parameters
Table 2 Request header parameters Name
Mandatory
Type
Description
X-Auth-Token
Yes
String
User token obtained from IAM. For details, see Authentication.
Table 3 Request body parameters Name
Mandatory
Type
Description
upgrade_mode
No
String
Upgrade mode. If this parameter is set to minimized_interrupt_time, the shortest interruption time is preferred. In this mode, the upgrade has little impact on services. If this parameter is set to minimized_upgrade_time, the shortest upgrade time is preferred. The default value is minimized_interrupt_time.
Example Request
Upgrading a database patch version and setting upgrade_mode to minimized_interrupt_time
POST https://dds.cn-north-1.myhuaweicloud.com/v3/054e292c9880d4992f02c0196d3ea468/instances/054e292c9880d4992f02c0196d3ein02/db-upgrade { "upgrade_mode" : "minimized_interrupt_time" }
Responses
- Parameter description
Table 4 Response body parameters Name
Type
Description
job_id
String
Task ID.
- Response example
{ "job_id" : "55e166d2-83ad-425f-b887-3503de03dc9b" }
Status Code
For details, see Status Code.
Error Code
For details, see Error Code.
Feedback
Was this page helpful?
Provide feedbackThank 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