From 71a58de48be918b779b8383d6427b603c5fc8401 Mon Sep 17 00:00:00 2001 From: yue9944882 <291271447@qq.com> Date: Wed, 24 Apr 2019 15:27:02 +0800 Subject: [PATCH] clean up genclient tags for hub types --- pkg/apis/admissionregistration/types.go | 4 ---- pkg/apis/apps/types.go | 5 ----- pkg/apis/auditregistration/types.go | 2 -- pkg/apis/authentication/types.go | 3 --- pkg/apis/authorization/types.go | 11 ----------- pkg/apis/autoscaling/types.go | 1 - pkg/apis/batch/types.go | 2 -- pkg/apis/certificates/types.go | 2 -- pkg/apis/coordination/types.go | 1 - pkg/apis/core/types.go | 22 ---------------------- pkg/apis/imagepolicy/types.go | 3 --- pkg/apis/networking/types.go | 2 -- pkg/apis/policy/types.go | 5 ----- pkg/apis/rbac/types.go | 6 ------ pkg/apis/scheduling/types.go | 2 -- pkg/apis/settings/types.go | 1 - pkg/apis/storage/types.go | 8 -------- 17 files changed, 80 deletions(-) diff --git a/pkg/apis/admissionregistration/types.go b/pkg/apis/admissionregistration/types.go index d642110a44d..9426267ae48 100644 --- a/pkg/apis/admissionregistration/types.go +++ b/pkg/apis/admissionregistration/types.go @@ -100,8 +100,6 @@ const ( SideEffectClassNoneOnDryRun SideEffectClass = "NoneOnDryRun" ) -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // ValidatingWebhookConfiguration describes the configuration of an admission webhook that accepts or rejects and object without changing it. @@ -128,8 +126,6 @@ type ValidatingWebhookConfigurationList struct { Items []ValidatingWebhookConfiguration } -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // MutatingWebhookConfiguration describes the configuration of and admission webhook that accept or reject and may change the object. diff --git a/pkg/apis/apps/types.go b/pkg/apis/apps/types.go index 8e40891b852..9af2f389e0f 100644 --- a/pkg/apis/apps/types.go +++ b/pkg/apis/apps/types.go @@ -23,7 +23,6 @@ import ( api "k8s.io/kubernetes/pkg/apis/core" ) -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // StatefulSet represents a set of pods with consistent identities. @@ -227,7 +226,6 @@ type StatefulSetList struct { Items []StatefulSet } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // ControllerRevision implements an immutable snapshot of state data. Clients @@ -262,7 +260,6 @@ type ControllerRevisionList struct { Items []ControllerRevision } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object type Deployment struct { @@ -644,7 +641,6 @@ type DaemonSetCondition struct { Message string } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // DaemonSet represents the configuration of a daemon set. @@ -691,7 +687,6 @@ type DaemonSetList struct { Items []DaemonSet } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // ReplicaSet ensures that a specified number of pod replicas are running at any given time. diff --git a/pkg/apis/auditregistration/types.go b/pkg/apis/auditregistration/types.go index 771ad758689..97f6bb2ef36 100644 --- a/pkg/apis/auditregistration/types.go +++ b/pkg/apis/auditregistration/types.go @@ -57,8 +57,6 @@ const ( StagePanic = "Panic" ) -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // AuditSink represents a cluster level sink for audit data diff --git a/pkg/apis/authentication/types.go b/pkg/apis/authentication/types.go index 8fc416d2bc4..0ae670d4705 100644 --- a/pkg/apis/authentication/types.go +++ b/pkg/apis/authentication/types.go @@ -36,9 +36,6 @@ const ( ImpersonateUserExtraHeaderPrefix = "Impersonate-Extra-" ) -// +genclient -// +genclient:nonNamespaced -// +genclient:noVerbs // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // TokenReview attempts to authenticate a token to a known user. diff --git a/pkg/apis/authorization/types.go b/pkg/apis/authorization/types.go index fafd1800d2d..368f37e66fa 100644 --- a/pkg/apis/authorization/types.go +++ b/pkg/apis/authorization/types.go @@ -20,9 +20,6 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) -// +genclient -// +genclient:nonNamespaced -// +genclient:noVerbs // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // SubjectAccessReview checks whether or not a user or group can perform an action. Not filling in a @@ -38,9 +35,6 @@ type SubjectAccessReview struct { Status SubjectAccessReviewStatus } -// +genclient -// +genclient:nonNamespaced -// +genclient:noVerbs // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // SelfSubjectAccessReview checks whether or the current user can perform an action. Not filling in a @@ -57,8 +51,6 @@ type SelfSubjectAccessReview struct { Status SubjectAccessReviewStatus } -// +genclient -// +genclient:noVerbs // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // LocalSubjectAccessReview checks whether or not a user or group can perform an action in a given namespace. @@ -155,9 +147,6 @@ type SubjectAccessReviewStatus struct { EvaluationError string } -// +genclient -// +genclient:nonNamespaced -// +genclient:noVerbs // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // SelfSubjectRulesReview enumerates the set of actions the current user can perform within a namespace. diff --git a/pkg/apis/autoscaling/types.go b/pkg/apis/autoscaling/types.go index 4ab6f8aff55..94d7dc883c7 100644 --- a/pkg/apis/autoscaling/types.go +++ b/pkg/apis/autoscaling/types.go @@ -379,7 +379,6 @@ type MetricValueStatus struct { AverageUtilization *int32 } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // HorizontalPodAutoscaler is the configuration for a horizontal pod diff --git a/pkg/apis/batch/types.go b/pkg/apis/batch/types.go index 8bbeae8301b..b5dd27eb3ee 100644 --- a/pkg/apis/batch/types.go +++ b/pkg/apis/batch/types.go @@ -21,7 +21,6 @@ import ( api "k8s.io/kubernetes/pkg/apis/core" ) -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // Job represents the configuration of a single job. @@ -215,7 +214,6 @@ type JobCondition struct { Message string } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // CronJob represents the configuration of a single cron job. diff --git a/pkg/apis/certificates/types.go b/pkg/apis/certificates/types.go index 77420687b0a..d4ba7fdc925 100644 --- a/pkg/apis/certificates/types.go +++ b/pkg/apis/certificates/types.go @@ -18,8 +18,6 @@ package certificates import metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // Describes a certificate signing request diff --git a/pkg/apis/coordination/types.go b/pkg/apis/coordination/types.go index 1d494e59d81..7b1078a1ee9 100644 --- a/pkg/apis/coordination/types.go +++ b/pkg/apis/coordination/types.go @@ -20,7 +20,6 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // Lease defines a lease concept. diff --git a/pkg/apis/core/types.go b/pkg/apis/core/types.go index 98a2d4ce9cc..a6f477ad230 100644 --- a/pkg/apis/core/types.go +++ b/pkg/apis/core/types.go @@ -255,8 +255,6 @@ const ( MountOptionAnnotation = "volume.beta.kubernetes.io/mount-options" ) -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object type PersistentVolume struct { @@ -363,7 +361,6 @@ type PersistentVolumeList struct { Items []PersistentVolume } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // PersistentVolumeClaim is a user's request for and claim to a persistent volume @@ -2879,7 +2876,6 @@ type PodStatusResult struct { Status PodStatus } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // Pod is a collection of containers, used as either input (create, update) or as output (list, get). @@ -2909,7 +2905,6 @@ type PodTemplateSpec struct { Spec PodSpec } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // PodTemplate describes a template for creating copies of a predefined pod. @@ -3017,9 +3012,6 @@ type ReplicationControllerCondition struct { Message string } -// +genclient -// +genclient:method=GetScale,verb=get,subresource=scale,result=k8s.io/kubernetes/pkg/apis/autoscaling.Scale -// +genclient:method=UpdateScale,verb=update,subresource=scale,input=k8s.io/kubernetes/pkg/apis/autoscaling.Scale,result=k8s.io/kubernetes/pkg/apis/autoscaling.Scale // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // ReplicationController represents the configuration of a replication controller. @@ -3293,7 +3285,6 @@ type ServicePort struct { NodePort int32 } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // Service is a named abstraction of software service (for example, mysql) consisting of local port @@ -3313,7 +3304,6 @@ type Service struct { Status ServiceStatus } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // ServiceAccount binds together: @@ -3351,7 +3341,6 @@ type ServiceAccountList struct { Items []ServiceAccount } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // Endpoints is a collection of endpoints that implement the actual service. Example: @@ -3776,8 +3765,6 @@ const ( // ResourceList is a set of (resource name, quantity) pairs. type ResourceList map[ResourceName]resource.Quantity -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // Node is a worker node in Kubernetes @@ -3839,8 +3826,6 @@ const ( NamespaceTerminating NamespacePhase = "Terminating" ) -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // A namespace provides a scope for Names. @@ -4095,7 +4080,6 @@ const ( EventTypeWarning string = "Warning" ) -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // Event is a report of an event somewhere in the cluster. @@ -4239,7 +4223,6 @@ type LimitRangeSpec struct { Limits []LimitRangeItem } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // LimitRange sets resource usage limits for each kind of resource in a Namespace @@ -4386,7 +4369,6 @@ type ResourceQuotaStatus struct { Used ResourceList } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // ResourceQuota sets aggregate quota restrictions enforced per namespace @@ -4416,7 +4398,6 @@ type ResourceQuotaList struct { Items []ResourceQuota } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // Secret holds secret data of a certain type. The total bytes of the values in @@ -4536,7 +4517,6 @@ type SecretList struct { Items []Secret } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // ConfigMap holds configuration data for components or applications to consume. @@ -4634,8 +4614,6 @@ type ComponentCondition struct { Error string } -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // ComponentStatus (and ComponentStatusList) holds the cluster validation info. diff --git a/pkg/apis/imagepolicy/types.go b/pkg/apis/imagepolicy/types.go index 834ce02edbd..11170940739 100644 --- a/pkg/apis/imagepolicy/types.go +++ b/pkg/apis/imagepolicy/types.go @@ -20,9 +20,6 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) -// +genclient -// +genclient:nonNamespaced -// +genclient:noVerbs // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // ImageReview checks if the set of images in a pod are allowed. diff --git a/pkg/apis/networking/types.go b/pkg/apis/networking/types.go index 43233039d84..b0da20cee3c 100644 --- a/pkg/apis/networking/types.go +++ b/pkg/apis/networking/types.go @@ -22,7 +22,6 @@ import ( api "k8s.io/kubernetes/pkg/apis/core" ) -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // NetworkPolicy describes what network traffic is allowed for a set of Pods @@ -196,7 +195,6 @@ type NetworkPolicyList struct { Items []NetworkPolicy } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // Ingress is a collection of rules that allow inbound connections to reach the diff --git a/pkg/apis/policy/types.go b/pkg/apis/policy/types.go index f51079a34a4..055efd3ef41 100644 --- a/pkg/apis/policy/types.go +++ b/pkg/apis/policy/types.go @@ -79,7 +79,6 @@ type PodDisruptionBudgetStatus struct { ExpectedPods int32 } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // PodDisruptionBudget is an object to define the max disruption that can be caused to a collection of pods @@ -106,8 +105,6 @@ type PodDisruptionBudgetList struct { Items []PodDisruptionBudget } -// +genclient -// +genclient:noVerbs // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // Eviction evicts a pod from its node subject to certain policies and safety constraints. @@ -125,8 +122,6 @@ type Eviction struct { DeleteOptions *metav1.DeleteOptions } -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // PodSecurityPolicy governs the ability to make requests that affect the SecurityContext diff --git a/pkg/apis/rbac/types.go b/pkg/apis/rbac/types.go index 6fdd486d242..6333aa4f323 100644 --- a/pkg/apis/rbac/types.go +++ b/pkg/apis/rbac/types.go @@ -88,7 +88,6 @@ type RoleRef struct { Name string } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // Role is a namespaced, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding. @@ -101,7 +100,6 @@ type Role struct { Rules []PolicyRule } -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // RoleBinding references a role, but does not contain it. It can reference a Role in the same namespace or a ClusterRole in the global namespace. @@ -143,8 +141,6 @@ type RoleList struct { Items []Role } -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // ClusterRole is a cluster level, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding or ClusterRoleBinding. @@ -169,8 +165,6 @@ type AggregationRule struct { ClusterRoleSelectors []metav1.LabelSelector } -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // ClusterRoleBinding references a ClusterRole, but not contain it. It can reference a ClusterRole in the global namespace, diff --git a/pkg/apis/scheduling/types.go b/pkg/apis/scheduling/types.go index 29c950157c6..185eb81c59b 100644 --- a/pkg/apis/scheduling/types.go +++ b/pkg/apis/scheduling/types.go @@ -36,8 +36,6 @@ const ( SystemNodeCritical = SystemPriorityClassPrefix + "node-critical" ) -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // PriorityClass defines the mapping from a priority class name to the priority diff --git a/pkg/apis/settings/types.go b/pkg/apis/settings/types.go index 876c8025532..ae48cb3a7fd 100644 --- a/pkg/apis/settings/types.go +++ b/pkg/apis/settings/types.go @@ -21,7 +21,6 @@ import ( api "k8s.io/kubernetes/pkg/apis/core" ) -// +genclient // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // PodPreset is a policy resource that defines additional runtime diff --git a/pkg/apis/storage/types.go b/pkg/apis/storage/types.go index daf23d61139..795033c14e7 100644 --- a/pkg/apis/storage/types.go +++ b/pkg/apis/storage/types.go @@ -21,8 +21,6 @@ import ( api "k8s.io/kubernetes/pkg/apis/core" ) -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // StorageClass describes a named "class" of storage offered in a cluster. @@ -94,8 +92,6 @@ type StorageClassList struct { Items []StorageClass } -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // Captures the intent to attach or detach the specified volume to/from @@ -216,8 +212,6 @@ const ( VolumeBindingWaitForFirstConsumer VolumeBindingMode = "WaitForFirstConsumer" ) -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // CSIDriver captures information about a Container Storage Interface (CSI) @@ -294,8 +288,6 @@ type CSIDriverSpec struct { PodInfoOnMount *bool } -// +genclient -// +genclient:nonNamespaced // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // CSINode holds information about all CSI drivers installed on a node.