mirror of
https://github.com/kubernetes/client-go.git
synced 2025-06-29 16:36:54 +00:00
generated
Kubernetes-commit: e86c38b249bb614c13210f1fe34fb92247641ef9
This commit is contained in:
parent
bf1a6eed35
commit
ef8b7aa53e
@ -16,10 +16,10 @@ limitations under the License.
|
|||||||
|
|
||||||
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
package v1alpha1
|
package v1alpha2
|
||||||
|
|
||||||
import (
|
import (
|
||||||
coordinationv1alpha1 "k8s.io/api/coordination/v1alpha1"
|
coordinationv1alpha2 "k8s.io/api/coordination/v1alpha2"
|
||||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
types "k8s.io/apimachinery/pkg/types"
|
types "k8s.io/apimachinery/pkg/types"
|
||||||
managedfields "k8s.io/apimachinery/pkg/util/managedfields"
|
managedfields "k8s.io/apimachinery/pkg/util/managedfields"
|
||||||
@ -42,7 +42,7 @@ func LeaseCandidate(name, namespace string) *LeaseCandidateApplyConfiguration {
|
|||||||
b.WithName(name)
|
b.WithName(name)
|
||||||
b.WithNamespace(namespace)
|
b.WithNamespace(namespace)
|
||||||
b.WithKind("LeaseCandidate")
|
b.WithKind("LeaseCandidate")
|
||||||
b.WithAPIVersion("coordination.k8s.io/v1alpha1")
|
b.WithAPIVersion("coordination.k8s.io/v1alpha2")
|
||||||
return b
|
return b
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -57,20 +57,20 @@ func LeaseCandidate(name, namespace string) *LeaseCandidateApplyConfiguration {
|
|||||||
// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
|
// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
|
||||||
// applied if another fieldManager has updated or force applied any of the previously applied fields.
|
// applied if another fieldManager has updated or force applied any of the previously applied fields.
|
||||||
// Experimental!
|
// Experimental!
|
||||||
func ExtractLeaseCandidate(leaseCandidate *coordinationv1alpha1.LeaseCandidate, fieldManager string) (*LeaseCandidateApplyConfiguration, error) {
|
func ExtractLeaseCandidate(leaseCandidate *coordinationv1alpha2.LeaseCandidate, fieldManager string) (*LeaseCandidateApplyConfiguration, error) {
|
||||||
return extractLeaseCandidate(leaseCandidate, fieldManager, "")
|
return extractLeaseCandidate(leaseCandidate, fieldManager, "")
|
||||||
}
|
}
|
||||||
|
|
||||||
// ExtractLeaseCandidateStatus is the same as ExtractLeaseCandidate except
|
// ExtractLeaseCandidateStatus is the same as ExtractLeaseCandidate except
|
||||||
// that it extracts the status subresource applied configuration.
|
// that it extracts the status subresource applied configuration.
|
||||||
// Experimental!
|
// Experimental!
|
||||||
func ExtractLeaseCandidateStatus(leaseCandidate *coordinationv1alpha1.LeaseCandidate, fieldManager string) (*LeaseCandidateApplyConfiguration, error) {
|
func ExtractLeaseCandidateStatus(leaseCandidate *coordinationv1alpha2.LeaseCandidate, fieldManager string) (*LeaseCandidateApplyConfiguration, error) {
|
||||||
return extractLeaseCandidate(leaseCandidate, fieldManager, "status")
|
return extractLeaseCandidate(leaseCandidate, fieldManager, "status")
|
||||||
}
|
}
|
||||||
|
|
||||||
func extractLeaseCandidate(leaseCandidate *coordinationv1alpha1.LeaseCandidate, fieldManager string, subresource string) (*LeaseCandidateApplyConfiguration, error) {
|
func extractLeaseCandidate(leaseCandidate *coordinationv1alpha2.LeaseCandidate, fieldManager string, subresource string) (*LeaseCandidateApplyConfiguration, error) {
|
||||||
b := &LeaseCandidateApplyConfiguration{}
|
b := &LeaseCandidateApplyConfiguration{}
|
||||||
err := managedfields.ExtractInto(leaseCandidate, internal.Parser().Type("io.k8s.api.coordination.v1alpha1.LeaseCandidate"), fieldManager, b, subresource)
|
err := managedfields.ExtractInto(leaseCandidate, internal.Parser().Type("io.k8s.api.coordination.v1alpha2.LeaseCandidate"), fieldManager, b, subresource)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
@ -78,7 +78,7 @@ func extractLeaseCandidate(leaseCandidate *coordinationv1alpha1.LeaseCandidate,
|
|||||||
b.WithNamespace(leaseCandidate.Namespace)
|
b.WithNamespace(leaseCandidate.Namespace)
|
||||||
|
|
||||||
b.WithKind("LeaseCandidate")
|
b.WithKind("LeaseCandidate")
|
||||||
b.WithAPIVersion("coordination.k8s.io/v1alpha1")
|
b.WithAPIVersion("coordination.k8s.io/v1alpha2")
|
||||||
return b, nil
|
return b, nil
|
||||||
}
|
}
|
||||||
|
|
@ -16,7 +16,7 @@ limitations under the License.
|
|||||||
|
|
||||||
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
package v1alpha1
|
package v1alpha2
|
||||||
|
|
||||||
import (
|
import (
|
||||||
coordinationv1 "k8s.io/api/coordination/v1"
|
coordinationv1 "k8s.io/api/coordination/v1"
|
||||||
@ -26,12 +26,12 @@ import (
|
|||||||
// LeaseCandidateSpecApplyConfiguration represents a declarative configuration of the LeaseCandidateSpec type for use
|
// LeaseCandidateSpecApplyConfiguration represents a declarative configuration of the LeaseCandidateSpec type for use
|
||||||
// with apply.
|
// with apply.
|
||||||
type LeaseCandidateSpecApplyConfiguration struct {
|
type LeaseCandidateSpecApplyConfiguration struct {
|
||||||
LeaseName *string `json:"leaseName,omitempty"`
|
LeaseName *string `json:"leaseName,omitempty"`
|
||||||
PingTime *v1.MicroTime `json:"pingTime,omitempty"`
|
PingTime *v1.MicroTime `json:"pingTime,omitempty"`
|
||||||
RenewTime *v1.MicroTime `json:"renewTime,omitempty"`
|
RenewTime *v1.MicroTime `json:"renewTime,omitempty"`
|
||||||
BinaryVersion *string `json:"binaryVersion,omitempty"`
|
BinaryVersion *string `json:"binaryVersion,omitempty"`
|
||||||
EmulationVersion *string `json:"emulationVersion,omitempty"`
|
EmulationVersion *string `json:"emulationVersion,omitempty"`
|
||||||
PreferredStrategies []coordinationv1.CoordinatedLeaseStrategy `json:"preferredStrategies,omitempty"`
|
Strategy *coordinationv1.CoordinatedLeaseStrategy `json:"strategy,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// LeaseCandidateSpecApplyConfiguration constructs a declarative configuration of the LeaseCandidateSpec type for use with
|
// LeaseCandidateSpecApplyConfiguration constructs a declarative configuration of the LeaseCandidateSpec type for use with
|
||||||
@ -80,12 +80,10 @@ func (b *LeaseCandidateSpecApplyConfiguration) WithEmulationVersion(value string
|
|||||||
return b
|
return b
|
||||||
}
|
}
|
||||||
|
|
||||||
// WithPreferredStrategies adds the given value to the PreferredStrategies field in the declarative configuration
|
// WithStrategy sets the Strategy field in the declarative configuration to the given value
|
||||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
// If called multiple times, values provided by each call will be appended to the PreferredStrategies field.
|
// If called multiple times, the Strategy field is set to the value of the last call.
|
||||||
func (b *LeaseCandidateSpecApplyConfiguration) WithPreferredStrategies(values ...coordinationv1.CoordinatedLeaseStrategy) *LeaseCandidateSpecApplyConfiguration {
|
func (b *LeaseCandidateSpecApplyConfiguration) WithStrategy(value coordinationv1.CoordinatedLeaseStrategy) *LeaseCandidateSpecApplyConfiguration {
|
||||||
for i := range values {
|
b.Strategy = &value
|
||||||
b.PreferredStrategies = append(b.PreferredStrategies, values[i])
|
|
||||||
}
|
|
||||||
return b
|
return b
|
||||||
}
|
}
|
@ -4471,7 +4471,7 @@ var schemaYAML = typed.YAMLObject(`types:
|
|||||||
- name: strategy
|
- name: strategy
|
||||||
type:
|
type:
|
||||||
scalar: string
|
scalar: string
|
||||||
- name: io.k8s.api.coordination.v1alpha1.LeaseCandidate
|
- name: io.k8s.api.coordination.v1alpha2.LeaseCandidate
|
||||||
map:
|
map:
|
||||||
fields:
|
fields:
|
||||||
- name: apiVersion
|
- name: apiVersion
|
||||||
@ -4486,14 +4486,15 @@ var schemaYAML = typed.YAMLObject(`types:
|
|||||||
default: {}
|
default: {}
|
||||||
- name: spec
|
- name: spec
|
||||||
type:
|
type:
|
||||||
namedType: io.k8s.api.coordination.v1alpha1.LeaseCandidateSpec
|
namedType: io.k8s.api.coordination.v1alpha2.LeaseCandidateSpec
|
||||||
default: {}
|
default: {}
|
||||||
- name: io.k8s.api.coordination.v1alpha1.LeaseCandidateSpec
|
- name: io.k8s.api.coordination.v1alpha2.LeaseCandidateSpec
|
||||||
map:
|
map:
|
||||||
fields:
|
fields:
|
||||||
- name: binaryVersion
|
- name: binaryVersion
|
||||||
type:
|
type:
|
||||||
scalar: string
|
scalar: string
|
||||||
|
default: ""
|
||||||
- name: emulationVersion
|
- name: emulationVersion
|
||||||
type:
|
type:
|
||||||
scalar: string
|
scalar: string
|
||||||
@ -4504,15 +4505,12 @@ var schemaYAML = typed.YAMLObject(`types:
|
|||||||
- name: pingTime
|
- name: pingTime
|
||||||
type:
|
type:
|
||||||
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.MicroTime
|
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.MicroTime
|
||||||
- name: preferredStrategies
|
|
||||||
type:
|
|
||||||
list:
|
|
||||||
elementType:
|
|
||||||
scalar: string
|
|
||||||
elementRelationship: atomic
|
|
||||||
- name: renewTime
|
- name: renewTime
|
||||||
type:
|
type:
|
||||||
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.MicroTime
|
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.MicroTime
|
||||||
|
- name: strategy
|
||||||
|
type:
|
||||||
|
scalar: string
|
||||||
- name: io.k8s.api.coordination.v1beta1.Lease
|
- name: io.k8s.api.coordination.v1beta1.Lease
|
||||||
map:
|
map:
|
||||||
fields:
|
fields:
|
||||||
|
@ -36,7 +36,7 @@ import (
|
|||||||
certificatesv1alpha1 "k8s.io/api/certificates/v1alpha1"
|
certificatesv1alpha1 "k8s.io/api/certificates/v1alpha1"
|
||||||
certificatesv1beta1 "k8s.io/api/certificates/v1beta1"
|
certificatesv1beta1 "k8s.io/api/certificates/v1beta1"
|
||||||
coordinationv1 "k8s.io/api/coordination/v1"
|
coordinationv1 "k8s.io/api/coordination/v1"
|
||||||
coordinationv1alpha1 "k8s.io/api/coordination/v1alpha1"
|
v1alpha2 "k8s.io/api/coordination/v1alpha2"
|
||||||
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
||||||
corev1 "k8s.io/api/core/v1"
|
corev1 "k8s.io/api/core/v1"
|
||||||
discoveryv1 "k8s.io/api/discovery/v1"
|
discoveryv1 "k8s.io/api/discovery/v1"
|
||||||
@ -89,7 +89,7 @@ import (
|
|||||||
applyconfigurationscertificatesv1alpha1 "k8s.io/client-go/applyconfigurations/certificates/v1alpha1"
|
applyconfigurationscertificatesv1alpha1 "k8s.io/client-go/applyconfigurations/certificates/v1alpha1"
|
||||||
applyconfigurationscertificatesv1beta1 "k8s.io/client-go/applyconfigurations/certificates/v1beta1"
|
applyconfigurationscertificatesv1beta1 "k8s.io/client-go/applyconfigurations/certificates/v1beta1"
|
||||||
applyconfigurationscoordinationv1 "k8s.io/client-go/applyconfigurations/coordination/v1"
|
applyconfigurationscoordinationv1 "k8s.io/client-go/applyconfigurations/coordination/v1"
|
||||||
applyconfigurationscoordinationv1alpha1 "k8s.io/client-go/applyconfigurations/coordination/v1alpha1"
|
coordinationv1alpha2 "k8s.io/client-go/applyconfigurations/coordination/v1alpha2"
|
||||||
applyconfigurationscoordinationv1beta1 "k8s.io/client-go/applyconfigurations/coordination/v1beta1"
|
applyconfigurationscoordinationv1beta1 "k8s.io/client-go/applyconfigurations/coordination/v1beta1"
|
||||||
applyconfigurationscorev1 "k8s.io/client-go/applyconfigurations/core/v1"
|
applyconfigurationscorev1 "k8s.io/client-go/applyconfigurations/core/v1"
|
||||||
applyconfigurationsdiscoveryv1 "k8s.io/client-go/applyconfigurations/discovery/v1"
|
applyconfigurationsdiscoveryv1 "k8s.io/client-go/applyconfigurations/discovery/v1"
|
||||||
@ -631,11 +631,11 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
|
|||||||
case coordinationv1.SchemeGroupVersion.WithKind("LeaseSpec"):
|
case coordinationv1.SchemeGroupVersion.WithKind("LeaseSpec"):
|
||||||
return &applyconfigurationscoordinationv1.LeaseSpecApplyConfiguration{}
|
return &applyconfigurationscoordinationv1.LeaseSpecApplyConfiguration{}
|
||||||
|
|
||||||
// Group=coordination.k8s.io, Version=v1alpha1
|
// Group=coordination.k8s.io, Version=v1alpha2
|
||||||
case coordinationv1alpha1.SchemeGroupVersion.WithKind("LeaseCandidate"):
|
case v1alpha2.SchemeGroupVersion.WithKind("LeaseCandidate"):
|
||||||
return &applyconfigurationscoordinationv1alpha1.LeaseCandidateApplyConfiguration{}
|
return &coordinationv1alpha2.LeaseCandidateApplyConfiguration{}
|
||||||
case coordinationv1alpha1.SchemeGroupVersion.WithKind("LeaseCandidateSpec"):
|
case v1alpha2.SchemeGroupVersion.WithKind("LeaseCandidateSpec"):
|
||||||
return &applyconfigurationscoordinationv1alpha1.LeaseCandidateSpecApplyConfiguration{}
|
return &coordinationv1alpha2.LeaseCandidateSpecApplyConfiguration{}
|
||||||
|
|
||||||
// Group=coordination.k8s.io, Version=v1beta1
|
// Group=coordination.k8s.io, Version=v1beta1
|
||||||
case coordinationv1beta1.SchemeGroupVersion.WithKind("Lease"):
|
case coordinationv1beta1.SchemeGroupVersion.WithKind("Lease"):
|
||||||
|
@ -20,7 +20,7 @@ package coordination
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
v1 "k8s.io/client-go/informers/coordination/v1"
|
v1 "k8s.io/client-go/informers/coordination/v1"
|
||||||
v1alpha1 "k8s.io/client-go/informers/coordination/v1alpha1"
|
v1alpha2 "k8s.io/client-go/informers/coordination/v1alpha2"
|
||||||
v1beta1 "k8s.io/client-go/informers/coordination/v1beta1"
|
v1beta1 "k8s.io/client-go/informers/coordination/v1beta1"
|
||||||
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
||||||
)
|
)
|
||||||
@ -29,8 +29,8 @@ import (
|
|||||||
type Interface interface {
|
type Interface interface {
|
||||||
// V1 provides access to shared informers for resources in V1.
|
// V1 provides access to shared informers for resources in V1.
|
||||||
V1() v1.Interface
|
V1() v1.Interface
|
||||||
// V1alpha1 provides access to shared informers for resources in V1alpha1.
|
// V1alpha2 provides access to shared informers for resources in V1alpha2.
|
||||||
V1alpha1() v1alpha1.Interface
|
V1alpha2() v1alpha2.Interface
|
||||||
// V1beta1 provides access to shared informers for resources in V1beta1.
|
// V1beta1 provides access to shared informers for resources in V1beta1.
|
||||||
V1beta1() v1beta1.Interface
|
V1beta1() v1beta1.Interface
|
||||||
}
|
}
|
||||||
@ -51,9 +51,9 @@ func (g *group) V1() v1.Interface {
|
|||||||
return v1.New(g.factory, g.namespace, g.tweakListOptions)
|
return v1.New(g.factory, g.namespace, g.tweakListOptions)
|
||||||
}
|
}
|
||||||
|
|
||||||
// V1alpha1 returns a new v1alpha1.Interface.
|
// V1alpha2 returns a new v1alpha2.Interface.
|
||||||
func (g *group) V1alpha1() v1alpha1.Interface {
|
func (g *group) V1alpha2() v1alpha2.Interface {
|
||||||
return v1alpha1.New(g.factory, g.namespace, g.tweakListOptions)
|
return v1alpha2.New(g.factory, g.namespace, g.tweakListOptions)
|
||||||
}
|
}
|
||||||
|
|
||||||
// V1beta1 returns a new v1beta1.Interface.
|
// V1beta1 returns a new v1beta1.Interface.
|
||||||
|
@ -16,7 +16,7 @@ limitations under the License.
|
|||||||
|
|
||||||
// Code generated by informer-gen. DO NOT EDIT.
|
// Code generated by informer-gen. DO NOT EDIT.
|
||||||
|
|
||||||
package v1alpha1
|
package v1alpha2
|
||||||
|
|
||||||
import (
|
import (
|
||||||
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
@ -16,19 +16,19 @@ limitations under the License.
|
|||||||
|
|
||||||
// Code generated by informer-gen. DO NOT EDIT.
|
// Code generated by informer-gen. DO NOT EDIT.
|
||||||
|
|
||||||
package v1alpha1
|
package v1alpha2
|
||||||
|
|
||||||
import (
|
import (
|
||||||
context "context"
|
context "context"
|
||||||
time "time"
|
time "time"
|
||||||
|
|
||||||
apicoordinationv1alpha1 "k8s.io/api/coordination/v1alpha1"
|
apicoordinationv1alpha2 "k8s.io/api/coordination/v1alpha2"
|
||||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||||
watch "k8s.io/apimachinery/pkg/watch"
|
watch "k8s.io/apimachinery/pkg/watch"
|
||||||
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
||||||
kubernetes "k8s.io/client-go/kubernetes"
|
kubernetes "k8s.io/client-go/kubernetes"
|
||||||
coordinationv1alpha1 "k8s.io/client-go/listers/coordination/v1alpha1"
|
coordinationv1alpha2 "k8s.io/client-go/listers/coordination/v1alpha2"
|
||||||
cache "k8s.io/client-go/tools/cache"
|
cache "k8s.io/client-go/tools/cache"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -36,7 +36,7 @@ import (
|
|||||||
// LeaseCandidates.
|
// LeaseCandidates.
|
||||||
type LeaseCandidateInformer interface {
|
type LeaseCandidateInformer interface {
|
||||||
Informer() cache.SharedIndexInformer
|
Informer() cache.SharedIndexInformer
|
||||||
Lister() coordinationv1alpha1.LeaseCandidateLister
|
Lister() coordinationv1alpha2.LeaseCandidateLister
|
||||||
}
|
}
|
||||||
|
|
||||||
type leaseCandidateInformer struct {
|
type leaseCandidateInformer struct {
|
||||||
@ -62,16 +62,16 @@ func NewFilteredLeaseCandidateInformer(client kubernetes.Interface, namespace st
|
|||||||
if tweakListOptions != nil {
|
if tweakListOptions != nil {
|
||||||
tweakListOptions(&options)
|
tweakListOptions(&options)
|
||||||
}
|
}
|
||||||
return client.CoordinationV1alpha1().LeaseCandidates(namespace).List(context.TODO(), options)
|
return client.CoordinationV1alpha2().LeaseCandidates(namespace).List(context.TODO(), options)
|
||||||
},
|
},
|
||||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||||
if tweakListOptions != nil {
|
if tweakListOptions != nil {
|
||||||
tweakListOptions(&options)
|
tweakListOptions(&options)
|
||||||
}
|
}
|
||||||
return client.CoordinationV1alpha1().LeaseCandidates(namespace).Watch(context.TODO(), options)
|
return client.CoordinationV1alpha2().LeaseCandidates(namespace).Watch(context.TODO(), options)
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
&apicoordinationv1alpha1.LeaseCandidate{},
|
&apicoordinationv1alpha2.LeaseCandidate{},
|
||||||
resyncPeriod,
|
resyncPeriod,
|
||||||
indexers,
|
indexers,
|
||||||
)
|
)
|
||||||
@ -82,9 +82,9 @@ func (f *leaseCandidateInformer) defaultInformer(client kubernetes.Interface, re
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (f *leaseCandidateInformer) Informer() cache.SharedIndexInformer {
|
func (f *leaseCandidateInformer) Informer() cache.SharedIndexInformer {
|
||||||
return f.factory.InformerFor(&apicoordinationv1alpha1.LeaseCandidate{}, f.defaultInformer)
|
return f.factory.InformerFor(&apicoordinationv1alpha2.LeaseCandidate{}, f.defaultInformer)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (f *leaseCandidateInformer) Lister() coordinationv1alpha1.LeaseCandidateLister {
|
func (f *leaseCandidateInformer) Lister() coordinationv1alpha2.LeaseCandidateLister {
|
||||||
return coordinationv1alpha1.NewLeaseCandidateLister(f.Informer().GetIndexer())
|
return coordinationv1alpha2.NewLeaseCandidateLister(f.Informer().GetIndexer())
|
||||||
}
|
}
|
@ -38,7 +38,7 @@ import (
|
|||||||
certificatesv1alpha1 "k8s.io/api/certificates/v1alpha1"
|
certificatesv1alpha1 "k8s.io/api/certificates/v1alpha1"
|
||||||
certificatesv1beta1 "k8s.io/api/certificates/v1beta1"
|
certificatesv1beta1 "k8s.io/api/certificates/v1beta1"
|
||||||
coordinationv1 "k8s.io/api/coordination/v1"
|
coordinationv1 "k8s.io/api/coordination/v1"
|
||||||
coordinationv1alpha1 "k8s.io/api/coordination/v1alpha1"
|
v1alpha2 "k8s.io/api/coordination/v1alpha2"
|
||||||
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
||||||
corev1 "k8s.io/api/core/v1"
|
corev1 "k8s.io/api/core/v1"
|
||||||
discoveryv1 "k8s.io/api/discovery/v1"
|
discoveryv1 "k8s.io/api/discovery/v1"
|
||||||
@ -204,9 +204,9 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource
|
|||||||
case coordinationv1.SchemeGroupVersion.WithResource("leases"):
|
case coordinationv1.SchemeGroupVersion.WithResource("leases"):
|
||||||
return &genericInformer{resource: resource.GroupResource(), informer: f.Coordination().V1().Leases().Informer()}, nil
|
return &genericInformer{resource: resource.GroupResource(), informer: f.Coordination().V1().Leases().Informer()}, nil
|
||||||
|
|
||||||
// Group=coordination.k8s.io, Version=v1alpha1
|
// Group=coordination.k8s.io, Version=v1alpha2
|
||||||
case coordinationv1alpha1.SchemeGroupVersion.WithResource("leasecandidates"):
|
case v1alpha2.SchemeGroupVersion.WithResource("leasecandidates"):
|
||||||
return &genericInformer{resource: resource.GroupResource(), informer: f.Coordination().V1alpha1().LeaseCandidates().Informer()}, nil
|
return &genericInformer{resource: resource.GroupResource(), informer: f.Coordination().V1alpha2().LeaseCandidates().Informer()}, nil
|
||||||
|
|
||||||
// Group=coordination.k8s.io, Version=v1beta1
|
// Group=coordination.k8s.io, Version=v1beta1
|
||||||
case coordinationv1beta1.SchemeGroupVersion.WithResource("leases"):
|
case coordinationv1beta1.SchemeGroupVersion.WithResource("leases"):
|
||||||
|
@ -45,7 +45,7 @@ import (
|
|||||||
certificatesv1alpha1 "k8s.io/client-go/kubernetes/typed/certificates/v1alpha1"
|
certificatesv1alpha1 "k8s.io/client-go/kubernetes/typed/certificates/v1alpha1"
|
||||||
certificatesv1beta1 "k8s.io/client-go/kubernetes/typed/certificates/v1beta1"
|
certificatesv1beta1 "k8s.io/client-go/kubernetes/typed/certificates/v1beta1"
|
||||||
coordinationv1 "k8s.io/client-go/kubernetes/typed/coordination/v1"
|
coordinationv1 "k8s.io/client-go/kubernetes/typed/coordination/v1"
|
||||||
coordinationv1alpha1 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha1"
|
coordinationv1alpha2 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha2"
|
||||||
coordinationv1beta1 "k8s.io/client-go/kubernetes/typed/coordination/v1beta1"
|
coordinationv1beta1 "k8s.io/client-go/kubernetes/typed/coordination/v1beta1"
|
||||||
corev1 "k8s.io/client-go/kubernetes/typed/core/v1"
|
corev1 "k8s.io/client-go/kubernetes/typed/core/v1"
|
||||||
discoveryv1 "k8s.io/client-go/kubernetes/typed/discovery/v1"
|
discoveryv1 "k8s.io/client-go/kubernetes/typed/discovery/v1"
|
||||||
@ -104,7 +104,7 @@ type Interface interface {
|
|||||||
CertificatesV1() certificatesv1.CertificatesV1Interface
|
CertificatesV1() certificatesv1.CertificatesV1Interface
|
||||||
CertificatesV1beta1() certificatesv1beta1.CertificatesV1beta1Interface
|
CertificatesV1beta1() certificatesv1beta1.CertificatesV1beta1Interface
|
||||||
CertificatesV1alpha1() certificatesv1alpha1.CertificatesV1alpha1Interface
|
CertificatesV1alpha1() certificatesv1alpha1.CertificatesV1alpha1Interface
|
||||||
CoordinationV1alpha1() coordinationv1alpha1.CoordinationV1alpha1Interface
|
CoordinationV1alpha2() coordinationv1alpha2.CoordinationV1alpha2Interface
|
||||||
CoordinationV1beta1() coordinationv1beta1.CoordinationV1beta1Interface
|
CoordinationV1beta1() coordinationv1beta1.CoordinationV1beta1Interface
|
||||||
CoordinationV1() coordinationv1.CoordinationV1Interface
|
CoordinationV1() coordinationv1.CoordinationV1Interface
|
||||||
CoreV1() corev1.CoreV1Interface
|
CoreV1() corev1.CoreV1Interface
|
||||||
@ -163,7 +163,7 @@ type Clientset struct {
|
|||||||
certificatesV1 *certificatesv1.CertificatesV1Client
|
certificatesV1 *certificatesv1.CertificatesV1Client
|
||||||
certificatesV1beta1 *certificatesv1beta1.CertificatesV1beta1Client
|
certificatesV1beta1 *certificatesv1beta1.CertificatesV1beta1Client
|
||||||
certificatesV1alpha1 *certificatesv1alpha1.CertificatesV1alpha1Client
|
certificatesV1alpha1 *certificatesv1alpha1.CertificatesV1alpha1Client
|
||||||
coordinationV1alpha1 *coordinationv1alpha1.CoordinationV1alpha1Client
|
coordinationV1alpha2 *coordinationv1alpha2.CoordinationV1alpha2Client
|
||||||
coordinationV1beta1 *coordinationv1beta1.CoordinationV1beta1Client
|
coordinationV1beta1 *coordinationv1beta1.CoordinationV1beta1Client
|
||||||
coordinationV1 *coordinationv1.CoordinationV1Client
|
coordinationV1 *coordinationv1.CoordinationV1Client
|
||||||
coreV1 *corev1.CoreV1Client
|
coreV1 *corev1.CoreV1Client
|
||||||
@ -303,9 +303,9 @@ func (c *Clientset) CertificatesV1alpha1() certificatesv1alpha1.CertificatesV1al
|
|||||||
return c.certificatesV1alpha1
|
return c.certificatesV1alpha1
|
||||||
}
|
}
|
||||||
|
|
||||||
// CoordinationV1alpha1 retrieves the CoordinationV1alpha1Client
|
// CoordinationV1alpha2 retrieves the CoordinationV1alpha2Client
|
||||||
func (c *Clientset) CoordinationV1alpha1() coordinationv1alpha1.CoordinationV1alpha1Interface {
|
func (c *Clientset) CoordinationV1alpha2() coordinationv1alpha2.CoordinationV1alpha2Interface {
|
||||||
return c.coordinationV1alpha1
|
return c.coordinationV1alpha2
|
||||||
}
|
}
|
||||||
|
|
||||||
// CoordinationV1beta1 retrieves the CoordinationV1beta1Client
|
// CoordinationV1beta1 retrieves the CoordinationV1beta1Client
|
||||||
@ -596,7 +596,7 @@ func NewForConfigAndClient(c *rest.Config, httpClient *http.Client) (*Clientset,
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
cs.coordinationV1alpha1, err = coordinationv1alpha1.NewForConfigAndClient(&configShallowCopy, httpClient)
|
cs.coordinationV1alpha2, err = coordinationv1alpha2.NewForConfigAndClient(&configShallowCopy, httpClient)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
@ -770,7 +770,7 @@ func New(c rest.Interface) *Clientset {
|
|||||||
cs.certificatesV1 = certificatesv1.New(c)
|
cs.certificatesV1 = certificatesv1.New(c)
|
||||||
cs.certificatesV1beta1 = certificatesv1beta1.New(c)
|
cs.certificatesV1beta1 = certificatesv1beta1.New(c)
|
||||||
cs.certificatesV1alpha1 = certificatesv1alpha1.New(c)
|
cs.certificatesV1alpha1 = certificatesv1alpha1.New(c)
|
||||||
cs.coordinationV1alpha1 = coordinationv1alpha1.New(c)
|
cs.coordinationV1alpha2 = coordinationv1alpha2.New(c)
|
||||||
cs.coordinationV1beta1 = coordinationv1beta1.New(c)
|
cs.coordinationV1beta1 = coordinationv1beta1.New(c)
|
||||||
cs.coordinationV1 = coordinationv1.New(c)
|
cs.coordinationV1 = coordinationv1.New(c)
|
||||||
cs.coreV1 = corev1.New(c)
|
cs.coreV1 = corev1.New(c)
|
||||||
|
@ -69,8 +69,8 @@ import (
|
|||||||
fakecertificatesv1beta1 "k8s.io/client-go/kubernetes/typed/certificates/v1beta1/fake"
|
fakecertificatesv1beta1 "k8s.io/client-go/kubernetes/typed/certificates/v1beta1/fake"
|
||||||
coordinationv1 "k8s.io/client-go/kubernetes/typed/coordination/v1"
|
coordinationv1 "k8s.io/client-go/kubernetes/typed/coordination/v1"
|
||||||
fakecoordinationv1 "k8s.io/client-go/kubernetes/typed/coordination/v1/fake"
|
fakecoordinationv1 "k8s.io/client-go/kubernetes/typed/coordination/v1/fake"
|
||||||
coordinationv1alpha1 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha1"
|
coordinationv1alpha2 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha2"
|
||||||
fakecoordinationv1alpha1 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha1/fake"
|
fakecoordinationv1alpha2 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha2/fake"
|
||||||
coordinationv1beta1 "k8s.io/client-go/kubernetes/typed/coordination/v1beta1"
|
coordinationv1beta1 "k8s.io/client-go/kubernetes/typed/coordination/v1beta1"
|
||||||
fakecoordinationv1beta1 "k8s.io/client-go/kubernetes/typed/coordination/v1beta1/fake"
|
fakecoordinationv1beta1 "k8s.io/client-go/kubernetes/typed/coordination/v1beta1/fake"
|
||||||
corev1 "k8s.io/client-go/kubernetes/typed/core/v1"
|
corev1 "k8s.io/client-go/kubernetes/typed/core/v1"
|
||||||
@ -327,9 +327,9 @@ func (c *Clientset) CertificatesV1alpha1() certificatesv1alpha1.CertificatesV1al
|
|||||||
return &fakecertificatesv1alpha1.FakeCertificatesV1alpha1{Fake: &c.Fake}
|
return &fakecertificatesv1alpha1.FakeCertificatesV1alpha1{Fake: &c.Fake}
|
||||||
}
|
}
|
||||||
|
|
||||||
// CoordinationV1alpha1 retrieves the CoordinationV1alpha1Client
|
// CoordinationV1alpha2 retrieves the CoordinationV1alpha2Client
|
||||||
func (c *Clientset) CoordinationV1alpha1() coordinationv1alpha1.CoordinationV1alpha1Interface {
|
func (c *Clientset) CoordinationV1alpha2() coordinationv1alpha2.CoordinationV1alpha2Interface {
|
||||||
return &fakecoordinationv1alpha1.FakeCoordinationV1alpha1{Fake: &c.Fake}
|
return &fakecoordinationv1alpha2.FakeCoordinationV1alpha2{Fake: &c.Fake}
|
||||||
}
|
}
|
||||||
|
|
||||||
// CoordinationV1beta1 retrieves the CoordinationV1beta1Client
|
// CoordinationV1beta1 retrieves the CoordinationV1beta1Client
|
||||||
|
@ -41,7 +41,7 @@ import (
|
|||||||
certificatesv1alpha1 "k8s.io/api/certificates/v1alpha1"
|
certificatesv1alpha1 "k8s.io/api/certificates/v1alpha1"
|
||||||
certificatesv1beta1 "k8s.io/api/certificates/v1beta1"
|
certificatesv1beta1 "k8s.io/api/certificates/v1beta1"
|
||||||
coordinationv1 "k8s.io/api/coordination/v1"
|
coordinationv1 "k8s.io/api/coordination/v1"
|
||||||
coordinationv1alpha1 "k8s.io/api/coordination/v1alpha1"
|
coordinationv1alpha2 "k8s.io/api/coordination/v1alpha2"
|
||||||
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
||||||
corev1 "k8s.io/api/core/v1"
|
corev1 "k8s.io/api/core/v1"
|
||||||
discoveryv1 "k8s.io/api/discovery/v1"
|
discoveryv1 "k8s.io/api/discovery/v1"
|
||||||
@ -105,7 +105,7 @@ var localSchemeBuilder = runtime.SchemeBuilder{
|
|||||||
certificatesv1.AddToScheme,
|
certificatesv1.AddToScheme,
|
||||||
certificatesv1beta1.AddToScheme,
|
certificatesv1beta1.AddToScheme,
|
||||||
certificatesv1alpha1.AddToScheme,
|
certificatesv1alpha1.AddToScheme,
|
||||||
coordinationv1alpha1.AddToScheme,
|
coordinationv1alpha2.AddToScheme,
|
||||||
coordinationv1beta1.AddToScheme,
|
coordinationv1beta1.AddToScheme,
|
||||||
coordinationv1.AddToScheme,
|
coordinationv1.AddToScheme,
|
||||||
corev1.AddToScheme,
|
corev1.AddToScheme,
|
||||||
|
@ -41,7 +41,7 @@ import (
|
|||||||
certificatesv1alpha1 "k8s.io/api/certificates/v1alpha1"
|
certificatesv1alpha1 "k8s.io/api/certificates/v1alpha1"
|
||||||
certificatesv1beta1 "k8s.io/api/certificates/v1beta1"
|
certificatesv1beta1 "k8s.io/api/certificates/v1beta1"
|
||||||
coordinationv1 "k8s.io/api/coordination/v1"
|
coordinationv1 "k8s.io/api/coordination/v1"
|
||||||
coordinationv1alpha1 "k8s.io/api/coordination/v1alpha1"
|
coordinationv1alpha2 "k8s.io/api/coordination/v1alpha2"
|
||||||
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
||||||
corev1 "k8s.io/api/core/v1"
|
corev1 "k8s.io/api/core/v1"
|
||||||
discoveryv1 "k8s.io/api/discovery/v1"
|
discoveryv1 "k8s.io/api/discovery/v1"
|
||||||
@ -105,7 +105,7 @@ var localSchemeBuilder = runtime.SchemeBuilder{
|
|||||||
certificatesv1.AddToScheme,
|
certificatesv1.AddToScheme,
|
||||||
certificatesv1beta1.AddToScheme,
|
certificatesv1beta1.AddToScheme,
|
||||||
certificatesv1alpha1.AddToScheme,
|
certificatesv1alpha1.AddToScheme,
|
||||||
coordinationv1alpha1.AddToScheme,
|
coordinationv1alpha2.AddToScheme,
|
||||||
coordinationv1beta1.AddToScheme,
|
coordinationv1beta1.AddToScheme,
|
||||||
coordinationv1.AddToScheme,
|
coordinationv1.AddToScheme,
|
||||||
corev1.AddToScheme,
|
corev1.AddToScheme,
|
||||||
|
@ -16,34 +16,34 @@ limitations under the License.
|
|||||||
|
|
||||||
// Code generated by client-gen. DO NOT EDIT.
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
package v1alpha1
|
package v1alpha2
|
||||||
|
|
||||||
import (
|
import (
|
||||||
http "net/http"
|
http "net/http"
|
||||||
|
|
||||||
coordinationv1alpha1 "k8s.io/api/coordination/v1alpha1"
|
coordinationv1alpha2 "k8s.io/api/coordination/v1alpha2"
|
||||||
scheme "k8s.io/client-go/kubernetes/scheme"
|
scheme "k8s.io/client-go/kubernetes/scheme"
|
||||||
rest "k8s.io/client-go/rest"
|
rest "k8s.io/client-go/rest"
|
||||||
)
|
)
|
||||||
|
|
||||||
type CoordinationV1alpha1Interface interface {
|
type CoordinationV1alpha2Interface interface {
|
||||||
RESTClient() rest.Interface
|
RESTClient() rest.Interface
|
||||||
LeaseCandidatesGetter
|
LeaseCandidatesGetter
|
||||||
}
|
}
|
||||||
|
|
||||||
// CoordinationV1alpha1Client is used to interact with features provided by the coordination.k8s.io group.
|
// CoordinationV1alpha2Client is used to interact with features provided by the coordination.k8s.io group.
|
||||||
type CoordinationV1alpha1Client struct {
|
type CoordinationV1alpha2Client struct {
|
||||||
restClient rest.Interface
|
restClient rest.Interface
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *CoordinationV1alpha1Client) LeaseCandidates(namespace string) LeaseCandidateInterface {
|
func (c *CoordinationV1alpha2Client) LeaseCandidates(namespace string) LeaseCandidateInterface {
|
||||||
return newLeaseCandidates(c, namespace)
|
return newLeaseCandidates(c, namespace)
|
||||||
}
|
}
|
||||||
|
|
||||||
// NewForConfig creates a new CoordinationV1alpha1Client for the given config.
|
// NewForConfig creates a new CoordinationV1alpha2Client for the given config.
|
||||||
// NewForConfig is equivalent to NewForConfigAndClient(c, httpClient),
|
// NewForConfig is equivalent to NewForConfigAndClient(c, httpClient),
|
||||||
// where httpClient was generated with rest.HTTPClientFor(c).
|
// where httpClient was generated with rest.HTTPClientFor(c).
|
||||||
func NewForConfig(c *rest.Config) (*CoordinationV1alpha1Client, error) {
|
func NewForConfig(c *rest.Config) (*CoordinationV1alpha2Client, error) {
|
||||||
config := *c
|
config := *c
|
||||||
if err := setConfigDefaults(&config); err != nil {
|
if err := setConfigDefaults(&config); err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
@ -55,9 +55,9 @@ func NewForConfig(c *rest.Config) (*CoordinationV1alpha1Client, error) {
|
|||||||
return NewForConfigAndClient(&config, httpClient)
|
return NewForConfigAndClient(&config, httpClient)
|
||||||
}
|
}
|
||||||
|
|
||||||
// NewForConfigAndClient creates a new CoordinationV1alpha1Client for the given config and http client.
|
// NewForConfigAndClient creates a new CoordinationV1alpha2Client for the given config and http client.
|
||||||
// Note the http client provided takes precedence over the configured transport values.
|
// Note the http client provided takes precedence over the configured transport values.
|
||||||
func NewForConfigAndClient(c *rest.Config, h *http.Client) (*CoordinationV1alpha1Client, error) {
|
func NewForConfigAndClient(c *rest.Config, h *http.Client) (*CoordinationV1alpha2Client, error) {
|
||||||
config := *c
|
config := *c
|
||||||
if err := setConfigDefaults(&config); err != nil {
|
if err := setConfigDefaults(&config); err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
@ -66,12 +66,12 @@ func NewForConfigAndClient(c *rest.Config, h *http.Client) (*CoordinationV1alpha
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
return &CoordinationV1alpha1Client{client}, nil
|
return &CoordinationV1alpha2Client{client}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// NewForConfigOrDie creates a new CoordinationV1alpha1Client for the given config and
|
// NewForConfigOrDie creates a new CoordinationV1alpha2Client for the given config and
|
||||||
// panics if there is an error in the config.
|
// panics if there is an error in the config.
|
||||||
func NewForConfigOrDie(c *rest.Config) *CoordinationV1alpha1Client {
|
func NewForConfigOrDie(c *rest.Config) *CoordinationV1alpha2Client {
|
||||||
client, err := NewForConfig(c)
|
client, err := NewForConfig(c)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
panic(err)
|
panic(err)
|
||||||
@ -79,13 +79,13 @@ func NewForConfigOrDie(c *rest.Config) *CoordinationV1alpha1Client {
|
|||||||
return client
|
return client
|
||||||
}
|
}
|
||||||
|
|
||||||
// New creates a new CoordinationV1alpha1Client for the given RESTClient.
|
// New creates a new CoordinationV1alpha2Client for the given RESTClient.
|
||||||
func New(c rest.Interface) *CoordinationV1alpha1Client {
|
func New(c rest.Interface) *CoordinationV1alpha2Client {
|
||||||
return &CoordinationV1alpha1Client{c}
|
return &CoordinationV1alpha2Client{c}
|
||||||
}
|
}
|
||||||
|
|
||||||
func setConfigDefaults(config *rest.Config) error {
|
func setConfigDefaults(config *rest.Config) error {
|
||||||
gv := coordinationv1alpha1.SchemeGroupVersion
|
gv := coordinationv1alpha2.SchemeGroupVersion
|
||||||
config.GroupVersion = &gv
|
config.GroupVersion = &gv
|
||||||
config.APIPath = "/apis"
|
config.APIPath = "/apis"
|
||||||
config.NegotiatedSerializer = rest.CodecFactoryForGeneratedClient(scheme.Scheme, scheme.Codecs).WithoutConversion()
|
config.NegotiatedSerializer = rest.CodecFactoryForGeneratedClient(scheme.Scheme, scheme.Codecs).WithoutConversion()
|
||||||
@ -99,7 +99,7 @@ func setConfigDefaults(config *rest.Config) error {
|
|||||||
|
|
||||||
// RESTClient returns a RESTClient that is used to communicate
|
// RESTClient returns a RESTClient that is used to communicate
|
||||||
// with API server by this client implementation.
|
// with API server by this client implementation.
|
||||||
func (c *CoordinationV1alpha1Client) RESTClient() rest.Interface {
|
func (c *CoordinationV1alpha2Client) RESTClient() rest.Interface {
|
||||||
if c == nil {
|
if c == nil {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
@ -17,4 +17,4 @@ limitations under the License.
|
|||||||
// Code generated by client-gen. DO NOT EDIT.
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
// This package has the automatically generated typed clients.
|
// This package has the automatically generated typed clients.
|
||||||
package v1alpha1
|
package v1alpha2
|
@ -19,22 +19,22 @@ limitations under the License.
|
|||||||
package fake
|
package fake
|
||||||
|
|
||||||
import (
|
import (
|
||||||
v1alpha1 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha1"
|
v1alpha2 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha2"
|
||||||
rest "k8s.io/client-go/rest"
|
rest "k8s.io/client-go/rest"
|
||||||
testing "k8s.io/client-go/testing"
|
testing "k8s.io/client-go/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
type FakeCoordinationV1alpha1 struct {
|
type FakeCoordinationV1alpha2 struct {
|
||||||
*testing.Fake
|
*testing.Fake
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *FakeCoordinationV1alpha1) LeaseCandidates(namespace string) v1alpha1.LeaseCandidateInterface {
|
func (c *FakeCoordinationV1alpha2) LeaseCandidates(namespace string) v1alpha2.LeaseCandidateInterface {
|
||||||
return &FakeLeaseCandidates{c, namespace}
|
return &FakeLeaseCandidates{c, namespace}
|
||||||
}
|
}
|
||||||
|
|
||||||
// RESTClient returns a RESTClient that is used to communicate
|
// RESTClient returns a RESTClient that is used to communicate
|
||||||
// with API server by this client implementation.
|
// with API server by this client implementation.
|
||||||
func (c *FakeCoordinationV1alpha1) RESTClient() rest.Interface {
|
func (c *FakeCoordinationV1alpha2) RESTClient() rest.Interface {
|
||||||
var ret *rest.RESTClient
|
var ret *rest.RESTClient
|
||||||
return ret
|
return ret
|
||||||
}
|
}
|
@ -23,40 +23,40 @@ import (
|
|||||||
json "encoding/json"
|
json "encoding/json"
|
||||||
fmt "fmt"
|
fmt "fmt"
|
||||||
|
|
||||||
v1alpha1 "k8s.io/api/coordination/v1alpha1"
|
v1alpha2 "k8s.io/api/coordination/v1alpha2"
|
||||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
labels "k8s.io/apimachinery/pkg/labels"
|
labels "k8s.io/apimachinery/pkg/labels"
|
||||||
types "k8s.io/apimachinery/pkg/types"
|
types "k8s.io/apimachinery/pkg/types"
|
||||||
watch "k8s.io/apimachinery/pkg/watch"
|
watch "k8s.io/apimachinery/pkg/watch"
|
||||||
coordinationv1alpha1 "k8s.io/client-go/applyconfigurations/coordination/v1alpha1"
|
coordinationv1alpha2 "k8s.io/client-go/applyconfigurations/coordination/v1alpha2"
|
||||||
testing "k8s.io/client-go/testing"
|
testing "k8s.io/client-go/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
// FakeLeaseCandidates implements LeaseCandidateInterface
|
// FakeLeaseCandidates implements LeaseCandidateInterface
|
||||||
type FakeLeaseCandidates struct {
|
type FakeLeaseCandidates struct {
|
||||||
Fake *FakeCoordinationV1alpha1
|
Fake *FakeCoordinationV1alpha2
|
||||||
ns string
|
ns string
|
||||||
}
|
}
|
||||||
|
|
||||||
var leasecandidatesResource = v1alpha1.SchemeGroupVersion.WithResource("leasecandidates")
|
var leasecandidatesResource = v1alpha2.SchemeGroupVersion.WithResource("leasecandidates")
|
||||||
|
|
||||||
var leasecandidatesKind = v1alpha1.SchemeGroupVersion.WithKind("LeaseCandidate")
|
var leasecandidatesKind = v1alpha2.SchemeGroupVersion.WithKind("LeaseCandidate")
|
||||||
|
|
||||||
// Get takes name of the leaseCandidate, and returns the corresponding leaseCandidate object, and an error if there is any.
|
// Get takes name of the leaseCandidate, and returns the corresponding leaseCandidate object, and an error if there is any.
|
||||||
func (c *FakeLeaseCandidates) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.LeaseCandidate, err error) {
|
func (c *FakeLeaseCandidates) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha2.LeaseCandidate, err error) {
|
||||||
emptyResult := &v1alpha1.LeaseCandidate{}
|
emptyResult := &v1alpha2.LeaseCandidate{}
|
||||||
obj, err := c.Fake.
|
obj, err := c.Fake.
|
||||||
Invokes(testing.NewGetActionWithOptions(leasecandidatesResource, c.ns, name, options), emptyResult)
|
Invokes(testing.NewGetActionWithOptions(leasecandidatesResource, c.ns, name, options), emptyResult)
|
||||||
|
|
||||||
if obj == nil {
|
if obj == nil {
|
||||||
return emptyResult, err
|
return emptyResult, err
|
||||||
}
|
}
|
||||||
return obj.(*v1alpha1.LeaseCandidate), err
|
return obj.(*v1alpha2.LeaseCandidate), err
|
||||||
}
|
}
|
||||||
|
|
||||||
// List takes label and field selectors, and returns the list of LeaseCandidates that match those selectors.
|
// List takes label and field selectors, and returns the list of LeaseCandidates that match those selectors.
|
||||||
func (c *FakeLeaseCandidates) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.LeaseCandidateList, err error) {
|
func (c *FakeLeaseCandidates) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha2.LeaseCandidateList, err error) {
|
||||||
emptyResult := &v1alpha1.LeaseCandidateList{}
|
emptyResult := &v1alpha2.LeaseCandidateList{}
|
||||||
obj, err := c.Fake.
|
obj, err := c.Fake.
|
||||||
Invokes(testing.NewListActionWithOptions(leasecandidatesResource, leasecandidatesKind, c.ns, opts), emptyResult)
|
Invokes(testing.NewListActionWithOptions(leasecandidatesResource, leasecandidatesKind, c.ns, opts), emptyResult)
|
||||||
|
|
||||||
@ -68,8 +68,8 @@ func (c *FakeLeaseCandidates) List(ctx context.Context, opts v1.ListOptions) (re
|
|||||||
if label == nil {
|
if label == nil {
|
||||||
label = labels.Everything()
|
label = labels.Everything()
|
||||||
}
|
}
|
||||||
list := &v1alpha1.LeaseCandidateList{ListMeta: obj.(*v1alpha1.LeaseCandidateList).ListMeta}
|
list := &v1alpha2.LeaseCandidateList{ListMeta: obj.(*v1alpha2.LeaseCandidateList).ListMeta}
|
||||||
for _, item := range obj.(*v1alpha1.LeaseCandidateList).Items {
|
for _, item := range obj.(*v1alpha2.LeaseCandidateList).Items {
|
||||||
if label.Matches(labels.Set(item.Labels)) {
|
if label.Matches(labels.Set(item.Labels)) {
|
||||||
list.Items = append(list.Items, item)
|
list.Items = append(list.Items, item)
|
||||||
}
|
}
|
||||||
@ -85,33 +85,33 @@ func (c *FakeLeaseCandidates) Watch(ctx context.Context, opts v1.ListOptions) (w
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Create takes the representation of a leaseCandidate and creates it. Returns the server's representation of the leaseCandidate, and an error, if there is any.
|
// Create takes the representation of a leaseCandidate and creates it. Returns the server's representation of the leaseCandidate, and an error, if there is any.
|
||||||
func (c *FakeLeaseCandidates) Create(ctx context.Context, leaseCandidate *v1alpha1.LeaseCandidate, opts v1.CreateOptions) (result *v1alpha1.LeaseCandidate, err error) {
|
func (c *FakeLeaseCandidates) Create(ctx context.Context, leaseCandidate *v1alpha2.LeaseCandidate, opts v1.CreateOptions) (result *v1alpha2.LeaseCandidate, err error) {
|
||||||
emptyResult := &v1alpha1.LeaseCandidate{}
|
emptyResult := &v1alpha2.LeaseCandidate{}
|
||||||
obj, err := c.Fake.
|
obj, err := c.Fake.
|
||||||
Invokes(testing.NewCreateActionWithOptions(leasecandidatesResource, c.ns, leaseCandidate, opts), emptyResult)
|
Invokes(testing.NewCreateActionWithOptions(leasecandidatesResource, c.ns, leaseCandidate, opts), emptyResult)
|
||||||
|
|
||||||
if obj == nil {
|
if obj == nil {
|
||||||
return emptyResult, err
|
return emptyResult, err
|
||||||
}
|
}
|
||||||
return obj.(*v1alpha1.LeaseCandidate), err
|
return obj.(*v1alpha2.LeaseCandidate), err
|
||||||
}
|
}
|
||||||
|
|
||||||
// Update takes the representation of a leaseCandidate and updates it. Returns the server's representation of the leaseCandidate, and an error, if there is any.
|
// Update takes the representation of a leaseCandidate and updates it. Returns the server's representation of the leaseCandidate, and an error, if there is any.
|
||||||
func (c *FakeLeaseCandidates) Update(ctx context.Context, leaseCandidate *v1alpha1.LeaseCandidate, opts v1.UpdateOptions) (result *v1alpha1.LeaseCandidate, err error) {
|
func (c *FakeLeaseCandidates) Update(ctx context.Context, leaseCandidate *v1alpha2.LeaseCandidate, opts v1.UpdateOptions) (result *v1alpha2.LeaseCandidate, err error) {
|
||||||
emptyResult := &v1alpha1.LeaseCandidate{}
|
emptyResult := &v1alpha2.LeaseCandidate{}
|
||||||
obj, err := c.Fake.
|
obj, err := c.Fake.
|
||||||
Invokes(testing.NewUpdateActionWithOptions(leasecandidatesResource, c.ns, leaseCandidate, opts), emptyResult)
|
Invokes(testing.NewUpdateActionWithOptions(leasecandidatesResource, c.ns, leaseCandidate, opts), emptyResult)
|
||||||
|
|
||||||
if obj == nil {
|
if obj == nil {
|
||||||
return emptyResult, err
|
return emptyResult, err
|
||||||
}
|
}
|
||||||
return obj.(*v1alpha1.LeaseCandidate), err
|
return obj.(*v1alpha2.LeaseCandidate), err
|
||||||
}
|
}
|
||||||
|
|
||||||
// Delete takes name of the leaseCandidate and deletes it. Returns an error if one occurs.
|
// Delete takes name of the leaseCandidate and deletes it. Returns an error if one occurs.
|
||||||
func (c *FakeLeaseCandidates) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
func (c *FakeLeaseCandidates) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||||
_, err := c.Fake.
|
_, err := c.Fake.
|
||||||
Invokes(testing.NewDeleteActionWithOptions(leasecandidatesResource, c.ns, name, opts), &v1alpha1.LeaseCandidate{})
|
Invokes(testing.NewDeleteActionWithOptions(leasecandidatesResource, c.ns, name, opts), &v1alpha2.LeaseCandidate{})
|
||||||
|
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
@ -120,24 +120,24 @@ func (c *FakeLeaseCandidates) Delete(ctx context.Context, name string, opts v1.D
|
|||||||
func (c *FakeLeaseCandidates) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
func (c *FakeLeaseCandidates) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||||
action := testing.NewDeleteCollectionActionWithOptions(leasecandidatesResource, c.ns, opts, listOpts)
|
action := testing.NewDeleteCollectionActionWithOptions(leasecandidatesResource, c.ns, opts, listOpts)
|
||||||
|
|
||||||
_, err := c.Fake.Invokes(action, &v1alpha1.LeaseCandidateList{})
|
_, err := c.Fake.Invokes(action, &v1alpha2.LeaseCandidateList{})
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
// Patch applies the patch and returns the patched leaseCandidate.
|
// Patch applies the patch and returns the patched leaseCandidate.
|
||||||
func (c *FakeLeaseCandidates) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.LeaseCandidate, err error) {
|
func (c *FakeLeaseCandidates) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.LeaseCandidate, err error) {
|
||||||
emptyResult := &v1alpha1.LeaseCandidate{}
|
emptyResult := &v1alpha2.LeaseCandidate{}
|
||||||
obj, err := c.Fake.
|
obj, err := c.Fake.
|
||||||
Invokes(testing.NewPatchSubresourceActionWithOptions(leasecandidatesResource, c.ns, name, pt, data, opts, subresources...), emptyResult)
|
Invokes(testing.NewPatchSubresourceActionWithOptions(leasecandidatesResource, c.ns, name, pt, data, opts, subresources...), emptyResult)
|
||||||
|
|
||||||
if obj == nil {
|
if obj == nil {
|
||||||
return emptyResult, err
|
return emptyResult, err
|
||||||
}
|
}
|
||||||
return obj.(*v1alpha1.LeaseCandidate), err
|
return obj.(*v1alpha2.LeaseCandidate), err
|
||||||
}
|
}
|
||||||
|
|
||||||
// Apply takes the given apply declarative configuration, applies it and returns the applied leaseCandidate.
|
// Apply takes the given apply declarative configuration, applies it and returns the applied leaseCandidate.
|
||||||
func (c *FakeLeaseCandidates) Apply(ctx context.Context, leaseCandidate *coordinationv1alpha1.LeaseCandidateApplyConfiguration, opts v1.ApplyOptions) (result *v1alpha1.LeaseCandidate, err error) {
|
func (c *FakeLeaseCandidates) Apply(ctx context.Context, leaseCandidate *coordinationv1alpha2.LeaseCandidateApplyConfiguration, opts v1.ApplyOptions) (result *v1alpha2.LeaseCandidate, err error) {
|
||||||
if leaseCandidate == nil {
|
if leaseCandidate == nil {
|
||||||
return nil, fmt.Errorf("leaseCandidate provided to Apply must not be nil")
|
return nil, fmt.Errorf("leaseCandidate provided to Apply must not be nil")
|
||||||
}
|
}
|
||||||
@ -149,12 +149,12 @@ func (c *FakeLeaseCandidates) Apply(ctx context.Context, leaseCandidate *coordin
|
|||||||
if name == nil {
|
if name == nil {
|
||||||
return nil, fmt.Errorf("leaseCandidate.Name must be provided to Apply")
|
return nil, fmt.Errorf("leaseCandidate.Name must be provided to Apply")
|
||||||
}
|
}
|
||||||
emptyResult := &v1alpha1.LeaseCandidate{}
|
emptyResult := &v1alpha2.LeaseCandidate{}
|
||||||
obj, err := c.Fake.
|
obj, err := c.Fake.
|
||||||
Invokes(testing.NewPatchSubresourceActionWithOptions(leasecandidatesResource, c.ns, *name, types.ApplyPatchType, data, opts.ToPatchOptions()), emptyResult)
|
Invokes(testing.NewPatchSubresourceActionWithOptions(leasecandidatesResource, c.ns, *name, types.ApplyPatchType, data, opts.ToPatchOptions()), emptyResult)
|
||||||
|
|
||||||
if obj == nil {
|
if obj == nil {
|
||||||
return emptyResult, err
|
return emptyResult, err
|
||||||
}
|
}
|
||||||
return obj.(*v1alpha1.LeaseCandidate), err
|
return obj.(*v1alpha2.LeaseCandidate), err
|
||||||
}
|
}
|
@ -16,6 +16,6 @@ limitations under the License.
|
|||||||
|
|
||||||
// Code generated by client-gen. DO NOT EDIT.
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
package v1alpha1
|
package v1alpha2
|
||||||
|
|
||||||
type LeaseCandidateExpansion interface{}
|
type LeaseCandidateExpansion interface{}
|
@ -16,16 +16,16 @@ limitations under the License.
|
|||||||
|
|
||||||
// Code generated by client-gen. DO NOT EDIT.
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
package v1alpha1
|
package v1alpha2
|
||||||
|
|
||||||
import (
|
import (
|
||||||
context "context"
|
context "context"
|
||||||
|
|
||||||
coordinationv1alpha1 "k8s.io/api/coordination/v1alpha1"
|
coordinationv1alpha2 "k8s.io/api/coordination/v1alpha2"
|
||||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||||
types "k8s.io/apimachinery/pkg/types"
|
types "k8s.io/apimachinery/pkg/types"
|
||||||
watch "k8s.io/apimachinery/pkg/watch"
|
watch "k8s.io/apimachinery/pkg/watch"
|
||||||
applyconfigurationscoordinationv1alpha1 "k8s.io/client-go/applyconfigurations/coordination/v1alpha1"
|
applyconfigurationscoordinationv1alpha2 "k8s.io/client-go/applyconfigurations/coordination/v1alpha2"
|
||||||
gentype "k8s.io/client-go/gentype"
|
gentype "k8s.io/client-go/gentype"
|
||||||
scheme "k8s.io/client-go/kubernetes/scheme"
|
scheme "k8s.io/client-go/kubernetes/scheme"
|
||||||
)
|
)
|
||||||
@ -38,34 +38,34 @@ type LeaseCandidatesGetter interface {
|
|||||||
|
|
||||||
// LeaseCandidateInterface has methods to work with LeaseCandidate resources.
|
// LeaseCandidateInterface has methods to work with LeaseCandidate resources.
|
||||||
type LeaseCandidateInterface interface {
|
type LeaseCandidateInterface interface {
|
||||||
Create(ctx context.Context, leaseCandidate *coordinationv1alpha1.LeaseCandidate, opts v1.CreateOptions) (*coordinationv1alpha1.LeaseCandidate, error)
|
Create(ctx context.Context, leaseCandidate *coordinationv1alpha2.LeaseCandidate, opts v1.CreateOptions) (*coordinationv1alpha2.LeaseCandidate, error)
|
||||||
Update(ctx context.Context, leaseCandidate *coordinationv1alpha1.LeaseCandidate, opts v1.UpdateOptions) (*coordinationv1alpha1.LeaseCandidate, error)
|
Update(ctx context.Context, leaseCandidate *coordinationv1alpha2.LeaseCandidate, opts v1.UpdateOptions) (*coordinationv1alpha2.LeaseCandidate, error)
|
||||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*coordinationv1alpha1.LeaseCandidate, error)
|
Get(ctx context.Context, name string, opts v1.GetOptions) (*coordinationv1alpha2.LeaseCandidate, error)
|
||||||
List(ctx context.Context, opts v1.ListOptions) (*coordinationv1alpha1.LeaseCandidateList, error)
|
List(ctx context.Context, opts v1.ListOptions) (*coordinationv1alpha2.LeaseCandidateList, error)
|
||||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *coordinationv1alpha1.LeaseCandidate, err error)
|
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *coordinationv1alpha2.LeaseCandidate, err error)
|
||||||
Apply(ctx context.Context, leaseCandidate *applyconfigurationscoordinationv1alpha1.LeaseCandidateApplyConfiguration, opts v1.ApplyOptions) (result *coordinationv1alpha1.LeaseCandidate, err error)
|
Apply(ctx context.Context, leaseCandidate *applyconfigurationscoordinationv1alpha2.LeaseCandidateApplyConfiguration, opts v1.ApplyOptions) (result *coordinationv1alpha2.LeaseCandidate, err error)
|
||||||
LeaseCandidateExpansion
|
LeaseCandidateExpansion
|
||||||
}
|
}
|
||||||
|
|
||||||
// leaseCandidates implements LeaseCandidateInterface
|
// leaseCandidates implements LeaseCandidateInterface
|
||||||
type leaseCandidates struct {
|
type leaseCandidates struct {
|
||||||
*gentype.ClientWithListAndApply[*coordinationv1alpha1.LeaseCandidate, *coordinationv1alpha1.LeaseCandidateList, *applyconfigurationscoordinationv1alpha1.LeaseCandidateApplyConfiguration]
|
*gentype.ClientWithListAndApply[*coordinationv1alpha2.LeaseCandidate, *coordinationv1alpha2.LeaseCandidateList, *applyconfigurationscoordinationv1alpha2.LeaseCandidateApplyConfiguration]
|
||||||
}
|
}
|
||||||
|
|
||||||
// newLeaseCandidates returns a LeaseCandidates
|
// newLeaseCandidates returns a LeaseCandidates
|
||||||
func newLeaseCandidates(c *CoordinationV1alpha1Client, namespace string) *leaseCandidates {
|
func newLeaseCandidates(c *CoordinationV1alpha2Client, namespace string) *leaseCandidates {
|
||||||
return &leaseCandidates{
|
return &leaseCandidates{
|
||||||
gentype.NewClientWithListAndApply[*coordinationv1alpha1.LeaseCandidate, *coordinationv1alpha1.LeaseCandidateList, *applyconfigurationscoordinationv1alpha1.LeaseCandidateApplyConfiguration](
|
gentype.NewClientWithListAndApply[*coordinationv1alpha2.LeaseCandidate, *coordinationv1alpha2.LeaseCandidateList, *applyconfigurationscoordinationv1alpha2.LeaseCandidateApplyConfiguration](
|
||||||
"leasecandidates",
|
"leasecandidates",
|
||||||
c.RESTClient(),
|
c.RESTClient(),
|
||||||
scheme.ParameterCodec,
|
scheme.ParameterCodec,
|
||||||
namespace,
|
namespace,
|
||||||
func() *coordinationv1alpha1.LeaseCandidate { return &coordinationv1alpha1.LeaseCandidate{} },
|
func() *coordinationv1alpha2.LeaseCandidate { return &coordinationv1alpha2.LeaseCandidate{} },
|
||||||
func() *coordinationv1alpha1.LeaseCandidateList { return &coordinationv1alpha1.LeaseCandidateList{} },
|
func() *coordinationv1alpha2.LeaseCandidateList { return &coordinationv1alpha2.LeaseCandidateList{} },
|
||||||
gentype.PrefersProtobuf[*coordinationv1alpha1.LeaseCandidate](),
|
gentype.PrefersProtobuf[*coordinationv1alpha2.LeaseCandidate](),
|
||||||
),
|
),
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -16,7 +16,7 @@ limitations under the License.
|
|||||||
|
|
||||||
// Code generated by lister-gen. DO NOT EDIT.
|
// Code generated by lister-gen. DO NOT EDIT.
|
||||||
|
|
||||||
package v1alpha1
|
package v1alpha2
|
||||||
|
|
||||||
// LeaseCandidateListerExpansion allows custom methods to be added to
|
// LeaseCandidateListerExpansion allows custom methods to be added to
|
||||||
// LeaseCandidateLister.
|
// LeaseCandidateLister.
|
@ -16,10 +16,10 @@ limitations under the License.
|
|||||||
|
|
||||||
// Code generated by lister-gen. DO NOT EDIT.
|
// Code generated by lister-gen. DO NOT EDIT.
|
||||||
|
|
||||||
package v1alpha1
|
package v1alpha2
|
||||||
|
|
||||||
import (
|
import (
|
||||||
coordinationv1alpha1 "k8s.io/api/coordination/v1alpha1"
|
coordinationv1alpha2 "k8s.io/api/coordination/v1alpha2"
|
||||||
labels "k8s.io/apimachinery/pkg/labels"
|
labels "k8s.io/apimachinery/pkg/labels"
|
||||||
listers "k8s.io/client-go/listers"
|
listers "k8s.io/client-go/listers"
|
||||||
cache "k8s.io/client-go/tools/cache"
|
cache "k8s.io/client-go/tools/cache"
|
||||||
@ -30,7 +30,7 @@ import (
|
|||||||
type LeaseCandidateLister interface {
|
type LeaseCandidateLister interface {
|
||||||
// List lists all LeaseCandidates in the indexer.
|
// List lists all LeaseCandidates in the indexer.
|
||||||
// Objects returned here must be treated as read-only.
|
// Objects returned here must be treated as read-only.
|
||||||
List(selector labels.Selector) (ret []*coordinationv1alpha1.LeaseCandidate, err error)
|
List(selector labels.Selector) (ret []*coordinationv1alpha2.LeaseCandidate, err error)
|
||||||
// LeaseCandidates returns an object that can list and get LeaseCandidates.
|
// LeaseCandidates returns an object that can list and get LeaseCandidates.
|
||||||
LeaseCandidates(namespace string) LeaseCandidateNamespaceLister
|
LeaseCandidates(namespace string) LeaseCandidateNamespaceLister
|
||||||
LeaseCandidateListerExpansion
|
LeaseCandidateListerExpansion
|
||||||
@ -38,17 +38,17 @@ type LeaseCandidateLister interface {
|
|||||||
|
|
||||||
// leaseCandidateLister implements the LeaseCandidateLister interface.
|
// leaseCandidateLister implements the LeaseCandidateLister interface.
|
||||||
type leaseCandidateLister struct {
|
type leaseCandidateLister struct {
|
||||||
listers.ResourceIndexer[*coordinationv1alpha1.LeaseCandidate]
|
listers.ResourceIndexer[*coordinationv1alpha2.LeaseCandidate]
|
||||||
}
|
}
|
||||||
|
|
||||||
// NewLeaseCandidateLister returns a new LeaseCandidateLister.
|
// NewLeaseCandidateLister returns a new LeaseCandidateLister.
|
||||||
func NewLeaseCandidateLister(indexer cache.Indexer) LeaseCandidateLister {
|
func NewLeaseCandidateLister(indexer cache.Indexer) LeaseCandidateLister {
|
||||||
return &leaseCandidateLister{listers.New[*coordinationv1alpha1.LeaseCandidate](indexer, coordinationv1alpha1.Resource("leasecandidate"))}
|
return &leaseCandidateLister{listers.New[*coordinationv1alpha2.LeaseCandidate](indexer, coordinationv1alpha2.Resource("leasecandidate"))}
|
||||||
}
|
}
|
||||||
|
|
||||||
// LeaseCandidates returns an object that can list and get LeaseCandidates.
|
// LeaseCandidates returns an object that can list and get LeaseCandidates.
|
||||||
func (s *leaseCandidateLister) LeaseCandidates(namespace string) LeaseCandidateNamespaceLister {
|
func (s *leaseCandidateLister) LeaseCandidates(namespace string) LeaseCandidateNamespaceLister {
|
||||||
return leaseCandidateNamespaceLister{listers.NewNamespaced[*coordinationv1alpha1.LeaseCandidate](s.ResourceIndexer, namespace)}
|
return leaseCandidateNamespaceLister{listers.NewNamespaced[*coordinationv1alpha2.LeaseCandidate](s.ResourceIndexer, namespace)}
|
||||||
}
|
}
|
||||||
|
|
||||||
// LeaseCandidateNamespaceLister helps list and get LeaseCandidates.
|
// LeaseCandidateNamespaceLister helps list and get LeaseCandidates.
|
||||||
@ -56,15 +56,15 @@ func (s *leaseCandidateLister) LeaseCandidates(namespace string) LeaseCandidateN
|
|||||||
type LeaseCandidateNamespaceLister interface {
|
type LeaseCandidateNamespaceLister interface {
|
||||||
// List lists all LeaseCandidates in the indexer for a given namespace.
|
// List lists all LeaseCandidates in the indexer for a given namespace.
|
||||||
// Objects returned here must be treated as read-only.
|
// Objects returned here must be treated as read-only.
|
||||||
List(selector labels.Selector) (ret []*coordinationv1alpha1.LeaseCandidate, err error)
|
List(selector labels.Selector) (ret []*coordinationv1alpha2.LeaseCandidate, err error)
|
||||||
// Get retrieves the LeaseCandidate from the indexer for a given namespace and name.
|
// Get retrieves the LeaseCandidate from the indexer for a given namespace and name.
|
||||||
// Objects returned here must be treated as read-only.
|
// Objects returned here must be treated as read-only.
|
||||||
Get(name string) (*coordinationv1alpha1.LeaseCandidate, error)
|
Get(name string) (*coordinationv1alpha2.LeaseCandidate, error)
|
||||||
LeaseCandidateNamespaceListerExpansion
|
LeaseCandidateNamespaceListerExpansion
|
||||||
}
|
}
|
||||||
|
|
||||||
// leaseCandidateNamespaceLister implements the LeaseCandidateNamespaceLister
|
// leaseCandidateNamespaceLister implements the LeaseCandidateNamespaceLister
|
||||||
// interface.
|
// interface.
|
||||||
type leaseCandidateNamespaceLister struct {
|
type leaseCandidateNamespaceLister struct {
|
||||||
listers.ResourceIndexer[*coordinationv1alpha1.LeaseCandidate]
|
listers.ResourceIndexer[*coordinationv1alpha2.LeaseCandidate]
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user