CCE Advanced HPA¶
Add-on Overview¶
CCE Advanced HPA (cce-hpa-controller) is an in-house add-on, which can be used to flexibly scale in or out Deployments based on metrics such as CPU usage and memory usage.
Add-on Parameters¶
Parameter | Mandatory | Type | Description |
---|---|---|---|
basic | No | object | Basic configuration parameters, which do not need to be specified |
flavor | Yes | Table 2 object | Flavor parameters |
custom | Yes | Table 3 object | Custom parameters |
Parameter | Mandatory | Type | Description |
---|---|---|---|
replicas | Yes | String | Number of pods. The default value is 2. |
resources | Yes | resources object | Container resource (CPU and memory) quotas. |
Parameter | Mandatory | Type | Description |
---|---|---|---|
multiAZEnable | No | bool | Whether to enable the forcible mode of multi-AZ deployment for the deployment component. The default value is false. Deployment pods of the add-on will be forcibly scheduled to nodes in different AZs. If there are fewer AZs than pods, the extra pods will fail to run. If both multiAZEnable and multiAZBalance are set to true, the settings of multiAZBalance take effect, which means, the equivalent mode of multi-AZ deployment is used. |
multiAZBalance | No | bool | Whether to enable the equivalent mode of multi-AZ deployment for the deployment component. The default value is false. Deployment pods of the add-on are evenly scheduled to the nodes in the cluster in each AZ. If a new AZ is added, it is recommended that you increase add-on pods for cross-AZ HA deployment. With the equivalent multi-AZ deployment, the difference between the number of add-on pods in different AZs will be less than or equal to 1. If resources in one of the AZs are insufficient, pods cannot be scheduled to that AZ. |
tolerations | No | Array of Table 5 | Toleration configuration |
node_match_expressions | No | Array of Table 6 | Add-on pod affinity configuration |
Parameter | Mandatory | Type | Description |
---|---|---|---|
limitsCpu | Yes | String | CPU size limit (unit: m) |
limitsMem | Yes | String | Memory size limit (unit: Mi) |
name | Yes | String | Add-on name. The value is fixed at customedhpa-controller. |
requestsCpu | Yes | String | Requested CPU size (unit: m) |
requestsMem | Yes | String | Requested memory size (unit: Mi) |
Parameter | Mandatory | Type | Description |
---|---|---|---|
key | No | String | Taint key |
effect | No | String | Taint policy |
operator | No | String | Operator |
tolerationSeconds | No | Int | Toleration time window |
Parameter | Mandatory | Type | Description |
---|---|---|---|
key | No | String | Taint key |
values | No | List<String> | Node affinity name |
operator | No | String | Operator |
Example Request¶
{
"kind": "Addon",
"apiVersion": "v3",
"metadata": {
"annotations": {
"addon.install/type": "install"
}
},
"spec": {
"clusterID": "2292498e-******-0255ac1001ba",
"version": "1.4.2",
"addonTemplateName": "cce-hpa-controller",
"values": {
"basic": {
"basickey":"val"
},
"flavor": {
"replicas": 1,
"resources": [{
"limitsCpu": "100m",
"limitsMem": "300Mi",
"name": "customedhpa-controller",
"requestsCpu": "100m",
"requestsMem": "300Mi"
}]
},
"custom": {
"multiAZBalance": false,
"multiAZEnabled": false,
"node_match_expressions": [],
"tolerations": [{
"key": "node.kubernetes.io/not-ready",
"operator": "Exists",
"effect": "NoExecute",
"tolerationSeconds": 60
},
{
"key": "node.kubernetes.io/unreachable",
"operator": "Exists",
"effect": "NoExecute",
"tolerationSeconds": 60
}]
}
}
}
}