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

feat: support scaleDownDelaySeconds in canary w/ traffic routing #1056

Merged
merged 5 commits into from
Apr 19, 2021

Conversation

jessesuen
Copy link
Member

Resolves #478

This change introduces scaleDownDelaySeconds and scaleDownDelayRevisionLimit to the canary strategy when used with traffic routing:

  strategy:
    canary:
      scaleDownDelaySeconds: 30        # default 30s
      scaleDownDelayRevisionLimit: 1
      trafficRouting:
...

The purpose of a scaleDownDelaySeconds for canary with traffic routing, is the same reason for blue-green scaleDownDelaySeconds. We want to avoid scaling down the stable stack prematurely in order to give some time for service selectors to propagate to mesh providers and ingress controllers, and avoid 500 errors. This change will introduce a default 30s delay before scaling down stable stack just like in blue-green.

@jessesuen jessesuen force-pushed the canary-scaleDownDelay branch from 071cf7d to f1b8494 Compare April 2, 2021 10:11
@codecov
Copy link

codecov bot commented Apr 2, 2021

Codecov Report

Merging #1056 (506a6af) into master (1fa63d7) will decrease coverage by 0.00%.
The diff coverage is 82.58%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1056      +/-   ##
==========================================
- Coverage   81.24%   81.23%   -0.01%     
==========================================
  Files         103      103              
  Lines        9192     9243      +51     
==========================================
+ Hits         7468     7509      +41     
- Misses       1229     1233       +4     
- Partials      495      501       +6     
Impacted Files Coverage Δ
rollout/replicaset.go 63.33% <71.42%> (+3.63%) ⬆️
rollout/canary.go 78.87% <74.07%> (-4.61%) ⬇️
rollout/bluegreen.go 70.91% <85.18%> (+0.35%) ⬆️
utils/defaults/defaults.go 87.03% <88.88%> (-0.72%) ⬇️
rollout/sync.go 74.78% <90.47%> (+2.41%) ⬆️
pkg/apis/rollouts/validation/validation.go 90.25% <100.00%> (+0.12%) ⬆️
pkg/kubectl-argo-rollouts/info/rollout_info.go 79.04% <100.00%> (+0.12%) ⬆️
rollout/trafficrouting/istio/istio.go 79.91% <100.00%> (+0.26%) ⬆️
utils/replicaset/replicaset.go 89.70% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1fa63d7...506a6af. Read the comment docs.

@jessesuen jessesuen force-pushed the canary-scaleDownDelay branch 3 times, most recently from 9bec8b0 to 41bdf97 Compare April 6, 2021 11:25
@jessesuen jessesuen marked this pull request as ready for review April 6, 2021 11:26
@jessesuen jessesuen requested a review from khhirani April 6, 2021 11:26
@jessesuen jessesuen force-pushed the canary-scaleDownDelay branch 2 times, most recently from 27a7af2 to bf6d749 Compare April 9, 2021 06:10
Copy link
Contributor

@khhirani khhirani left a comment

Choose a reason for hiding this comment

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

LGTM

@jessesuen jessesuen force-pushed the canary-scaleDownDelay branch from bf6d749 to a0f595e Compare April 9, 2021 21:24
@jessesuen jessesuen force-pushed the canary-scaleDownDelay branch 2 times, most recently from 7cdcfc5 to eacb4af Compare April 19, 2021 21:18
Signed-off-by: Jesse Suen <[email protected]>
@jessesuen jessesuen force-pushed the canary-scaleDownDelay branch from eacb4af to 506a6af Compare April 19, 2021 21:23
@sonarcloud
Copy link

sonarcloud bot commented Apr 19, 2021

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 2 Code Smells

No Coverage information No Coverage information
2.6% 2.6% Duplication

@jessesuen jessesuen merged commit 31afa28 into argoproj:master Apr 19, 2021
@jessesuen jessesuen deleted the canary-scaleDownDelay branch April 19, 2021 21:57
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.

Introduce scaleDownDelay in canary (with traffic routing)
2 participants