Updated on 2024-07-10 GMT+08:00

Upgrading an Instance

Function

This API is used to upgrading the instance kernel.

Calling Method

For details, see Calling APIs.

URI

POST /v2/{project_id}/kafka/instances/{instance_id}/upgrade

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Project ID. For details, see Obtaining a Project ID.

instance_id

Yes

String

Instance ID.

Request Parameters

Table 2 Request body parameters

Parameter

Mandatory

Type

Description

is_schedule

No

Boolean

Indicates whether the task is scheduled. If no, is_schedule and execute_at can be left blank. If yes, is_schedule is true and execute_at must be specified.

execute_at

No

Long

Schedule time. The value is a UNIX timestamp, in ms.

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

-

String

ID of the submitted upgrade task.

Status code: 400

Table 4 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error description.

Example Requests

Upgrading an instance whose ID is instance_id

POST https://{endpoint}/v2/{project_id}/kafka/instances/{instance_id}/upgrade

{
  "is_schedule" : true,
  "execute_at" : 1695796358970
}

Example Responses

Status code: 200

Successful

93b94287-728d-4bb1-a158-cb66cb0854e7

Status Codes

Status Code

Description

200

Successful

400

Failed

Error Codes

See Error Codes.