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

Adjust log levels for cloud provider interface calls #250

Merged
merged 1 commit into from
Sep 10, 2019

Conversation

andrewsykim
Copy link
Member

@andrewsykim andrewsykim commented Sep 10, 2019

Signed-off-by: Andrew Sy Kim kiman@vmware.com

What this PR does / why we need it:
Increases log level for calling Instances() and Zones() interface, log warning for unsupported cloud provider features. For interfaces we know we support, that should be a higher log level (proposed 6 in this PR) and for unsupported interfaces we should log a warning.

IMO Info.V(1) is way too verbose for every time Instances() is called from the cloud provider controllers, for example this is what the logs look like using just --v=2

I0910 02:14:38.430932       1 cloud.go:101] Enabling Instances interface on vSphere cloud provider
I0910 02:14:38.431043       1 cloud.go:101] Enabling Instances interface on vSphere cloud provider
I0910 02:14:38.435543       1 instances.go:189] VM=423043aa-9350-db86-50a2-ee8f4fca1647 IsActive=true
I0910 02:14:38.435559       1 instances.go:158] instances.InstanceExistsByProviderID() CACHED with 423043aa-9350-db86-50a2-ee8f4fca1647
I0910 02:14:43.435717       1 cloud.go:101] Enabling Instances interface on vSphere cloud provider
I0910 02:14:43.435754       1 cloud.go:101] Enabling Instances interface on vSphere cloud provider
I0910 02:14:43.439921       1 instances.go:189] VM=423043aa-9350-db86-50a2-ee8f4fca1647 IsActive=true
I0910 02:14:43.439943       1 instances.go:158] instances.InstanceExistsByProviderID() CACHED with 423043aa-9350-db86-50a2-ee8f4fca1647
I0910 02:14:48.440090       1 cloud.go:101] Enabling Instances interface on vSphere cloud provider
I0910 02:14:48.440126       1 cloud.go:101] Enabling Instances interface on vSphere cloud provider
I0910 02:14:48.444040       1 instances.go:189] VM=423043aa-9350-db86-50a2-ee8f4fca1647 IsActive=true
I0910 02:14:48.444064       1 instances.go:158] instances.InstanceExistsByProviderID() CACHED with 423043aa-9350-db86-50a2-ee8f4fca1647

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

Special notes for your reviewer:

Release note:

… warning for unsupported cloud provider features

Signed-off-by: Andrew Sy Kim <kiman@vmware.com>
@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 Sep 10, 2019
@andrewsykim
Copy link
Member Author

/assign @dvonthenen

@davidvonthenen
Copy link
Contributor

/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 Sep 10, 2019
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: dvonthenen

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

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 10, 2019
@k8s-ci-robot k8s-ci-robot merged commit a4146dc into kubernetes:master Sep 10, 2019
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. 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.

3 participants