Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add AnalysisTemplate & update logic for canary rollout strategy #46

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

j-jasmin
Copy link

@j-jasmin j-jasmin commented Apr 22, 2024

Changes made:

  • make stable(Service|Metadata) and canary(Service|Metadata) depending on whether useTrafficRouting is true for a canary rollout
  • make preview service creation depending on whether useTrafficRouting is true or rollout.strategy is BlueGreen
  • add steps to control progress of canary rollouts
  • add option to create AnalysisTemplate
  • add option to subscribe on rollout events and sent slack notifications
  • add progressDeadlineSeconds with default kubernetes value
  • add minReadySeconds with default kubernetes value
  • add progressDeadlineAbort for argo rollouts

@j-jasmin j-jasmin marked this pull request as draft April 22, 2024 13:13
@j-jasmin j-jasmin marked this pull request as ready for review April 22, 2024 13:16
@j-jasmin j-jasmin marked this pull request as draft April 23, 2024 16:05
@j-jasmin j-jasmin force-pushed the canary-rollout branch 2 times, most recently from 175a67c to 9f69f14 Compare April 26, 2024 08:02
@j-jasmin j-jasmin marked this pull request as ready for review April 26, 2024 08:03
charts/generic-service/README.md Outdated Show resolved Hide resolved
charts/generic-service/values.schema.json Outdated Show resolved Hide resolved
charts/generic-service/values.schema.json Outdated Show resolved Hide resolved
charts/generic-service/values.schema.json Outdated Show resolved Hide resolved
{{- with .Values.rollout.notifications }}
{{- range $event, $channels := . }}
{{- range $channel := $channels }}
notifications.argoproj.io/subscribe.{{ $event }}.slack: {{ join ";" $channels | quote }}
Copy link
Member

Choose a reason for hiding this comment

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

I'd prefer to keep this more generalized, since not everybody uses Slack for notifications. Perhaps we could just use the existing annotations for this?

Copy link
Author

Choose a reason for hiding this comment

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

Yeah that's what I initially wanted to do but it would add the annotation to all resources while it would be only needed for Rollout?

Copy link
Member

Choose a reason for hiding this comment

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

generic-service applies labels to all resources but annotations only to the resource created in controller.yaml, Rollout in this case.

Copy link
Author

Choose a reason for hiding this comment

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

removed it 👍

charts/generic-service/values.schema.json Show resolved Hide resolved
@j-jasmin j-jasmin force-pushed the canary-rollout branch 5 times, most recently from b71ef98 to 48efa9e Compare May 3, 2024 07:21
Comment on lines 63 to 65
{{- with .Values.rollout.analysis -}}
analysis: {{- . | toYaml | nindent 8 }}
{{- end }}
Copy link
Member

Choose a reason for hiding this comment

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

with doesn't seem necessary here.

Indent seems to be too deep. Would put analysis under trafficRouting.

Suggested change
{{- with .Values.rollout.analysis -}}
analysis: {{- . | toYaml | nindent 8 }}
{{- end }}
analysis: {{- .Values.rollout.analysis | toYaml | nindent 8 }}

Copy link
Author

Choose a reason for hiding this comment

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

analysis is an optional field (with or without traffic routing). see rollout specs

Copy link
Member

@bastianeicher bastianeicher May 4, 2024

Choose a reason for hiding this comment

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

Then perhaps like this?

Suggested change
{{- with .Values.rollout.analysis -}}
analysis: {{- . | toYaml | nindent 8 }}
{{- end }}
{{- if .Values.rollout.analysis }}
analysis: {{- . | toYaml | nindent 8 }}
{{- end }}

charts/generic-service/templates/controller.yaml Outdated Show resolved Hide resolved
charts/generic-service/templates/controller.yaml Outdated Show resolved Hide resolved
charts/generic-service/templates/controller.yaml Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants