From 22575d4c620a1c3938150e1498795b70bfb25f7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment?= <16559029+clementlecorre@users.noreply.github.com> Date: Mon, 22 Nov 2021 10:32:27 +0100 Subject: [PATCH] feat(argo-workflows): support resourceRateLimit config (#1008) * feat(argo-workflows): add `resourceRateLimit` config Signed-off-by: clement * chore: update chart version Signed-off-by: clement * chore(linter): add new line Signed-off-by: clement * chore: bump chart helm 0.9.0 Signed-off-by: clement --- charts/argo-workflows/Chart.yaml | 4 ++-- charts/argo-workflows/README.md | 1 + .../controller/workflow-controller-config-map.yaml | 3 +++ charts/argo-workflows/values.yaml | 7 +++++++ 4 files changed, 13 insertions(+), 2 deletions(-) diff --git a/charts/argo-workflows/Chart.yaml b/charts/argo-workflows/Chart.yaml index 866975e6..ed425839 100644 --- a/charts/argo-workflows/Chart.yaml +++ b/charts/argo-workflows/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v2 name: argo-workflows description: A Helm chart for Argo Workflows type: application -version: 0.8.3 +version: 0.9.0 appVersion: v3.2.4 icon: https://raw.githubusercontent.com/argoproj/argo-workflows/master/docs/assets/argo.png home: https://github.com/argoproj/argo-helm @@ -15,4 +15,4 @@ maintainers: - name: benjaminws annotations: artifacthub.io/changes: | - - "[Changed]: Update to app version v3.2.4" + - "[Added]: support resourceRateLimit config" diff --git a/charts/argo-workflows/README.md b/charts/argo-workflows/README.md index 098bad79..f86d3d6c 100644 --- a/charts/argo-workflows/README.md +++ b/charts/argo-workflows/README.md @@ -94,6 +94,7 @@ Fields to note: | controller.podWorkers | string | `nil` | Number of pod workers | | controller.priorityClassName | string | `""` | Leverage a PriorityClass to ensure your pods survive resource shortages. | | controller.replicas | int | `1` | The number of controller pods to run | +| controller.resourceRateLimit | object | `{}` | Globally limits the rate at which pods are created. This is intended to mitigate flooding of the Kubernetes API server by workflows with a large amount of parallel nodes. | | controller.resources | object | `{}` | Resource limits and requests for the controller | | controller.securityContext | object | `{"allowPrivilegeEscalation":false,"capabilities":{"drop":["ALL"]},"readOnlyRootFilesystem":true,"runAsNonRoot":true}` | the controller container's securityContext | | controller.serviceAccount.annotations | object | `{}` | Annotations applied to created service account | diff --git a/charts/argo-workflows/templates/controller/workflow-controller-config-map.yaml b/charts/argo-workflows/templates/controller/workflow-controller-config-map.yaml index 77214546..c09a0dc9 100644 --- a/charts/argo-workflows/templates/controller/workflow-controller-config-map.yaml +++ b/charts/argo-workflows/templates/controller/workflow-controller-config-map.yaml @@ -21,6 +21,9 @@ data: {{- if .Values.controller.parallelism }} parallelism: {{ .Values.controller.parallelism }} {{- end }} + {{- if .Values.controller.resourceRateLimit }} + resourceRateLimit: {{ toYaml .Values.controller.resourceRateLimit | nindent 6 }} + {{- end }} {{- with .Values.controller.namespaceParallelism }} namespaceParallelism: {{ . }} {{- end }} diff --git a/charts/argo-workflows/values.yaml b/charts/argo-workflows/values.yaml index bf336a4e..6548ead4 100644 --- a/charts/argo-workflows/values.yaml +++ b/charts/argo-workflows/values.yaml @@ -49,6 +49,13 @@ controller: tag: "" # -- parallelism dictates how many workflows can be running at the same time parallelism: + # -- Globally limits the rate at which pods are created. + # This is intended to mitigate flooding of the Kubernetes API server by workflows with a large amount of + # parallel nodes. + resourceRateLimit: {} + # limit: 10 + # burst: 1 + # -- Limits the maximum number of incomplete workflows in a namespace namespaceParallelism: # -- Resolves ongoing, uncommon AWS EKS bug: https://github.com/argoproj/argo-workflows/pull/4224