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

Change default update strategy to rolling update #50175

Merged
merged 2 commits into from
Aug 9, 2017

Conversation

foxish
Copy link
Contributor

@foxish foxish commented Aug 4, 2017

Fixes #49604
Change default update strategy to rolling update for daemonset and statefulset in v1beta2

cc @kubernetes/sig-apps-pr-reviews @lukaszo @Kargakis

Release note:

Make rolling update the default update strategy for v1beta2.DaemonSet and v1beta2.StatefulSet

@foxish foxish self-assigned this Aug 4, 2017
@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Aug 4, 2017
@k8s-github-robot k8s-github-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. release-note Denotes a PR that will be considered when it comes time to generate release notes. labels Aug 4, 2017
@foxish foxish requested review from kow3ns and janetkuo August 4, 2017 22:31
@foxish
Copy link
Contributor Author

foxish commented Aug 4, 2017

/test pull-kubernetes-bazel

@@ -68,7 +68,8 @@ func SetDefaults_StatefulSet(obj *appsv1beta2.StatefulSet) {
}

if obj.Spec.UpdateStrategy.Type == "" {
obj.Spec.UpdateStrategy.Type = appsv1beta2.OnDeleteStatefulSetStrategyType
obj.Spec.UpdateStrategy.Type = appsv1beta2.RollingUpdateStatefulSetStrategyType
obj.Spec.UpdateStrategy.RollingUpdate = &appsv1beta2.RollingUpdateStatefulSetStrategy{}
Copy link
Contributor

Choose a reason for hiding this comment

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

Can you add a comment that this will default below to specific values? I would group the update strategy defaulting code.

@0xmichalis
Copy link
Contributor

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Aug 4, 2017
@@ -8,6 +8,8 @@ openapi_library(
name = "go_default_library",
srcs = ["doc.go"],
openapi_targets = [
"_output/dockerized/go/src/github.com/miekg/coredns/vendor/k8s.io/client-go/1.5/pkg/runtime",
Copy link
Contributor

Choose a reason for hiding this comment

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

I noticed these two lines were added by code generation and I removed them manually in #49983. Should they be included?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Should remove them. Will revert that entire file; Thanks

Copy link
Member

@kow3ns kow3ns left a comment

Choose a reason for hiding this comment

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

/lgtm

@foxish foxish force-pushed the update-strategies branch from 7ea74ea to 375ce72 Compare August 7, 2017 23:01
@k8s-github-robot k8s-github-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Aug 7, 2017
@foxish foxish force-pushed the update-strategies branch from 375ce72 to 34fee76 Compare August 7, 2017 23:05
@foxish
Copy link
Contributor Author

foxish commented Aug 7, 2017

@smarterclayton PTAL for approval

@foxish
Copy link
Contributor Author

foxish commented Aug 8, 2017

/test pull-kubernetes-e2e-gce-etcd3
/test pull-kubernetes-unit

@foxish foxish removed their assignment Aug 8, 2017
@foxish
Copy link
Contributor Author

foxish commented Aug 8, 2017

/test pull-kubernetes-e2e-gce-etcd3

@bgrant0607
Copy link
Member

@foxish

The commits should be squashed.

Were the comments in types.go already updated to reflect the new default values?

@kow3ns
Copy link
Member

kow3ns commented Aug 8, 2017

@bgrant0607 None of the workloads API objects list a default value for updateStrategy fields. I'd prefer to issue a separate PR to clean this up for all of the API objects at once.

@foxish foxish force-pushed the update-strategies branch from 34fee76 to 37091c3 Compare August 8, 2017 22:24
@foxish
Copy link
Contributor Author

foxish commented Aug 9, 2017

@bgrant0607, PTAL. Discussed with @kow3ns offline. Updated the fields to indicate the new defaults;

@kow3ns
Copy link
Member

kow3ns commented Aug 9, 2017

@foxish as per our discussion this looks correct and consistent to me. We should consider if updateStrategy also gets a comment for the default materialization of the struct in a separate PR.

@bgrant0607
Copy link
Member

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Aug 9, 2017
@k8s-github-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: bgrant0607, foxish, kargakis, kow3ns

Associated issue: 49604

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these OWNERS Files:

You can indicate your approval by writing /approve in a comment
You can cancel your approval by writing /approve cancel in a comment

@k8s-github-robot k8s-github-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 9, 2017
@k8s-github-robot
Copy link

/test all [submit-queue is verifying that this PR is safe to merge]

@k8s-github-robot
Copy link

Automatic merge from submit-queue

@k8s-github-robot k8s-github-robot merged commit 3d91ba5 into kubernetes:master Aug 9, 2017
@foxish foxish deleted the update-strategies branch August 9, 2017 07:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants