mirror of
https://github.com/kubernetes/client-go.git
synced 2025-06-26 15:12:06 +00:00
Graduate EndpointSlice API to GA
* Removes discovery v1alpha1 API * Replaces per Endpoint Topology with a read only DeprecatedTopology in GA API * Adds per Endpoint Zone field in GA API Kubernetes-commit: a9891b4b9b909b76533a50812c21575cd96c43b1
This commit is contained in:
parent
d2a6442e7d
commit
2eb8aff5d3
@ -16,21 +16,22 @@ limitations under the License.
|
|||||||
|
|
||||||
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||||
|
|
||||||
package v1alpha1
|
package v1
|
||||||
|
|
||||||
import (
|
import (
|
||||||
v1 "k8s.io/client-go/applyconfigurations/core/v1"
|
corev1 "k8s.io/client-go/applyconfigurations/core/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
// EndpointApplyConfiguration represents an declarative configuration of the Endpoint type for use
|
// EndpointApplyConfiguration represents an declarative configuration of the Endpoint type for use
|
||||||
// with apply.
|
// with apply.
|
||||||
type EndpointApplyConfiguration struct {
|
type EndpointApplyConfiguration struct {
|
||||||
Addresses []string `json:"addresses,omitempty"`
|
Addresses []string `json:"addresses,omitempty"`
|
||||||
Conditions *EndpointConditionsApplyConfiguration `json:"conditions,omitempty"`
|
Conditions *EndpointConditionsApplyConfiguration `json:"conditions,omitempty"`
|
||||||
Hostname *string `json:"hostname,omitempty"`
|
Hostname *string `json:"hostname,omitempty"`
|
||||||
TargetRef *v1.ObjectReferenceApplyConfiguration `json:"targetRef,omitempty"`
|
TargetRef *corev1.ObjectReferenceApplyConfiguration `json:"targetRef,omitempty"`
|
||||||
Topology map[string]string `json:"topology,omitempty"`
|
DeprecatedTopology map[string]string `json:"deprecatedTopology,omitempty"`
|
||||||
NodeName *string `json:"nodeName,omitempty"`
|
NodeName *string `json:"nodeName,omitempty"`
|
||||||
|
Zone *string `json:"zone,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// EndpointApplyConfiguration constructs an declarative configuration of the Endpoint type for use with
|
// EndpointApplyConfiguration constructs an declarative configuration of the Endpoint type for use with
|
||||||
@ -68,21 +69,21 @@ func (b *EndpointApplyConfiguration) WithHostname(value string) *EndpointApplyCo
|
|||||||
// WithTargetRef sets the TargetRef field in the declarative configuration to the given value
|
// WithTargetRef sets the TargetRef field in the declarative configuration to the given value
|
||||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
// If called multiple times, the TargetRef field is set to the value of the last call.
|
// If called multiple times, the TargetRef field is set to the value of the last call.
|
||||||
func (b *EndpointApplyConfiguration) WithTargetRef(value *v1.ObjectReferenceApplyConfiguration) *EndpointApplyConfiguration {
|
func (b *EndpointApplyConfiguration) WithTargetRef(value *corev1.ObjectReferenceApplyConfiguration) *EndpointApplyConfiguration {
|
||||||
b.TargetRef = value
|
b.TargetRef = value
|
||||||
return b
|
return b
|
||||||
}
|
}
|
||||||
|
|
||||||
// WithTopology puts the entries into the Topology field in the declarative configuration
|
// WithDeprecatedTopology puts the entries into the DeprecatedTopology field in the declarative configuration
|
||||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||||
// If called multiple times, the entries provided by each call will be put on the Topology field,
|
// If called multiple times, the entries provided by each call will be put on the DeprecatedTopology field,
|
||||||
// overwriting an existing map entries in Topology field with the same key.
|
// overwriting an existing map entries in DeprecatedTopology field with the same key.
|
||||||
func (b *EndpointApplyConfiguration) WithTopology(entries map[string]string) *EndpointApplyConfiguration {
|
func (b *EndpointApplyConfiguration) WithDeprecatedTopology(entries map[string]string) *EndpointApplyConfiguration {
|
||||||
if b.Topology == nil && len(entries) > 0 {
|
if b.DeprecatedTopology == nil && len(entries) > 0 {
|
||||||
b.Topology = make(map[string]string, len(entries))
|
b.DeprecatedTopology = make(map[string]string, len(entries))
|
||||||
}
|
}
|
||||||
for k, v := range entries {
|
for k, v := range entries {
|
||||||
b.Topology[k] = v
|
b.DeprecatedTopology[k] = v
|
||||||
}
|
}
|
||||||
return b
|
return b
|
||||||
}
|
}
|
||||||
@ -94,3 +95,11 @@ func (b *EndpointApplyConfiguration) WithNodeName(value string) *EndpointApplyCo
|
|||||||
b.NodeName = &value
|
b.NodeName = &value
|
||||||
return b
|
return b
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// WithZone sets the Zone field in the declarative configuration to the given value
|
||||||
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
|
// If called multiple times, the Zone field is set to the value of the last call.
|
||||||
|
func (b *EndpointApplyConfiguration) WithZone(value string) *EndpointApplyConfiguration {
|
||||||
|
b.Zone = &value
|
||||||
|
return b
|
||||||
|
}
|
@ -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 v1
|
||||||
|
|
||||||
// EndpointConditionsApplyConfiguration represents an declarative configuration of the EndpointConditions type for use
|
// EndpointConditionsApplyConfiguration represents an declarative configuration of the EndpointConditions type for use
|
||||||
// with apply.
|
// with apply.
|
@ -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 v1
|
||||||
|
|
||||||
import (
|
import (
|
||||||
v1 "k8s.io/api/core/v1"
|
v1 "k8s.io/api/core/v1"
|
@ -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 v1
|
||||||
|
|
||||||
import (
|
import (
|
||||||
v1alpha1 "k8s.io/api/discovery/v1alpha1"
|
discoveryv1 "k8s.io/api/discovery/v1"
|
||||||
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"
|
||||||
v1 "k8s.io/client-go/applyconfigurations/meta/v1"
|
v1 "k8s.io/client-go/applyconfigurations/meta/v1"
|
||||||
@ -30,7 +30,7 @@ import (
|
|||||||
type EndpointSliceApplyConfiguration struct {
|
type EndpointSliceApplyConfiguration struct {
|
||||||
v1.TypeMetaApplyConfiguration `json:",inline"`
|
v1.TypeMetaApplyConfiguration `json:",inline"`
|
||||||
*v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"`
|
*v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"`
|
||||||
AddressType *v1alpha1.AddressType `json:"addressType,omitempty"`
|
AddressType *discoveryv1.AddressType `json:"addressType,omitempty"`
|
||||||
Endpoints []EndpointApplyConfiguration `json:"endpoints,omitempty"`
|
Endpoints []EndpointApplyConfiguration `json:"endpoints,omitempty"`
|
||||||
Ports []EndpointPortApplyConfiguration `json:"ports,omitempty"`
|
Ports []EndpointPortApplyConfiguration `json:"ports,omitempty"`
|
||||||
}
|
}
|
||||||
@ -42,7 +42,7 @@ func EndpointSlice(name, namespace string) *EndpointSliceApplyConfiguration {
|
|||||||
b.WithName(name)
|
b.WithName(name)
|
||||||
b.WithNamespace(namespace)
|
b.WithNamespace(namespace)
|
||||||
b.WithKind("EndpointSlice")
|
b.WithKind("EndpointSlice")
|
||||||
b.WithAPIVersion("discovery.k8s.io/v1alpha1")
|
b.WithAPIVersion("discovery.k8s.io/v1")
|
||||||
return b
|
return b
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -225,7 +225,7 @@ func (b *EndpointSliceApplyConfiguration) ensureObjectMetaApplyConfigurationExis
|
|||||||
// WithAddressType sets the AddressType field in the declarative configuration to the given value
|
// WithAddressType sets the AddressType field in the declarative configuration to the given value
|
||||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||||
// If called multiple times, the AddressType field is set to the value of the last call.
|
// If called multiple times, the AddressType field is set to the value of the last call.
|
||||||
func (b *EndpointSliceApplyConfiguration) WithAddressType(value v1alpha1.AddressType) *EndpointSliceApplyConfiguration {
|
func (b *EndpointSliceApplyConfiguration) WithAddressType(value discoveryv1.AddressType) *EndpointSliceApplyConfiguration {
|
||||||
b.AddressType = &value
|
b.AddressType = &value
|
||||||
return b
|
return b
|
||||||
}
|
}
|
@ -35,12 +35,12 @@ import (
|
|||||||
coordinationv1 "k8s.io/api/coordination/v1"
|
coordinationv1 "k8s.io/api/coordination/v1"
|
||||||
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
||||||
corev1 "k8s.io/api/core/v1"
|
corev1 "k8s.io/api/core/v1"
|
||||||
v1alpha1 "k8s.io/api/discovery/v1alpha1"
|
discoveryv1 "k8s.io/api/discovery/v1"
|
||||||
discoveryv1beta1 "k8s.io/api/discovery/v1beta1"
|
discoveryv1beta1 "k8s.io/api/discovery/v1beta1"
|
||||||
eventsv1 "k8s.io/api/events/v1"
|
eventsv1 "k8s.io/api/events/v1"
|
||||||
eventsv1beta1 "k8s.io/api/events/v1beta1"
|
eventsv1beta1 "k8s.io/api/events/v1beta1"
|
||||||
extensionsv1beta1 "k8s.io/api/extensions/v1beta1"
|
extensionsv1beta1 "k8s.io/api/extensions/v1beta1"
|
||||||
flowcontrolv1alpha1 "k8s.io/api/flowcontrol/v1alpha1"
|
v1alpha1 "k8s.io/api/flowcontrol/v1alpha1"
|
||||||
flowcontrolv1beta1 "k8s.io/api/flowcontrol/v1beta1"
|
flowcontrolv1beta1 "k8s.io/api/flowcontrol/v1beta1"
|
||||||
imagepolicyv1alpha1 "k8s.io/api/imagepolicy/v1alpha1"
|
imagepolicyv1alpha1 "k8s.io/api/imagepolicy/v1alpha1"
|
||||||
networkingv1 "k8s.io/api/networking/v1"
|
networkingv1 "k8s.io/api/networking/v1"
|
||||||
@ -76,12 +76,12 @@ import (
|
|||||||
applyconfigurationscoordinationv1 "k8s.io/client-go/applyconfigurations/coordination/v1"
|
applyconfigurationscoordinationv1 "k8s.io/client-go/applyconfigurations/coordination/v1"
|
||||||
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"
|
||||||
discoveryv1alpha1 "k8s.io/client-go/applyconfigurations/discovery/v1alpha1"
|
applyconfigurationsdiscoveryv1 "k8s.io/client-go/applyconfigurations/discovery/v1"
|
||||||
applyconfigurationsdiscoveryv1beta1 "k8s.io/client-go/applyconfigurations/discovery/v1beta1"
|
applyconfigurationsdiscoveryv1beta1 "k8s.io/client-go/applyconfigurations/discovery/v1beta1"
|
||||||
applyconfigurationseventsv1 "k8s.io/client-go/applyconfigurations/events/v1"
|
applyconfigurationseventsv1 "k8s.io/client-go/applyconfigurations/events/v1"
|
||||||
applyconfigurationseventsv1beta1 "k8s.io/client-go/applyconfigurations/events/v1beta1"
|
applyconfigurationseventsv1beta1 "k8s.io/client-go/applyconfigurations/events/v1beta1"
|
||||||
applyconfigurationsextensionsv1beta1 "k8s.io/client-go/applyconfigurations/extensions/v1beta1"
|
applyconfigurationsextensionsv1beta1 "k8s.io/client-go/applyconfigurations/extensions/v1beta1"
|
||||||
applyconfigurationsflowcontrolv1alpha1 "k8s.io/client-go/applyconfigurations/flowcontrol/v1alpha1"
|
flowcontrolv1alpha1 "k8s.io/client-go/applyconfigurations/flowcontrol/v1alpha1"
|
||||||
applyconfigurationsflowcontrolv1beta1 "k8s.io/client-go/applyconfigurations/flowcontrol/v1beta1"
|
applyconfigurationsflowcontrolv1beta1 "k8s.io/client-go/applyconfigurations/flowcontrol/v1beta1"
|
||||||
applyconfigurationsimagepolicyv1alpha1 "k8s.io/client-go/applyconfigurations/imagepolicy/v1alpha1"
|
applyconfigurationsimagepolicyv1alpha1 "k8s.io/client-go/applyconfigurations/imagepolicy/v1alpha1"
|
||||||
applyconfigurationsmetav1 "k8s.io/client-go/applyconfigurations/meta/v1"
|
applyconfigurationsmetav1 "k8s.io/client-go/applyconfigurations/meta/v1"
|
||||||
@ -772,15 +772,15 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
|
|||||||
case corev1.SchemeGroupVersion.WithKind("WindowsSecurityContextOptions"):
|
case corev1.SchemeGroupVersion.WithKind("WindowsSecurityContextOptions"):
|
||||||
return &applyconfigurationscorev1.WindowsSecurityContextOptionsApplyConfiguration{}
|
return &applyconfigurationscorev1.WindowsSecurityContextOptionsApplyConfiguration{}
|
||||||
|
|
||||||
// Group=discovery.k8s.io, Version=v1alpha1
|
// Group=discovery.k8s.io, Version=v1
|
||||||
case v1alpha1.SchemeGroupVersion.WithKind("Endpoint"):
|
case discoveryv1.SchemeGroupVersion.WithKind("Endpoint"):
|
||||||
return &discoveryv1alpha1.EndpointApplyConfiguration{}
|
return &applyconfigurationsdiscoveryv1.EndpointApplyConfiguration{}
|
||||||
case v1alpha1.SchemeGroupVersion.WithKind("EndpointConditions"):
|
case discoveryv1.SchemeGroupVersion.WithKind("EndpointConditions"):
|
||||||
return &discoveryv1alpha1.EndpointConditionsApplyConfiguration{}
|
return &applyconfigurationsdiscoveryv1.EndpointConditionsApplyConfiguration{}
|
||||||
case v1alpha1.SchemeGroupVersion.WithKind("EndpointPort"):
|
case discoveryv1.SchemeGroupVersion.WithKind("EndpointPort"):
|
||||||
return &discoveryv1alpha1.EndpointPortApplyConfiguration{}
|
return &applyconfigurationsdiscoveryv1.EndpointPortApplyConfiguration{}
|
||||||
case v1alpha1.SchemeGroupVersion.WithKind("EndpointSlice"):
|
case discoveryv1.SchemeGroupVersion.WithKind("EndpointSlice"):
|
||||||
return &discoveryv1alpha1.EndpointSliceApplyConfiguration{}
|
return &applyconfigurationsdiscoveryv1.EndpointSliceApplyConfiguration{}
|
||||||
|
|
||||||
// Group=discovery.k8s.io, Version=v1beta1
|
// Group=discovery.k8s.io, Version=v1beta1
|
||||||
case discoveryv1beta1.SchemeGroupVersion.WithKind("Endpoint"):
|
case discoveryv1beta1.SchemeGroupVersion.WithKind("Endpoint"):
|
||||||
@ -899,46 +899,46 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
|
|||||||
return &applyconfigurationsextensionsv1beta1.SupplementalGroupsStrategyOptionsApplyConfiguration{}
|
return &applyconfigurationsextensionsv1beta1.SupplementalGroupsStrategyOptionsApplyConfiguration{}
|
||||||
|
|
||||||
// Group=flowcontrol.apiserver.k8s.io, Version=v1alpha1
|
// Group=flowcontrol.apiserver.k8s.io, Version=v1alpha1
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("FlowDistinguisherMethod"):
|
case v1alpha1.SchemeGroupVersion.WithKind("FlowDistinguisherMethod"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.FlowDistinguisherMethodApplyConfiguration{}
|
return &flowcontrolv1alpha1.FlowDistinguisherMethodApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("FlowSchema"):
|
case v1alpha1.SchemeGroupVersion.WithKind("FlowSchema"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.FlowSchemaApplyConfiguration{}
|
return &flowcontrolv1alpha1.FlowSchemaApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("FlowSchemaCondition"):
|
case v1alpha1.SchemeGroupVersion.WithKind("FlowSchemaCondition"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.FlowSchemaConditionApplyConfiguration{}
|
return &flowcontrolv1alpha1.FlowSchemaConditionApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("FlowSchemaSpec"):
|
case v1alpha1.SchemeGroupVersion.WithKind("FlowSchemaSpec"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.FlowSchemaSpecApplyConfiguration{}
|
return &flowcontrolv1alpha1.FlowSchemaSpecApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("FlowSchemaStatus"):
|
case v1alpha1.SchemeGroupVersion.WithKind("FlowSchemaStatus"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.FlowSchemaStatusApplyConfiguration{}
|
return &flowcontrolv1alpha1.FlowSchemaStatusApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("GroupSubject"):
|
case v1alpha1.SchemeGroupVersion.WithKind("GroupSubject"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.GroupSubjectApplyConfiguration{}
|
return &flowcontrolv1alpha1.GroupSubjectApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("LimitedPriorityLevelConfiguration"):
|
case v1alpha1.SchemeGroupVersion.WithKind("LimitedPriorityLevelConfiguration"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.LimitedPriorityLevelConfigurationApplyConfiguration{}
|
return &flowcontrolv1alpha1.LimitedPriorityLevelConfigurationApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("LimitResponse"):
|
case v1alpha1.SchemeGroupVersion.WithKind("LimitResponse"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.LimitResponseApplyConfiguration{}
|
return &flowcontrolv1alpha1.LimitResponseApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("NonResourcePolicyRule"):
|
case v1alpha1.SchemeGroupVersion.WithKind("NonResourcePolicyRule"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.NonResourcePolicyRuleApplyConfiguration{}
|
return &flowcontrolv1alpha1.NonResourcePolicyRuleApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("PolicyRulesWithSubjects"):
|
case v1alpha1.SchemeGroupVersion.WithKind("PolicyRulesWithSubjects"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.PolicyRulesWithSubjectsApplyConfiguration{}
|
return &flowcontrolv1alpha1.PolicyRulesWithSubjectsApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("PriorityLevelConfiguration"):
|
case v1alpha1.SchemeGroupVersion.WithKind("PriorityLevelConfiguration"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.PriorityLevelConfigurationApplyConfiguration{}
|
return &flowcontrolv1alpha1.PriorityLevelConfigurationApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("PriorityLevelConfigurationCondition"):
|
case v1alpha1.SchemeGroupVersion.WithKind("PriorityLevelConfigurationCondition"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.PriorityLevelConfigurationConditionApplyConfiguration{}
|
return &flowcontrolv1alpha1.PriorityLevelConfigurationConditionApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("PriorityLevelConfigurationReference"):
|
case v1alpha1.SchemeGroupVersion.WithKind("PriorityLevelConfigurationReference"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.PriorityLevelConfigurationReferenceApplyConfiguration{}
|
return &flowcontrolv1alpha1.PriorityLevelConfigurationReferenceApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("PriorityLevelConfigurationSpec"):
|
case v1alpha1.SchemeGroupVersion.WithKind("PriorityLevelConfigurationSpec"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.PriorityLevelConfigurationSpecApplyConfiguration{}
|
return &flowcontrolv1alpha1.PriorityLevelConfigurationSpecApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("PriorityLevelConfigurationStatus"):
|
case v1alpha1.SchemeGroupVersion.WithKind("PriorityLevelConfigurationStatus"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.PriorityLevelConfigurationStatusApplyConfiguration{}
|
return &flowcontrolv1alpha1.PriorityLevelConfigurationStatusApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("QueuingConfiguration"):
|
case v1alpha1.SchemeGroupVersion.WithKind("QueuingConfiguration"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.QueuingConfigurationApplyConfiguration{}
|
return &flowcontrolv1alpha1.QueuingConfigurationApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("ResourcePolicyRule"):
|
case v1alpha1.SchemeGroupVersion.WithKind("ResourcePolicyRule"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.ResourcePolicyRuleApplyConfiguration{}
|
return &flowcontrolv1alpha1.ResourcePolicyRuleApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("ServiceAccountSubject"):
|
case v1alpha1.SchemeGroupVersion.WithKind("ServiceAccountSubject"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.ServiceAccountSubjectApplyConfiguration{}
|
return &flowcontrolv1alpha1.ServiceAccountSubjectApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("Subject"):
|
case v1alpha1.SchemeGroupVersion.WithKind("Subject"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.SubjectApplyConfiguration{}
|
return &flowcontrolv1alpha1.SubjectApplyConfiguration{}
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithKind("UserSubject"):
|
case v1alpha1.SchemeGroupVersion.WithKind("UserSubject"):
|
||||||
return &applyconfigurationsflowcontrolv1alpha1.UserSubjectApplyConfiguration{}
|
return &flowcontrolv1alpha1.UserSubjectApplyConfiguration{}
|
||||||
|
|
||||||
// Group=flowcontrol.apiserver.k8s.io, Version=v1beta1
|
// Group=flowcontrol.apiserver.k8s.io, Version=v1beta1
|
||||||
case flowcontrolv1beta1.SchemeGroupVersion.WithKind("FlowDistinguisherMethod"):
|
case flowcontrolv1beta1.SchemeGroupVersion.WithKind("FlowDistinguisherMethod"):
|
||||||
|
@ -19,15 +19,15 @@ limitations under the License.
|
|||||||
package discovery
|
package discovery
|
||||||
|
|
||||||
import (
|
import (
|
||||||
v1alpha1 "k8s.io/client-go/informers/discovery/v1alpha1"
|
v1 "k8s.io/client-go/informers/discovery/v1"
|
||||||
v1beta1 "k8s.io/client-go/informers/discovery/v1beta1"
|
v1beta1 "k8s.io/client-go/informers/discovery/v1beta1"
|
||||||
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Interface provides access to each of this group's versions.
|
// Interface provides access to each of this group's versions.
|
||||||
type Interface interface {
|
type Interface interface {
|
||||||
// V1alpha1 provides access to shared informers for resources in V1alpha1.
|
// V1 provides access to shared informers for resources in V1.
|
||||||
V1alpha1() v1alpha1.Interface
|
V1() v1.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
|
||||||
}
|
}
|
||||||
@ -43,9 +43,9 @@ func New(f internalinterfaces.SharedInformerFactory, namespace string, tweakList
|
|||||||
return &group{factory: f, namespace: namespace, tweakListOptions: tweakListOptions}
|
return &group{factory: f, namespace: namespace, tweakListOptions: tweakListOptions}
|
||||||
}
|
}
|
||||||
|
|
||||||
// V1alpha1 returns a new v1alpha1.Interface.
|
// V1 returns a new v1.Interface.
|
||||||
func (g *group) V1alpha1() v1alpha1.Interface {
|
func (g *group) V1() v1.Interface {
|
||||||
return v1alpha1.New(g.factory, g.namespace, g.tweakListOptions)
|
return v1.New(g.factory, g.namespace, g.tweakListOptions)
|
||||||
}
|
}
|
||||||
|
|
||||||
// V1beta1 returns a new v1beta1.Interface.
|
// V1beta1 returns a new v1beta1.Interface.
|
||||||
|
@ -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 v1
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
time "time"
|
time "time"
|
||||||
|
|
||||||
discoveryv1alpha1 "k8s.io/api/discovery/v1alpha1"
|
discoveryv1 "k8s.io/api/discovery/v1"
|
||||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
metav1 "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"
|
||||||
v1alpha1 "k8s.io/client-go/listers/discovery/v1alpha1"
|
v1 "k8s.io/client-go/listers/discovery/v1"
|
||||||
cache "k8s.io/client-go/tools/cache"
|
cache "k8s.io/client-go/tools/cache"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -36,7 +36,7 @@ import (
|
|||||||
// EndpointSlices.
|
// EndpointSlices.
|
||||||
type EndpointSliceInformer interface {
|
type EndpointSliceInformer interface {
|
||||||
Informer() cache.SharedIndexInformer
|
Informer() cache.SharedIndexInformer
|
||||||
Lister() v1alpha1.EndpointSliceLister
|
Lister() v1.EndpointSliceLister
|
||||||
}
|
}
|
||||||
|
|
||||||
type endpointSliceInformer struct {
|
type endpointSliceInformer struct {
|
||||||
@ -58,20 +58,20 @@ func NewEndpointSliceInformer(client kubernetes.Interface, namespace string, res
|
|||||||
func NewFilteredEndpointSliceInformer(client kubernetes.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
|
func NewFilteredEndpointSliceInformer(client kubernetes.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
|
||||||
return cache.NewSharedIndexInformer(
|
return cache.NewSharedIndexInformer(
|
||||||
&cache.ListWatch{
|
&cache.ListWatch{
|
||||||
ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
|
ListFunc: func(options metav1.ListOptions) (runtime.Object, error) {
|
||||||
if tweakListOptions != nil {
|
if tweakListOptions != nil {
|
||||||
tweakListOptions(&options)
|
tweakListOptions(&options)
|
||||||
}
|
}
|
||||||
return client.DiscoveryV1alpha1().EndpointSlices(namespace).List(context.TODO(), options)
|
return client.DiscoveryV1().EndpointSlices(namespace).List(context.TODO(), options)
|
||||||
},
|
},
|
||||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) {
|
||||||
if tweakListOptions != nil {
|
if tweakListOptions != nil {
|
||||||
tweakListOptions(&options)
|
tweakListOptions(&options)
|
||||||
}
|
}
|
||||||
return client.DiscoveryV1alpha1().EndpointSlices(namespace).Watch(context.TODO(), options)
|
return client.DiscoveryV1().EndpointSlices(namespace).Watch(context.TODO(), options)
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
&discoveryv1alpha1.EndpointSlice{},
|
&discoveryv1.EndpointSlice{},
|
||||||
resyncPeriod,
|
resyncPeriod,
|
||||||
indexers,
|
indexers,
|
||||||
)
|
)
|
||||||
@ -82,9 +82,9 @@ func (f *endpointSliceInformer) defaultInformer(client kubernetes.Interface, res
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (f *endpointSliceInformer) Informer() cache.SharedIndexInformer {
|
func (f *endpointSliceInformer) Informer() cache.SharedIndexInformer {
|
||||||
return f.factory.InformerFor(&discoveryv1alpha1.EndpointSlice{}, f.defaultInformer)
|
return f.factory.InformerFor(&discoveryv1.EndpointSlice{}, f.defaultInformer)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (f *endpointSliceInformer) Lister() v1alpha1.EndpointSliceLister {
|
func (f *endpointSliceInformer) Lister() v1.EndpointSliceLister {
|
||||||
return v1alpha1.NewEndpointSliceLister(f.Informer().GetIndexer())
|
return v1.NewEndpointSliceLister(f.Informer().GetIndexer())
|
||||||
}
|
}
|
@ -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 v1
|
||||||
|
|
||||||
import (
|
import (
|
||||||
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
@ -37,12 +37,12 @@ import (
|
|||||||
coordinationv1 "k8s.io/api/coordination/v1"
|
coordinationv1 "k8s.io/api/coordination/v1"
|
||||||
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
||||||
corev1 "k8s.io/api/core/v1"
|
corev1 "k8s.io/api/core/v1"
|
||||||
v1alpha1 "k8s.io/api/discovery/v1alpha1"
|
discoveryv1 "k8s.io/api/discovery/v1"
|
||||||
discoveryv1beta1 "k8s.io/api/discovery/v1beta1"
|
discoveryv1beta1 "k8s.io/api/discovery/v1beta1"
|
||||||
eventsv1 "k8s.io/api/events/v1"
|
eventsv1 "k8s.io/api/events/v1"
|
||||||
eventsv1beta1 "k8s.io/api/events/v1beta1"
|
eventsv1beta1 "k8s.io/api/events/v1beta1"
|
||||||
extensionsv1beta1 "k8s.io/api/extensions/v1beta1"
|
extensionsv1beta1 "k8s.io/api/extensions/v1beta1"
|
||||||
flowcontrolv1alpha1 "k8s.io/api/flowcontrol/v1alpha1"
|
v1alpha1 "k8s.io/api/flowcontrol/v1alpha1"
|
||||||
flowcontrolv1beta1 "k8s.io/api/flowcontrol/v1beta1"
|
flowcontrolv1beta1 "k8s.io/api/flowcontrol/v1beta1"
|
||||||
networkingv1 "k8s.io/api/networking/v1"
|
networkingv1 "k8s.io/api/networking/v1"
|
||||||
networkingv1beta1 "k8s.io/api/networking/v1beta1"
|
networkingv1beta1 "k8s.io/api/networking/v1beta1"
|
||||||
@ -205,9 +205,9 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource
|
|||||||
case corev1.SchemeGroupVersion.WithResource("serviceaccounts"):
|
case corev1.SchemeGroupVersion.WithResource("serviceaccounts"):
|
||||||
return &genericInformer{resource: resource.GroupResource(), informer: f.Core().V1().ServiceAccounts().Informer()}, nil
|
return &genericInformer{resource: resource.GroupResource(), informer: f.Core().V1().ServiceAccounts().Informer()}, nil
|
||||||
|
|
||||||
// Group=discovery.k8s.io, Version=v1alpha1
|
// Group=discovery.k8s.io, Version=v1
|
||||||
case v1alpha1.SchemeGroupVersion.WithResource("endpointslices"):
|
case discoveryv1.SchemeGroupVersion.WithResource("endpointslices"):
|
||||||
return &genericInformer{resource: resource.GroupResource(), informer: f.Discovery().V1alpha1().EndpointSlices().Informer()}, nil
|
return &genericInformer{resource: resource.GroupResource(), informer: f.Discovery().V1().EndpointSlices().Informer()}, nil
|
||||||
|
|
||||||
// Group=discovery.k8s.io, Version=v1beta1
|
// Group=discovery.k8s.io, Version=v1beta1
|
||||||
case discoveryv1beta1.SchemeGroupVersion.WithResource("endpointslices"):
|
case discoveryv1beta1.SchemeGroupVersion.WithResource("endpointslices"):
|
||||||
@ -236,9 +236,9 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource
|
|||||||
return &genericInformer{resource: resource.GroupResource(), informer: f.Extensions().V1beta1().ReplicaSets().Informer()}, nil
|
return &genericInformer{resource: resource.GroupResource(), informer: f.Extensions().V1beta1().ReplicaSets().Informer()}, nil
|
||||||
|
|
||||||
// Group=flowcontrol.apiserver.k8s.io, Version=v1alpha1
|
// Group=flowcontrol.apiserver.k8s.io, Version=v1alpha1
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithResource("flowschemas"):
|
case v1alpha1.SchemeGroupVersion.WithResource("flowschemas"):
|
||||||
return &genericInformer{resource: resource.GroupResource(), informer: f.Flowcontrol().V1alpha1().FlowSchemas().Informer()}, nil
|
return &genericInformer{resource: resource.GroupResource(), informer: f.Flowcontrol().V1alpha1().FlowSchemas().Informer()}, nil
|
||||||
case flowcontrolv1alpha1.SchemeGroupVersion.WithResource("prioritylevelconfigurations"):
|
case v1alpha1.SchemeGroupVersion.WithResource("prioritylevelconfigurations"):
|
||||||
return &genericInformer{resource: resource.GroupResource(), informer: f.Flowcontrol().V1alpha1().PriorityLevelConfigurations().Informer()}, nil
|
return &genericInformer{resource: resource.GroupResource(), informer: f.Flowcontrol().V1alpha1().PriorityLevelConfigurations().Informer()}, nil
|
||||||
|
|
||||||
// Group=flowcontrol.apiserver.k8s.io, Version=v1beta1
|
// Group=flowcontrol.apiserver.k8s.io, Version=v1beta1
|
||||||
|
@ -42,7 +42,7 @@ import (
|
|||||||
coordinationv1 "k8s.io/client-go/kubernetes/typed/coordination/v1"
|
coordinationv1 "k8s.io/client-go/kubernetes/typed/coordination/v1"
|
||||||
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"
|
||||||
discoveryv1alpha1 "k8s.io/client-go/kubernetes/typed/discovery/v1alpha1"
|
discoveryv1 "k8s.io/client-go/kubernetes/typed/discovery/v1"
|
||||||
discoveryv1beta1 "k8s.io/client-go/kubernetes/typed/discovery/v1beta1"
|
discoveryv1beta1 "k8s.io/client-go/kubernetes/typed/discovery/v1beta1"
|
||||||
eventsv1 "k8s.io/client-go/kubernetes/typed/events/v1"
|
eventsv1 "k8s.io/client-go/kubernetes/typed/events/v1"
|
||||||
eventsv1beta1 "k8s.io/client-go/kubernetes/typed/events/v1beta1"
|
eventsv1beta1 "k8s.io/client-go/kubernetes/typed/events/v1beta1"
|
||||||
@ -90,7 +90,7 @@ type Interface interface {
|
|||||||
CoordinationV1beta1() coordinationv1beta1.CoordinationV1beta1Interface
|
CoordinationV1beta1() coordinationv1beta1.CoordinationV1beta1Interface
|
||||||
CoordinationV1() coordinationv1.CoordinationV1Interface
|
CoordinationV1() coordinationv1.CoordinationV1Interface
|
||||||
CoreV1() corev1.CoreV1Interface
|
CoreV1() corev1.CoreV1Interface
|
||||||
DiscoveryV1alpha1() discoveryv1alpha1.DiscoveryV1alpha1Interface
|
DiscoveryV1() discoveryv1.DiscoveryV1Interface
|
||||||
DiscoveryV1beta1() discoveryv1beta1.DiscoveryV1beta1Interface
|
DiscoveryV1beta1() discoveryv1beta1.DiscoveryV1beta1Interface
|
||||||
EventsV1() eventsv1.EventsV1Interface
|
EventsV1() eventsv1.EventsV1Interface
|
||||||
EventsV1beta1() eventsv1beta1.EventsV1beta1Interface
|
EventsV1beta1() eventsv1beta1.EventsV1beta1Interface
|
||||||
@ -138,7 +138,7 @@ type Clientset struct {
|
|||||||
coordinationV1beta1 *coordinationv1beta1.CoordinationV1beta1Client
|
coordinationV1beta1 *coordinationv1beta1.CoordinationV1beta1Client
|
||||||
coordinationV1 *coordinationv1.CoordinationV1Client
|
coordinationV1 *coordinationv1.CoordinationV1Client
|
||||||
coreV1 *corev1.CoreV1Client
|
coreV1 *corev1.CoreV1Client
|
||||||
discoveryV1alpha1 *discoveryv1alpha1.DiscoveryV1alpha1Client
|
discoveryV1 *discoveryv1.DiscoveryV1Client
|
||||||
discoveryV1beta1 *discoveryv1beta1.DiscoveryV1beta1Client
|
discoveryV1beta1 *discoveryv1beta1.DiscoveryV1beta1Client
|
||||||
eventsV1 *eventsv1.EventsV1Client
|
eventsV1 *eventsv1.EventsV1Client
|
||||||
eventsV1beta1 *eventsv1beta1.EventsV1beta1Client
|
eventsV1beta1 *eventsv1beta1.EventsV1beta1Client
|
||||||
@ -262,9 +262,9 @@ func (c *Clientset) CoreV1() corev1.CoreV1Interface {
|
|||||||
return c.coreV1
|
return c.coreV1
|
||||||
}
|
}
|
||||||
|
|
||||||
// DiscoveryV1alpha1 retrieves the DiscoveryV1alpha1Client
|
// DiscoveryV1 retrieves the DiscoveryV1Client
|
||||||
func (c *Clientset) DiscoveryV1alpha1() discoveryv1alpha1.DiscoveryV1alpha1Interface {
|
func (c *Clientset) DiscoveryV1() discoveryv1.DiscoveryV1Interface {
|
||||||
return c.discoveryV1alpha1
|
return c.discoveryV1
|
||||||
}
|
}
|
||||||
|
|
||||||
// DiscoveryV1beta1 retrieves the DiscoveryV1beta1Client
|
// DiscoveryV1beta1 retrieves the DiscoveryV1beta1Client
|
||||||
@ -473,7 +473,7 @@ func NewForConfig(c *rest.Config) (*Clientset, error) {
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
cs.discoveryV1alpha1, err = discoveryv1alpha1.NewForConfig(&configShallowCopy)
|
cs.discoveryV1, err = discoveryv1.NewForConfig(&configShallowCopy)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
@ -593,7 +593,7 @@ func NewForConfigOrDie(c *rest.Config) *Clientset {
|
|||||||
cs.coordinationV1beta1 = coordinationv1beta1.NewForConfigOrDie(c)
|
cs.coordinationV1beta1 = coordinationv1beta1.NewForConfigOrDie(c)
|
||||||
cs.coordinationV1 = coordinationv1.NewForConfigOrDie(c)
|
cs.coordinationV1 = coordinationv1.NewForConfigOrDie(c)
|
||||||
cs.coreV1 = corev1.NewForConfigOrDie(c)
|
cs.coreV1 = corev1.NewForConfigOrDie(c)
|
||||||
cs.discoveryV1alpha1 = discoveryv1alpha1.NewForConfigOrDie(c)
|
cs.discoveryV1 = discoveryv1.NewForConfigOrDie(c)
|
||||||
cs.discoveryV1beta1 = discoveryv1beta1.NewForConfigOrDie(c)
|
cs.discoveryV1beta1 = discoveryv1beta1.NewForConfigOrDie(c)
|
||||||
cs.eventsV1 = eventsv1.NewForConfigOrDie(c)
|
cs.eventsV1 = eventsv1.NewForConfigOrDie(c)
|
||||||
cs.eventsV1beta1 = eventsv1beta1.NewForConfigOrDie(c)
|
cs.eventsV1beta1 = eventsv1beta1.NewForConfigOrDie(c)
|
||||||
@ -643,7 +643,7 @@ func New(c rest.Interface) *Clientset {
|
|||||||
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)
|
||||||
cs.discoveryV1alpha1 = discoveryv1alpha1.New(c)
|
cs.discoveryV1 = discoveryv1.New(c)
|
||||||
cs.discoveryV1beta1 = discoveryv1beta1.New(c)
|
cs.discoveryV1beta1 = discoveryv1beta1.New(c)
|
||||||
cs.eventsV1 = eventsv1.New(c)
|
cs.eventsV1 = eventsv1.New(c)
|
||||||
cs.eventsV1beta1 = eventsv1beta1.New(c)
|
cs.eventsV1beta1 = eventsv1beta1.New(c)
|
||||||
|
@ -64,8 +64,8 @@ import (
|
|||||||
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"
|
||||||
fakecorev1 "k8s.io/client-go/kubernetes/typed/core/v1/fake"
|
fakecorev1 "k8s.io/client-go/kubernetes/typed/core/v1/fake"
|
||||||
discoveryv1alpha1 "k8s.io/client-go/kubernetes/typed/discovery/v1alpha1"
|
discoveryv1 "k8s.io/client-go/kubernetes/typed/discovery/v1"
|
||||||
fakediscoveryv1alpha1 "k8s.io/client-go/kubernetes/typed/discovery/v1alpha1/fake"
|
fakediscoveryv1 "k8s.io/client-go/kubernetes/typed/discovery/v1/fake"
|
||||||
discoveryv1beta1 "k8s.io/client-go/kubernetes/typed/discovery/v1beta1"
|
discoveryv1beta1 "k8s.io/client-go/kubernetes/typed/discovery/v1beta1"
|
||||||
fakediscoveryv1beta1 "k8s.io/client-go/kubernetes/typed/discovery/v1beta1/fake"
|
fakediscoveryv1beta1 "k8s.io/client-go/kubernetes/typed/discovery/v1beta1/fake"
|
||||||
eventsv1 "k8s.io/client-go/kubernetes/typed/events/v1"
|
eventsv1 "k8s.io/client-go/kubernetes/typed/events/v1"
|
||||||
@ -258,9 +258,9 @@ func (c *Clientset) CoreV1() corev1.CoreV1Interface {
|
|||||||
return &fakecorev1.FakeCoreV1{Fake: &c.Fake}
|
return &fakecorev1.FakeCoreV1{Fake: &c.Fake}
|
||||||
}
|
}
|
||||||
|
|
||||||
// DiscoveryV1alpha1 retrieves the DiscoveryV1alpha1Client
|
// DiscoveryV1 retrieves the DiscoveryV1Client
|
||||||
func (c *Clientset) DiscoveryV1alpha1() discoveryv1alpha1.DiscoveryV1alpha1Interface {
|
func (c *Clientset) DiscoveryV1() discoveryv1.DiscoveryV1Interface {
|
||||||
return &fakediscoveryv1alpha1.FakeDiscoveryV1alpha1{Fake: &c.Fake}
|
return &fakediscoveryv1.FakeDiscoveryV1{Fake: &c.Fake}
|
||||||
}
|
}
|
||||||
|
|
||||||
// DiscoveryV1beta1 retrieves the DiscoveryV1beta1Client
|
// DiscoveryV1beta1 retrieves the DiscoveryV1beta1Client
|
||||||
|
@ -39,7 +39,7 @@ import (
|
|||||||
coordinationv1 "k8s.io/api/coordination/v1"
|
coordinationv1 "k8s.io/api/coordination/v1"
|
||||||
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
||||||
corev1 "k8s.io/api/core/v1"
|
corev1 "k8s.io/api/core/v1"
|
||||||
discoveryv1alpha1 "k8s.io/api/discovery/v1alpha1"
|
discoveryv1 "k8s.io/api/discovery/v1"
|
||||||
discoveryv1beta1 "k8s.io/api/discovery/v1beta1"
|
discoveryv1beta1 "k8s.io/api/discovery/v1beta1"
|
||||||
eventsv1 "k8s.io/api/events/v1"
|
eventsv1 "k8s.io/api/events/v1"
|
||||||
eventsv1beta1 "k8s.io/api/events/v1beta1"
|
eventsv1beta1 "k8s.io/api/events/v1beta1"
|
||||||
@ -92,7 +92,7 @@ var localSchemeBuilder = runtime.SchemeBuilder{
|
|||||||
coordinationv1beta1.AddToScheme,
|
coordinationv1beta1.AddToScheme,
|
||||||
coordinationv1.AddToScheme,
|
coordinationv1.AddToScheme,
|
||||||
corev1.AddToScheme,
|
corev1.AddToScheme,
|
||||||
discoveryv1alpha1.AddToScheme,
|
discoveryv1.AddToScheme,
|
||||||
discoveryv1beta1.AddToScheme,
|
discoveryv1beta1.AddToScheme,
|
||||||
eventsv1.AddToScheme,
|
eventsv1.AddToScheme,
|
||||||
eventsv1beta1.AddToScheme,
|
eventsv1beta1.AddToScheme,
|
||||||
|
@ -39,7 +39,7 @@ import (
|
|||||||
coordinationv1 "k8s.io/api/coordination/v1"
|
coordinationv1 "k8s.io/api/coordination/v1"
|
||||||
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
||||||
corev1 "k8s.io/api/core/v1"
|
corev1 "k8s.io/api/core/v1"
|
||||||
discoveryv1alpha1 "k8s.io/api/discovery/v1alpha1"
|
discoveryv1 "k8s.io/api/discovery/v1"
|
||||||
discoveryv1beta1 "k8s.io/api/discovery/v1beta1"
|
discoveryv1beta1 "k8s.io/api/discovery/v1beta1"
|
||||||
eventsv1 "k8s.io/api/events/v1"
|
eventsv1 "k8s.io/api/events/v1"
|
||||||
eventsv1beta1 "k8s.io/api/events/v1beta1"
|
eventsv1beta1 "k8s.io/api/events/v1beta1"
|
||||||
@ -92,7 +92,7 @@ var localSchemeBuilder = runtime.SchemeBuilder{
|
|||||||
coordinationv1beta1.AddToScheme,
|
coordinationv1beta1.AddToScheme,
|
||||||
coordinationv1.AddToScheme,
|
coordinationv1.AddToScheme,
|
||||||
corev1.AddToScheme,
|
corev1.AddToScheme,
|
||||||
discoveryv1alpha1.AddToScheme,
|
discoveryv1.AddToScheme,
|
||||||
discoveryv1beta1.AddToScheme,
|
discoveryv1beta1.AddToScheme,
|
||||||
eventsv1.AddToScheme,
|
eventsv1.AddToScheme,
|
||||||
eventsv1beta1.AddToScheme,
|
eventsv1beta1.AddToScheme,
|
||||||
|
@ -16,30 +16,30 @@ limitations under the License.
|
|||||||
|
|
||||||
// Code generated by client-gen. DO NOT EDIT.
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
package v1alpha1
|
package v1
|
||||||
|
|
||||||
import (
|
import (
|
||||||
v1alpha1 "k8s.io/api/discovery/v1alpha1"
|
v1 "k8s.io/api/discovery/v1"
|
||||||
"k8s.io/client-go/kubernetes/scheme"
|
"k8s.io/client-go/kubernetes/scheme"
|
||||||
rest "k8s.io/client-go/rest"
|
rest "k8s.io/client-go/rest"
|
||||||
)
|
)
|
||||||
|
|
||||||
type DiscoveryV1alpha1Interface interface {
|
type DiscoveryV1Interface interface {
|
||||||
RESTClient() rest.Interface
|
RESTClient() rest.Interface
|
||||||
EndpointSlicesGetter
|
EndpointSlicesGetter
|
||||||
}
|
}
|
||||||
|
|
||||||
// DiscoveryV1alpha1Client is used to interact with features provided by the discovery.k8s.io group.
|
// DiscoveryV1Client is used to interact with features provided by the discovery.k8s.io group.
|
||||||
type DiscoveryV1alpha1Client struct {
|
type DiscoveryV1Client struct {
|
||||||
restClient rest.Interface
|
restClient rest.Interface
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *DiscoveryV1alpha1Client) EndpointSlices(namespace string) EndpointSliceInterface {
|
func (c *DiscoveryV1Client) EndpointSlices(namespace string) EndpointSliceInterface {
|
||||||
return newEndpointSlices(c, namespace)
|
return newEndpointSlices(c, namespace)
|
||||||
}
|
}
|
||||||
|
|
||||||
// NewForConfig creates a new DiscoveryV1alpha1Client for the given config.
|
// NewForConfig creates a new DiscoveryV1Client for the given config.
|
||||||
func NewForConfig(c *rest.Config) (*DiscoveryV1alpha1Client, error) {
|
func NewForConfig(c *rest.Config) (*DiscoveryV1Client, error) {
|
||||||
config := *c
|
config := *c
|
||||||
if err := setConfigDefaults(&config); err != nil {
|
if err := setConfigDefaults(&config); err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
@ -48,12 +48,12 @@ func NewForConfig(c *rest.Config) (*DiscoveryV1alpha1Client, error) {
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
return &DiscoveryV1alpha1Client{client}, nil
|
return &DiscoveryV1Client{client}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// NewForConfigOrDie creates a new DiscoveryV1alpha1Client for the given config and
|
// NewForConfigOrDie creates a new DiscoveryV1Client 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) *DiscoveryV1alpha1Client {
|
func NewForConfigOrDie(c *rest.Config) *DiscoveryV1Client {
|
||||||
client, err := NewForConfig(c)
|
client, err := NewForConfig(c)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
panic(err)
|
panic(err)
|
||||||
@ -61,13 +61,13 @@ func NewForConfigOrDie(c *rest.Config) *DiscoveryV1alpha1Client {
|
|||||||
return client
|
return client
|
||||||
}
|
}
|
||||||
|
|
||||||
// New creates a new DiscoveryV1alpha1Client for the given RESTClient.
|
// New creates a new DiscoveryV1Client for the given RESTClient.
|
||||||
func New(c rest.Interface) *DiscoveryV1alpha1Client {
|
func New(c rest.Interface) *DiscoveryV1Client {
|
||||||
return &DiscoveryV1alpha1Client{c}
|
return &DiscoveryV1Client{c}
|
||||||
}
|
}
|
||||||
|
|
||||||
func setConfigDefaults(config *rest.Config) error {
|
func setConfigDefaults(config *rest.Config) error {
|
||||||
gv := v1alpha1.SchemeGroupVersion
|
gv := v1.SchemeGroupVersion
|
||||||
config.GroupVersion = &gv
|
config.GroupVersion = &gv
|
||||||
config.APIPath = "/apis"
|
config.APIPath = "/apis"
|
||||||
config.NegotiatedSerializer = scheme.Codecs.WithoutConversion()
|
config.NegotiatedSerializer = scheme.Codecs.WithoutConversion()
|
||||||
@ -81,7 +81,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 *DiscoveryV1alpha1Client) RESTClient() rest.Interface {
|
func (c *DiscoveryV1Client) 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 v1
|
@ -16,14 +16,14 @@ limitations under the License.
|
|||||||
|
|
||||||
// Code generated by client-gen. DO NOT EDIT.
|
// Code generated by client-gen. DO NOT EDIT.
|
||||||
|
|
||||||
package v1alpha1
|
package v1
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
v1alpha1 "k8s.io/api/discovery/v1alpha1"
|
v1 "k8s.io/api/discovery/v1"
|
||||||
v1 "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"
|
||||||
watch "k8s.io/apimachinery/pkg/watch"
|
watch "k8s.io/apimachinery/pkg/watch"
|
||||||
scheme "k8s.io/client-go/kubernetes/scheme"
|
scheme "k8s.io/client-go/kubernetes/scheme"
|
||||||
@ -38,14 +38,14 @@ type EndpointSlicesGetter interface {
|
|||||||
|
|
||||||
// EndpointSliceInterface has methods to work with EndpointSlice resources.
|
// EndpointSliceInterface has methods to work with EndpointSlice resources.
|
||||||
type EndpointSliceInterface interface {
|
type EndpointSliceInterface interface {
|
||||||
Create(ctx context.Context, endpointSlice *v1alpha1.EndpointSlice, opts v1.CreateOptions) (*v1alpha1.EndpointSlice, error)
|
Create(ctx context.Context, endpointSlice *v1.EndpointSlice, opts metav1.CreateOptions) (*v1.EndpointSlice, error)
|
||||||
Update(ctx context.Context, endpointSlice *v1alpha1.EndpointSlice, opts v1.UpdateOptions) (*v1alpha1.EndpointSlice, error)
|
Update(ctx context.Context, endpointSlice *v1.EndpointSlice, opts metav1.UpdateOptions) (*v1.EndpointSlice, error)
|
||||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error
|
||||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error
|
||||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.EndpointSlice, error)
|
Get(ctx context.Context, name string, opts metav1.GetOptions) (*v1.EndpointSlice, error)
|
||||||
List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.EndpointSliceList, error)
|
List(ctx context.Context, opts metav1.ListOptions) (*v1.EndpointSliceList, error)
|
||||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error)
|
||||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.EndpointSlice, err error)
|
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (result *v1.EndpointSlice, err error)
|
||||||
EndpointSliceExpansion
|
EndpointSliceExpansion
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -56,7 +56,7 @@ type endpointSlices struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// newEndpointSlices returns a EndpointSlices
|
// newEndpointSlices returns a EndpointSlices
|
||||||
func newEndpointSlices(c *DiscoveryV1alpha1Client, namespace string) *endpointSlices {
|
func newEndpointSlices(c *DiscoveryV1Client, namespace string) *endpointSlices {
|
||||||
return &endpointSlices{
|
return &endpointSlices{
|
||||||
client: c.RESTClient(),
|
client: c.RESTClient(),
|
||||||
ns: namespace,
|
ns: namespace,
|
||||||
@ -64,8 +64,8 @@ func newEndpointSlices(c *DiscoveryV1alpha1Client, namespace string) *endpointSl
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Get takes name of the endpointSlice, and returns the corresponding endpointSlice object, and an error if there is any.
|
// Get takes name of the endpointSlice, and returns the corresponding endpointSlice object, and an error if there is any.
|
||||||
func (c *endpointSlices) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.EndpointSlice, err error) {
|
func (c *endpointSlices) Get(ctx context.Context, name string, options metav1.GetOptions) (result *v1.EndpointSlice, err error) {
|
||||||
result = &v1alpha1.EndpointSlice{}
|
result = &v1.EndpointSlice{}
|
||||||
err = c.client.Get().
|
err = c.client.Get().
|
||||||
Namespace(c.ns).
|
Namespace(c.ns).
|
||||||
Resource("endpointslices").
|
Resource("endpointslices").
|
||||||
@ -77,12 +77,12 @@ func (c *endpointSlices) Get(ctx context.Context, name string, options v1.GetOpt
|
|||||||
}
|
}
|
||||||
|
|
||||||
// List takes label and field selectors, and returns the list of EndpointSlices that match those selectors.
|
// List takes label and field selectors, and returns the list of EndpointSlices that match those selectors.
|
||||||
func (c *endpointSlices) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.EndpointSliceList, err error) {
|
func (c *endpointSlices) List(ctx context.Context, opts metav1.ListOptions) (result *v1.EndpointSliceList, err error) {
|
||||||
var timeout time.Duration
|
var timeout time.Duration
|
||||||
if opts.TimeoutSeconds != nil {
|
if opts.TimeoutSeconds != nil {
|
||||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||||
}
|
}
|
||||||
result = &v1alpha1.EndpointSliceList{}
|
result = &v1.EndpointSliceList{}
|
||||||
err = c.client.Get().
|
err = c.client.Get().
|
||||||
Namespace(c.ns).
|
Namespace(c.ns).
|
||||||
Resource("endpointslices").
|
Resource("endpointslices").
|
||||||
@ -94,7 +94,7 @@ func (c *endpointSlices) List(ctx context.Context, opts v1.ListOptions) (result
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Watch returns a watch.Interface that watches the requested endpointSlices.
|
// Watch returns a watch.Interface that watches the requested endpointSlices.
|
||||||
func (c *endpointSlices) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
func (c *endpointSlices) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) {
|
||||||
var timeout time.Duration
|
var timeout time.Duration
|
||||||
if opts.TimeoutSeconds != nil {
|
if opts.TimeoutSeconds != nil {
|
||||||
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
|
||||||
@ -109,8 +109,8 @@ func (c *endpointSlices) Watch(ctx context.Context, opts v1.ListOptions) (watch.
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Create takes the representation of a endpointSlice and creates it. Returns the server's representation of the endpointSlice, and an error, if there is any.
|
// Create takes the representation of a endpointSlice and creates it. Returns the server's representation of the endpointSlice, and an error, if there is any.
|
||||||
func (c *endpointSlices) Create(ctx context.Context, endpointSlice *v1alpha1.EndpointSlice, opts v1.CreateOptions) (result *v1alpha1.EndpointSlice, err error) {
|
func (c *endpointSlices) Create(ctx context.Context, endpointSlice *v1.EndpointSlice, opts metav1.CreateOptions) (result *v1.EndpointSlice, err error) {
|
||||||
result = &v1alpha1.EndpointSlice{}
|
result = &v1.EndpointSlice{}
|
||||||
err = c.client.Post().
|
err = c.client.Post().
|
||||||
Namespace(c.ns).
|
Namespace(c.ns).
|
||||||
Resource("endpointslices").
|
Resource("endpointslices").
|
||||||
@ -122,8 +122,8 @@ func (c *endpointSlices) Create(ctx context.Context, endpointSlice *v1alpha1.End
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Update takes the representation of a endpointSlice and updates it. Returns the server's representation of the endpointSlice, and an error, if there is any.
|
// Update takes the representation of a endpointSlice and updates it. Returns the server's representation of the endpointSlice, and an error, if there is any.
|
||||||
func (c *endpointSlices) Update(ctx context.Context, endpointSlice *v1alpha1.EndpointSlice, opts v1.UpdateOptions) (result *v1alpha1.EndpointSlice, err error) {
|
func (c *endpointSlices) Update(ctx context.Context, endpointSlice *v1.EndpointSlice, opts metav1.UpdateOptions) (result *v1.EndpointSlice, err error) {
|
||||||
result = &v1alpha1.EndpointSlice{}
|
result = &v1.EndpointSlice{}
|
||||||
err = c.client.Put().
|
err = c.client.Put().
|
||||||
Namespace(c.ns).
|
Namespace(c.ns).
|
||||||
Resource("endpointslices").
|
Resource("endpointslices").
|
||||||
@ -136,7 +136,7 @@ func (c *endpointSlices) Update(ctx context.Context, endpointSlice *v1alpha1.End
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Delete takes name of the endpointSlice and deletes it. Returns an error if one occurs.
|
// Delete takes name of the endpointSlice and deletes it. Returns an error if one occurs.
|
||||||
func (c *endpointSlices) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
func (c *endpointSlices) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error {
|
||||||
return c.client.Delete().
|
return c.client.Delete().
|
||||||
Namespace(c.ns).
|
Namespace(c.ns).
|
||||||
Resource("endpointslices").
|
Resource("endpointslices").
|
||||||
@ -147,7 +147,7 @@ func (c *endpointSlices) Delete(ctx context.Context, name string, opts v1.Delete
|
|||||||
}
|
}
|
||||||
|
|
||||||
// DeleteCollection deletes a collection of objects.
|
// DeleteCollection deletes a collection of objects.
|
||||||
func (c *endpointSlices) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
func (c *endpointSlices) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error {
|
||||||
var timeout time.Duration
|
var timeout time.Duration
|
||||||
if listOpts.TimeoutSeconds != nil {
|
if listOpts.TimeoutSeconds != nil {
|
||||||
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
|
timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second
|
||||||
@ -163,8 +163,8 @@ func (c *endpointSlices) DeleteCollection(ctx context.Context, opts v1.DeleteOpt
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Patch applies the patch and returns the patched endpointSlice.
|
// Patch applies the patch and returns the patched endpointSlice.
|
||||||
func (c *endpointSlices) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.EndpointSlice, err error) {
|
func (c *endpointSlices) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (result *v1.EndpointSlice, err error) {
|
||||||
result = &v1alpha1.EndpointSlice{}
|
result = &v1.EndpointSlice{}
|
||||||
err = c.client.Patch(pt).
|
err = c.client.Patch(pt).
|
||||||
Namespace(c.ns).
|
Namespace(c.ns).
|
||||||
Resource("endpointslices").
|
Resource("endpointslices").
|
@ -19,22 +19,22 @@ limitations under the License.
|
|||||||
package fake
|
package fake
|
||||||
|
|
||||||
import (
|
import (
|
||||||
v1alpha1 "k8s.io/client-go/kubernetes/typed/discovery/v1alpha1"
|
v1 "k8s.io/client-go/kubernetes/typed/discovery/v1"
|
||||||
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 FakeDiscoveryV1alpha1 struct {
|
type FakeDiscoveryV1 struct {
|
||||||
*testing.Fake
|
*testing.Fake
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *FakeDiscoveryV1alpha1) EndpointSlices(namespace string) v1alpha1.EndpointSliceInterface {
|
func (c *FakeDiscoveryV1) EndpointSlices(namespace string) v1.EndpointSliceInterface {
|
||||||
return &FakeEndpointSlices{c, namespace}
|
return &FakeEndpointSlices{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 *FakeDiscoveryV1alpha1) RESTClient() rest.Interface {
|
func (c *FakeDiscoveryV1) RESTClient() rest.Interface {
|
||||||
var ret *rest.RESTClient
|
var ret *rest.RESTClient
|
||||||
return ret
|
return ret
|
||||||
}
|
}
|
@ -21,7 +21,7 @@ package fake
|
|||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
v1alpha1 "k8s.io/api/discovery/v1alpha1"
|
discoveryv1 "k8s.io/api/discovery/v1"
|
||||||
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"
|
||||||
schema "k8s.io/apimachinery/pkg/runtime/schema"
|
schema "k8s.io/apimachinery/pkg/runtime/schema"
|
||||||
@ -32,29 +32,29 @@ import (
|
|||||||
|
|
||||||
// FakeEndpointSlices implements EndpointSliceInterface
|
// FakeEndpointSlices implements EndpointSliceInterface
|
||||||
type FakeEndpointSlices struct {
|
type FakeEndpointSlices struct {
|
||||||
Fake *FakeDiscoveryV1alpha1
|
Fake *FakeDiscoveryV1
|
||||||
ns string
|
ns string
|
||||||
}
|
}
|
||||||
|
|
||||||
var endpointslicesResource = schema.GroupVersionResource{Group: "discovery.k8s.io", Version: "v1alpha1", Resource: "endpointslices"}
|
var endpointslicesResource = schema.GroupVersionResource{Group: "discovery.k8s.io", Version: "v1", Resource: "endpointslices"}
|
||||||
|
|
||||||
var endpointslicesKind = schema.GroupVersionKind{Group: "discovery.k8s.io", Version: "v1alpha1", Kind: "EndpointSlice"}
|
var endpointslicesKind = schema.GroupVersionKind{Group: "discovery.k8s.io", Version: "v1", Kind: "EndpointSlice"}
|
||||||
|
|
||||||
// Get takes name of the endpointSlice, and returns the corresponding endpointSlice object, and an error if there is any.
|
// Get takes name of the endpointSlice, and returns the corresponding endpointSlice object, and an error if there is any.
|
||||||
func (c *FakeEndpointSlices) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.EndpointSlice, err error) {
|
func (c *FakeEndpointSlices) Get(ctx context.Context, name string, options v1.GetOptions) (result *discoveryv1.EndpointSlice, err error) {
|
||||||
obj, err := c.Fake.
|
obj, err := c.Fake.
|
||||||
Invokes(testing.NewGetAction(endpointslicesResource, c.ns, name), &v1alpha1.EndpointSlice{})
|
Invokes(testing.NewGetAction(endpointslicesResource, c.ns, name), &discoveryv1.EndpointSlice{})
|
||||||
|
|
||||||
if obj == nil {
|
if obj == nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
return obj.(*v1alpha1.EndpointSlice), err
|
return obj.(*discoveryv1.EndpointSlice), err
|
||||||
}
|
}
|
||||||
|
|
||||||
// List takes label and field selectors, and returns the list of EndpointSlices that match those selectors.
|
// List takes label and field selectors, and returns the list of EndpointSlices that match those selectors.
|
||||||
func (c *FakeEndpointSlices) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.EndpointSliceList, err error) {
|
func (c *FakeEndpointSlices) List(ctx context.Context, opts v1.ListOptions) (result *discoveryv1.EndpointSliceList, err error) {
|
||||||
obj, err := c.Fake.
|
obj, err := c.Fake.
|
||||||
Invokes(testing.NewListAction(endpointslicesResource, endpointslicesKind, c.ns, opts), &v1alpha1.EndpointSliceList{})
|
Invokes(testing.NewListAction(endpointslicesResource, endpointslicesKind, c.ns, opts), &discoveryv1.EndpointSliceList{})
|
||||||
|
|
||||||
if obj == nil {
|
if obj == nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
@ -64,8 +64,8 @@ func (c *FakeEndpointSlices) List(ctx context.Context, opts v1.ListOptions) (res
|
|||||||
if label == nil {
|
if label == nil {
|
||||||
label = labels.Everything()
|
label = labels.Everything()
|
||||||
}
|
}
|
||||||
list := &v1alpha1.EndpointSliceList{ListMeta: obj.(*v1alpha1.EndpointSliceList).ListMeta}
|
list := &discoveryv1.EndpointSliceList{ListMeta: obj.(*discoveryv1.EndpointSliceList).ListMeta}
|
||||||
for _, item := range obj.(*v1alpha1.EndpointSliceList).Items {
|
for _, item := range obj.(*discoveryv1.EndpointSliceList).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)
|
||||||
}
|
}
|
||||||
@ -81,31 +81,31 @@ func (c *FakeEndpointSlices) Watch(ctx context.Context, opts v1.ListOptions) (wa
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Create takes the representation of a endpointSlice and creates it. Returns the server's representation of the endpointSlice, and an error, if there is any.
|
// Create takes the representation of a endpointSlice and creates it. Returns the server's representation of the endpointSlice, and an error, if there is any.
|
||||||
func (c *FakeEndpointSlices) Create(ctx context.Context, endpointSlice *v1alpha1.EndpointSlice, opts v1.CreateOptions) (result *v1alpha1.EndpointSlice, err error) {
|
func (c *FakeEndpointSlices) Create(ctx context.Context, endpointSlice *discoveryv1.EndpointSlice, opts v1.CreateOptions) (result *discoveryv1.EndpointSlice, err error) {
|
||||||
obj, err := c.Fake.
|
obj, err := c.Fake.
|
||||||
Invokes(testing.NewCreateAction(endpointslicesResource, c.ns, endpointSlice), &v1alpha1.EndpointSlice{})
|
Invokes(testing.NewCreateAction(endpointslicesResource, c.ns, endpointSlice), &discoveryv1.EndpointSlice{})
|
||||||
|
|
||||||
if obj == nil {
|
if obj == nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
return obj.(*v1alpha1.EndpointSlice), err
|
return obj.(*discoveryv1.EndpointSlice), err
|
||||||
}
|
}
|
||||||
|
|
||||||
// Update takes the representation of a endpointSlice and updates it. Returns the server's representation of the endpointSlice, and an error, if there is any.
|
// Update takes the representation of a endpointSlice and updates it. Returns the server's representation of the endpointSlice, and an error, if there is any.
|
||||||
func (c *FakeEndpointSlices) Update(ctx context.Context, endpointSlice *v1alpha1.EndpointSlice, opts v1.UpdateOptions) (result *v1alpha1.EndpointSlice, err error) {
|
func (c *FakeEndpointSlices) Update(ctx context.Context, endpointSlice *discoveryv1.EndpointSlice, opts v1.UpdateOptions) (result *discoveryv1.EndpointSlice, err error) {
|
||||||
obj, err := c.Fake.
|
obj, err := c.Fake.
|
||||||
Invokes(testing.NewUpdateAction(endpointslicesResource, c.ns, endpointSlice), &v1alpha1.EndpointSlice{})
|
Invokes(testing.NewUpdateAction(endpointslicesResource, c.ns, endpointSlice), &discoveryv1.EndpointSlice{})
|
||||||
|
|
||||||
if obj == nil {
|
if obj == nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
return obj.(*v1alpha1.EndpointSlice), err
|
return obj.(*discoveryv1.EndpointSlice), err
|
||||||
}
|
}
|
||||||
|
|
||||||
// Delete takes name of the endpointSlice and deletes it. Returns an error if one occurs.
|
// Delete takes name of the endpointSlice and deletes it. Returns an error if one occurs.
|
||||||
func (c *FakeEndpointSlices) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
func (c *FakeEndpointSlices) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
|
||||||
_, err := c.Fake.
|
_, err := c.Fake.
|
||||||
Invokes(testing.NewDeleteAction(endpointslicesResource, c.ns, name), &v1alpha1.EndpointSlice{})
|
Invokes(testing.NewDeleteAction(endpointslicesResource, c.ns, name), &discoveryv1.EndpointSlice{})
|
||||||
|
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
@ -114,17 +114,17 @@ func (c *FakeEndpointSlices) Delete(ctx context.Context, name string, opts v1.De
|
|||||||
func (c *FakeEndpointSlices) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
func (c *FakeEndpointSlices) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
|
||||||
action := testing.NewDeleteCollectionAction(endpointslicesResource, c.ns, listOpts)
|
action := testing.NewDeleteCollectionAction(endpointslicesResource, c.ns, listOpts)
|
||||||
|
|
||||||
_, err := c.Fake.Invokes(action, &v1alpha1.EndpointSliceList{})
|
_, err := c.Fake.Invokes(action, &discoveryv1.EndpointSliceList{})
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
// Patch applies the patch and returns the patched endpointSlice.
|
// Patch applies the patch and returns the patched endpointSlice.
|
||||||
func (c *FakeEndpointSlices) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.EndpointSlice, err error) {
|
func (c *FakeEndpointSlices) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *discoveryv1.EndpointSlice, err error) {
|
||||||
obj, err := c.Fake.
|
obj, err := c.Fake.
|
||||||
Invokes(testing.NewPatchSubresourceAction(endpointslicesResource, c.ns, name, pt, data, subresources...), &v1alpha1.EndpointSlice{})
|
Invokes(testing.NewPatchSubresourceAction(endpointslicesResource, c.ns, name, pt, data, subresources...), &discoveryv1.EndpointSlice{})
|
||||||
|
|
||||||
if obj == nil {
|
if obj == nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
return obj.(*v1alpha1.EndpointSlice), err
|
return obj.(*discoveryv1.EndpointSlice), 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 v1
|
||||||
|
|
||||||
type EndpointSliceExpansion interface{}
|
type EndpointSliceExpansion interface{}
|
@ -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 v1
|
||||||
|
|
||||||
import (
|
import (
|
||||||
v1alpha1 "k8s.io/api/discovery/v1alpha1"
|
v1 "k8s.io/api/discovery/v1"
|
||||||
"k8s.io/apimachinery/pkg/api/errors"
|
"k8s.io/apimachinery/pkg/api/errors"
|
||||||
"k8s.io/apimachinery/pkg/labels"
|
"k8s.io/apimachinery/pkg/labels"
|
||||||
"k8s.io/client-go/tools/cache"
|
"k8s.io/client-go/tools/cache"
|
||||||
@ -30,7 +30,7 @@ import (
|
|||||||
type EndpointSliceLister interface {
|
type EndpointSliceLister interface {
|
||||||
// List lists all EndpointSlices in the indexer.
|
// List lists all EndpointSlices 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 []*v1alpha1.EndpointSlice, err error)
|
List(selector labels.Selector) (ret []*v1.EndpointSlice, err error)
|
||||||
// EndpointSlices returns an object that can list and get EndpointSlices.
|
// EndpointSlices returns an object that can list and get EndpointSlices.
|
||||||
EndpointSlices(namespace string) EndpointSliceNamespaceLister
|
EndpointSlices(namespace string) EndpointSliceNamespaceLister
|
||||||
EndpointSliceListerExpansion
|
EndpointSliceListerExpansion
|
||||||
@ -47,9 +47,9 @@ func NewEndpointSliceLister(indexer cache.Indexer) EndpointSliceLister {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// List lists all EndpointSlices in the indexer.
|
// List lists all EndpointSlices in the indexer.
|
||||||
func (s *endpointSliceLister) List(selector labels.Selector) (ret []*v1alpha1.EndpointSlice, err error) {
|
func (s *endpointSliceLister) List(selector labels.Selector) (ret []*v1.EndpointSlice, err error) {
|
||||||
err = cache.ListAll(s.indexer, selector, func(m interface{}) {
|
err = cache.ListAll(s.indexer, selector, func(m interface{}) {
|
||||||
ret = append(ret, m.(*v1alpha1.EndpointSlice))
|
ret = append(ret, m.(*v1.EndpointSlice))
|
||||||
})
|
})
|
||||||
return ret, err
|
return ret, err
|
||||||
}
|
}
|
||||||
@ -64,10 +64,10 @@ func (s *endpointSliceLister) EndpointSlices(namespace string) EndpointSliceName
|
|||||||
type EndpointSliceNamespaceLister interface {
|
type EndpointSliceNamespaceLister interface {
|
||||||
// List lists all EndpointSlices in the indexer for a given namespace.
|
// List lists all EndpointSlices 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 []*v1alpha1.EndpointSlice, err error)
|
List(selector labels.Selector) (ret []*v1.EndpointSlice, err error)
|
||||||
// Get retrieves the EndpointSlice from the indexer for a given namespace and name.
|
// Get retrieves the EndpointSlice 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) (*v1alpha1.EndpointSlice, error)
|
Get(name string) (*v1.EndpointSlice, error)
|
||||||
EndpointSliceNamespaceListerExpansion
|
EndpointSliceNamespaceListerExpansion
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -79,21 +79,21 @@ type endpointSliceNamespaceLister struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// List lists all EndpointSlices in the indexer for a given namespace.
|
// List lists all EndpointSlices in the indexer for a given namespace.
|
||||||
func (s endpointSliceNamespaceLister) List(selector labels.Selector) (ret []*v1alpha1.EndpointSlice, err error) {
|
func (s endpointSliceNamespaceLister) List(selector labels.Selector) (ret []*v1.EndpointSlice, err error) {
|
||||||
err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) {
|
err = cache.ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) {
|
||||||
ret = append(ret, m.(*v1alpha1.EndpointSlice))
|
ret = append(ret, m.(*v1.EndpointSlice))
|
||||||
})
|
})
|
||||||
return ret, err
|
return ret, err
|
||||||
}
|
}
|
||||||
|
|
||||||
// Get retrieves the EndpointSlice from the indexer for a given namespace and name.
|
// Get retrieves the EndpointSlice from the indexer for a given namespace and name.
|
||||||
func (s endpointSliceNamespaceLister) Get(name string) (*v1alpha1.EndpointSlice, error) {
|
func (s endpointSliceNamespaceLister) Get(name string) (*v1.EndpointSlice, error) {
|
||||||
obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name)
|
obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
if !exists {
|
if !exists {
|
||||||
return nil, errors.NewNotFound(v1alpha1.Resource("endpointslice"), name)
|
return nil, errors.NewNotFound(v1.Resource("endpointslice"), name)
|
||||||
}
|
}
|
||||||
return obj.(*v1alpha1.EndpointSlice), nil
|
return obj.(*v1.EndpointSlice), nil
|
||||||
}
|
}
|
@ -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 v1
|
||||||
|
|
||||||
// EndpointSliceListerExpansion allows custom methods to be added to
|
// EndpointSliceListerExpansion allows custom methods to be added to
|
||||||
// EndpointSliceLister.
|
// EndpointSliceLister.
|
Loading…
Reference in New Issue
Block a user