Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Deprecation warnings for auto detecting cloud providers#51312

Merged
k8s-github-robot merged 1 commit into
kubernetes:masterfrom
andrewsykim:50986
Aug 29, 2017
Merged

Deprecation warnings for auto detecting cloud providers#51312
k8s-github-robot merged 1 commit into
kubernetes:masterfrom
andrewsykim:50986

Conversation

@andrewsykim
Copy link
Copy Markdown
Member

What this PR does / why we need it:
Adds deprecation warnings for auto detecting cloud providers. As part of the initiative for out-of-tree cloud providers, this feature is conflicting since we're shifting the dependency of kubernetes core into cAdvisor. In the future kubelets should be using --cloud-provider=external or no cloud provider at all.

Which issue this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged): fixes #50986

Special notes for your reviewer:
NOTE: I still have to coordinate with sig-node and kubernetes-dev to get approval for this deprecation, I'm only opening this PR since we're close to code freeze and it's something presentable.

Release note:

Deprecate auto detecting cloud providers in kubelet. Auto detecting cloud providers go against the initiative for out-of-tree cloud providers as we'll now depend on cAdvisor integrations with cloud providers instead of the core repo. In the near future, `--cloud-provider` for kubelet will either be an empty string or `external`. 

@k8s-ci-robot k8s-ci-robot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Aug 25, 2017
@andrewsykim
Copy link
Copy Markdown
Member Author

/sig node

@k8s-ci-robot k8s-ci-robot added the sig/node Categorizes an issue or PR as relevant to SIG Node. label Aug 25, 2017
@k8s-github-robot k8s-github-robot added the release-note Denotes a PR that will be considered when it comes time to generate release notes. label Aug 25, 2017
@andrewsykim
Copy link
Copy Markdown
Member Author

Copy link
Copy Markdown
Contributor

@mtaufen mtaufen left a comment

Choose a reason for hiding this comment

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

couple comments otherwise looks good

Comment thread cmd/kubelet/app/options/options.go Outdated
// with cloud providers instead of in the core repo.
// More details here: https://github.com/kubernetes/kubernetes/issues/50986
CloudProvider: v1alpha1.AutoDetectCloudProvider,
RootDirectory: v1alpha1.DefaultRootDir,
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.

Might be better to move RootDirectory above the comment?

"If --tls-cert-file and --tls-private-key-file are provided, this flag will be ignored.")

fs.StringVar(&f.CloudProvider, "cloud-provider", f.CloudProvider, "The provider for cloud services. By default, kubelet will attempt to auto-detect the cloud provider. Specify empty string for running with no cloud provider.")
fs.StringVar(&f.CloudProvider, "cloud-provider", f.CloudProvider, "The provider for cloud services. By default, kubelet will attempt to auto-detect the cloud provider (deprecated). Specify empty string for running with no cloud provider, this will be the default in upcoming releases.")
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.

Please add a MarkDeprecated e.g. fs.MarkDeprecated("cloud-provider", "Specify empty string for running with no cloud provider, this will be the default in upcoming releases.")

And maybe make the StringVar doc string start with "Deprecated", so it's super-obvious.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

@mtaufen Don't want users thinking we're deprecating the cloud-provider flag if we start the flag descrption with "DEPRECATED". Do you forsee that as a problem?

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.

Oh duh. I see your point, you aren't deprecating the entire flag.
Can we at least print a deprecation warning when people use the auto-detection feature?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Yup, I'll add that

@luxas
Copy link
Copy Markdown
Member

luxas commented Aug 25, 2017

PTAL @kubernetes/sig-node-pr-reviews @kubernetes/sig-cluster-lifecycle-pr-reviews

@wlan0 @andrewsykim Did any of you send out an email to kubernetes-dev?

@k8s-ci-robot k8s-ci-robot added the sig/cluster-lifecycle Categorizes an issue or PR as relevant to SIG Cluster Lifecycle. label Aug 25, 2017
@luxas luxas added this to the v1.8 milestone Aug 25, 2017
@andrewsykim
Copy link
Copy Markdown
Member Author

@luxas will send the email out today, wanted to open the PR first so we have something concrete to show.

@andrewsykim
Copy link
Copy Markdown
Member Author

Email sent!

Copy link
Copy Markdown
Member

@luxas luxas left a comment

Choose a reason for hiding this comment

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

LGTM when @mtaufen's comments are addressed.

@andrewsykim
Copy link
Copy Markdown
Member Author

@mtaufen comments addressed

@andrewsykim
Copy link
Copy Markdown
Member Author

/test pull-kubernetes-e2e-gce-etcd3

@luxas
Copy link
Copy Markdown
Member

luxas commented Aug 26, 2017

cc @dims

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

@luxas luxas left a comment

Choose a reason for hiding this comment

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

Thanks @andrewsykim
/lgtm

@dims
Copy link
Copy Markdown
Member

dims commented Aug 26, 2017

@kubernetes/sig-node-pr-reviews

@mtaufen
Copy link
Copy Markdown
Contributor

mtaufen commented Aug 28, 2017

/lgtm

@yujuhong
Copy link
Copy Markdown
Contributor

/approve

@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 28, 2017
@vishh
Copy link
Copy Markdown
Contributor

vishh commented Aug 28, 2017

/approve

@k8s-github-robot
Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: andrewsykim, luxas, mtaufen, vishh, yujuhong

Associated issue: 50986

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

Details 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

@fejta-bot
Copy link
Copy Markdown

/retest
This bot automatically retries jobs that failed/flaked on approved PRs (send feedback to @fejta).

Review the full test history for this PR.

@k8s-github-robot
Copy link
Copy Markdown

Automatic merge from submit-queue (batch tested with PRs 50932, 49610, 51312, 51415, 50705)

@k8s-github-robot k8s-github-robot merged commit 7c70dec into kubernetes:master Aug 29, 2017
dims added a commit to dims/kubernetes that referenced this pull request Dec 4, 2017
Following up on PR kubernetes#53573 and PR kubernetes#51312, Let's drop all code
related to auto-detection for v1.10.
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. sig/cluster-lifecycle Categorizes an issue or PR as relevant to SIG Cluster Lifecycle. sig/node Categorizes an issue or PR as relevant to SIG Node. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Remove --cloud-provider=auto-detect

10 participants