Updates the configuration of an application in a Container Service for Kubernetes (ACK) or Serverless Kubernetes cluster.
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action
policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- The required resource types are displayed in bold characters.
- If the permissions cannot be granted at the resource level,
All Resources
is used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
edas:ManageApplication | Write |
|
| none |
Request syntax
PUT /pop/v5/k8s/acs/k8s_app_configuration
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
AppId | string | Yes | The ID of the application. You can query the application ID by calling the ListApplication operation. For more information, see ListApplication . | 23bf94d9-****-4994-9917-616a827aa777 |
ClusterId | string | Yes | The ID of the cluster. You can query the cluster ID by calling the ListCluster operation. For more information, see ListCluster . | 9c28bbb9-****-44b3-b953-54ef8a2d0be2 |
CpuLimit | string | Yes | The maximum number of CPU cores allowed for each application instance when the application is running. The value 0 indicates that no limit is set on CPU cores. | 1 |
MemoryLimit | string | Yes | The maximum size of memory allowed for each application instance when the application is running. Unit: MB. The value 0 indicates that no limit is set on the memory size. | 4 |
McpuLimit | string | No | The maximum number of CPU cores allowed. The value 0 indicates that no limit is set on CPU cores. | 1 |
CpuRequest | string | No | The number of CPU cores requested for each application instance when the application is running. Unit: cores. We recommend that you set this parameter. The value 0 indicates that no limit is set on CPU cores. Note
You must set this parameter together with the CpuLimit parameter. Make sure that the value of this parameter does not exceed that of the CpuLimit parameter.
| 1 |
McpuRequest | string | No | The minimum number of CPU cores required. Unit: cores. The value 0 indicates that no limit is set on CPU cores. Note
You must set this parameter together with the CpuLimit parameter. Make sure that the value of this parameter does not exceed that of the CpuLimit parameter.
| 1000 |
MemoryRequest | string | No | The size of memory requested for each application instance when the application is running. Unit: MB. We recommend that you set this parameter. If you do not want to apply for a memory quota, set this parameter to 0. Note
You must set this parameter together with the MemoryLimit parameter. Make sure that the value of this parameter does not exceed that of the MemoryLimit parameter.
| 400 |
Timeout | integer | No | The timeout period of the change process. Valid values: 1 to 1800. Default value: 600. Unit: seconds. | 60 |
EphemeralStorageRequest | string | No | The minimum size of space required by ephemeral storage. Unit: GB. The value 0 indicates that no limit is set on the ephemeral storage space. Note
You must set this parameter together with the EphemeralStorageLimit parameter. Make sure that the value of this parameter does not exceed that of the EphemeralStorageLimit parameter.
| 2 |
EphemeralStorageLimit | string | No | The maximum size of space required by ephemeral storage. Unit: GB. The value 0 indicates that no limit is set on the ephemeral storage space. | 4 |
Response parameters
Examples
Sample success responses
JSON
format
{
"ChangeOrderId": "8806d1c6-****-48eb-9373-6bdef3007466",
"Code": 200,
"Message": "success",
"RequestId": "4823-bhjf-23u4-****"
}
Error codes
HTTP status code | Error code | Error message |
---|---|---|
400 | Edas.errorcode.K8SAppConfiguration.UpdateFail | Failed to set app configuration. |
For a list of error codes, visit the Service error codes.