Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .changesets/feat_helm_rollingupdate.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
### Support providing RollingUpdate maxSurge and maxUnavailable values ([Issue #5664](https://github.com/apollographql/router/issues/5664))

RollingUpdate maxSurge and maxUnavailable are commonly used deployment configuration values. This change makes their
values able to be set via the router helm chart.

By [Jon Christiansen](https://github.com/theJC) in https://github.com/apollographql/router/pull/5665
10 changes: 10 additions & 0 deletions helm/chart/router/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -172,3 +172,13 @@ spec:
topologySpreadConstraints:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- if .Values.rollingUpdate }}
strategy:
rollingUpdate:
{{- if (hasKey .Values.rollingUpdate "maxUnavailable") }}
maxUnavailable: {{ .Values.rollingUpdate.maxUnavailable }}
{{- end }}
{{- if (hasKey .Values.rollingUpdate "maxSurge") }}
maxSurge: {{ .Values.rollingUpdate.maxSurge }}
{{- end }}
{{- end }}
Comment thread
theJC marked this conversation as resolved.
Outdated
9 changes: 9 additions & 0 deletions helm/chart/router/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,15 @@ autoscaling:
# type: cpu
# targetUtilizationPercentage: 75


rollingUpdate:
{}
# Adjust rolling update strategy. Can take absolute values or % values.
# (https://kubernetes.io/docs/concepts/workloads/controllers/deployment/#rolling-update-deployment)
# Defaults if not set are:
# maxUnavailable: 25%
# maxSurge: 25%

Comment on lines +222 to +230

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would be nice to have line 224 moved to line 221 and specified as a helm-docs style comment

@theJC theJC Jul 27, 2024

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've adjusted and used helm-doc style comment per your feedback.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@garypen - are you good with this PR now with the adjustment made?

@theJC theJC Aug 13, 2024

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@garypen or @BrynCooke -- Sorry for the harassment, but can we get this merged in. I have at least one more PR I'd like to submit, but I'd like this one settled first before I do so.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@theJC Sorry about the delay, I've been on vacation.

nodeSelector: {}

tolerations: []
Expand Down