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

Added SMI canary deployment strategy to KubernetesManifest task #11218

Merged
merged 8 commits into from
Oct 22, 2019

Conversation

vithati
Copy link
Member

@vithati vithati commented Aug 26, 2019

Added SMI canary deployment strategy to KubernetesManifest task

@vithati vithati requested a review from thesattiraju August 26, 2019 16:54
@vithati vithati requested a review from bansalaseem as a code owner August 26, 2019 16:54
@vithati vithati requested a review from nishubansal August 26, 2019 16:55
@thesattiraju
Copy link
Contributor

Tests are failing. Could you check if the expected behavior for default ones are changing?

@thesattiraju
Copy link
Contributor

Given that this logic works only if any service mesh is enabled on the cluster, shouldn't you add a check if it exists on the cluster?

@@ -11,7 +11,10 @@
"loc.input.help.namespace": "Sets the namespace for the commands by using the –namespace flag. If the namespace is not provided, the commands will run in the default namespace.",
"loc.input.label.strategy": "Strategy",
"loc.input.help.strategy": "Deployment strategy to be used",
"loc.input.label.trafficSplitMethod": "Traffic split method",
"loc.input.help.trafficSplitMethod": "Deployment strategy to be used",
Copy link
Member

Choose a reason for hiding this comment

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

Label and help are looking like related. Can we add some more details in 'Help'.

Copy link
Member Author

Choose a reason for hiding this comment

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

i will check with PM and will add.

Tasks/KubernetesManifestV0/src/actions/promote.ts Outdated Show resolved Hide resolved
Tasks/KubernetesManifestV0/task.json Outdated Show resolved Hide resolved
Tasks/KubernetesManifestV0/src/actions/promote.ts Outdated Show resolved Hide resolved
Tasks/KubernetesManifestV0/src/actions/reject.ts Outdated Show resolved Hide resolved
Tasks/KubernetesManifestV0/task.json Outdated Show resolved Hide resolved
Tasks/KubernetesManifestV0/task.json Outdated Show resolved Hide resolved
@vithati vithati force-pushed the users/vithati/k8sm branch from dbb4f20 to e6ffc58 Compare October 21, 2019 20:20
"apiVersion": "split.smi-spec.io/v1alpha1",
"kind": "TrafficSplit",
"metadata": {
"name": "%s"
Copy link
Contributor

Choose a reason for hiding this comment

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

You could directly use ` and replace it here instead of using formatter

// In case of SMI traffic split strategy when deployment is promoted, first we will redirect traffic to
// Canary deployment, then update stable deployment and then redirect traffic to stable deployment
tl.debug('Redirecting traffic to canary deployment');
SMICanaryDeploymentHelper.redirectTrafficToCanaryDeployment(kubectl, TaskInputParameters.manifests);
Copy link
Member

Choose a reason for hiding this comment

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

Just want to confirm, Redirecting entire traffic to canary during promote, how are we making sure Canary pods can handle that much traffic?

Copy link
Member Author

Choose a reason for hiding this comment

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

In SMI, first you will redirect traffic to other deploymnt(canary) before updating stable. Generally customer will increase the canary pods before updating stable one.

Tasks/KubernetesManifestV0/src/utils/FileHelper.ts Outdated Show resolved Hide resolved
@vithati vithati force-pushed the users/vithati/k8sm branch from 9c0a66b to 09ca9a4 Compare October 22, 2019 12:52
@vithati vithati merged commit 25a9340 into master Oct 22, 2019
@vithati vithati deleted the users/vithati/k8sm branch October 22, 2019 13:00
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.

3 participants