diff --git a/hack/.golint_failures b/hack/.golint_failures index c6f0382aca..7d0db783d2 100644 --- a/hack/.golint_failures +++ b/hack/.golint_failures @@ -71,7 +71,6 @@ pkg/capabilities pkg/cloudprovider/providers/fake pkg/cloudprovider/providers/photon pkg/cloudprovider/providers/vsphere -pkg/cloudprovider/providers/vsphere/vclib pkg/controller pkg/controller/apis/config/v1alpha1 pkg/controller/bootstrap @@ -161,10 +160,7 @@ pkg/kubelet/apis pkg/kubelet/apis/config pkg/kubelet/apis/config/v1beta1 pkg/kubelet/apis/cri/testing -pkg/kubelet/apis/deviceplugin/v1alpha pkg/kubelet/apis/deviceplugin/v1beta1 -pkg/kubelet/apis/pluginregistration/v1alpha1 -pkg/kubelet/apis/pluginregistration/v1beta1 pkg/kubelet/cadvisor pkg/kubelet/cadvisor/testing pkg/kubelet/checkpoint diff --git a/pkg/cloudprovider/providers/vsphere/vclib/connection_test.go b/pkg/cloudprovider/providers/vsphere/vclib/connection_test.go index 1567e9e28f..3e34886060 100644 --- a/pkg/cloudprovider/providers/vsphere/vclib/connection_test.go +++ b/pkg/cloudprovider/providers/vsphere/vclib/connection_test.go @@ -85,7 +85,7 @@ func TestWithValidCaCert(t *testing.T) { server, _ := createTestServer(t, fixtures.CaCertPath, fixtures.ServerCertPath, fixtures.ServerKeyPath, handler) server.StartTLS() - u := mustParseUrl(t, server.URL) + u := mustParseURL(t, server.URL) connection := &vclib.VSphereConnection{ Hostname: u.Hostname(), @@ -104,7 +104,7 @@ func TestWithVerificationWithWrongThumbprint(t *testing.T) { server, _ := createTestServer(t, fixtures.CaCertPath, fixtures.ServerCertPath, fixtures.ServerKeyPath, handler) server.StartTLS() - u := mustParseUrl(t, server.URL) + u := mustParseURL(t, server.URL) connection := &vclib.VSphereConnection{ Hostname: u.Hostname(), @@ -124,7 +124,7 @@ func TestWithVerificationWithoutCaCertOrThumbprint(t *testing.T) { server, _ := createTestServer(t, fixtures.CaCertPath, fixtures.ServerCertPath, fixtures.ServerKeyPath, handler) server.StartTLS() - u := mustParseUrl(t, server.URL) + u := mustParseURL(t, server.URL) connection := &vclib.VSphereConnection{ Hostname: u.Hostname(), @@ -142,7 +142,7 @@ func TestWithValidThumbprint(t *testing.T) { server, thumbprint := createTestServer(t, fixtures.CaCertPath, fixtures.ServerCertPath, fixtures.ServerKeyPath, handler) server.StartTLS() - u := mustParseUrl(t, server.URL) + u := mustParseURL(t, server.URL) connection := &vclib.VSphereConnection{ Hostname: u.Hostname(), @@ -213,7 +213,7 @@ func getRequestVerifier(t *testing.T) (http.HandlerFunc, func()) { return handler, checker } -func mustParseUrl(t *testing.T, i string) *url.URL { +func mustParseURL(t *testing.T, i string) *url.URL { u, err := url.Parse(i) if err != nil { t.Fatalf("Cannot parse URL: %v", err) diff --git a/pkg/kubelet/apis/deviceplugin/v1alpha/constants.go b/pkg/kubelet/apis/deviceplugin/v1alpha/constants.go index 34e8847fa2..7c1ebdfa2d 100644 --- a/pkg/kubelet/apis/deviceplugin/v1alpha/constants.go +++ b/pkg/kubelet/apis/deviceplugin/v1alpha/constants.go @@ -22,7 +22,7 @@ const ( // Unhealthy means that the device is unhealthy Unhealthy = "Unhealthy" - // Current version of the API supported by kubelet + // Version is the current version of the API supported by kubelet Version = "v1alpha2" // DevicePluginPath is the folder the Device Plugin is expecting sockets to be on // Only privileged pods have access to this path diff --git a/pkg/kubelet/apis/pluginregistration/v1alpha1/constants.go b/pkg/kubelet/apis/pluginregistration/v1alpha1/constants.go index cfc1b7c6d7..7708f758fa 100644 --- a/pkg/kubelet/apis/pluginregistration/v1alpha1/constants.go +++ b/pkg/kubelet/apis/pluginregistration/v1alpha1/constants.go @@ -17,6 +17,8 @@ limitations under the License. package pluginregistration const ( - CSIPlugin = "CSIPlugin" + // CSIPlugin identifier for registered CSI plugins + CSIPlugin = "CSIPlugin" + // DevicePlugin identifier for registered device plugins DevicePlugin = "DevicePlugin" ) diff --git a/pkg/kubelet/apis/pluginregistration/v1beta1/constants.go b/pkg/kubelet/apis/pluginregistration/v1beta1/constants.go index cfc1b7c6d7..7708f758fa 100644 --- a/pkg/kubelet/apis/pluginregistration/v1beta1/constants.go +++ b/pkg/kubelet/apis/pluginregistration/v1beta1/constants.go @@ -17,6 +17,8 @@ limitations under the License. package pluginregistration const ( - CSIPlugin = "CSIPlugin" + // CSIPlugin identifier for registered CSI plugins + CSIPlugin = "CSIPlugin" + // DevicePlugin identifier for registered device plugins DevicePlugin = "DevicePlugin" )