diff --git a/go.mod b/go.mod index 9e27ac947a..105daeef77 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,7 @@ go 1.16 require ( github.com/gogo/protobuf v1.3.2 github.com/stretchr/testify v1.7.0 - k8s.io/apimachinery v0.0.0-20220330050810-6550efdb7444 + k8s.io/apimachinery v0.0.0-20220331225401-97e5df2d0258 ) -replace k8s.io/apimachinery => k8s.io/apimachinery v0.0.0-20220330050810-6550efdb7444 +replace k8s.io/apimachinery => k8s.io/apimachinery v0.0.0-20220331225401-97e5df2d0258 diff --git a/go.sum b/go.sum index 0af15436bc..626883b1f4 100644 --- a/go.sum +++ b/go.sum @@ -221,8 +221,8 @@ gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b h1:h8qDotaEPuJATrMmW04NCwg7v gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -k8s.io/apimachinery v0.0.0-20220330050810-6550efdb7444 h1:whQmS3GtF822OUer+LPJnMFKn6kPfuJOCM/3xUuATIY= -k8s.io/apimachinery v0.0.0-20220330050810-6550efdb7444/go.mod h1:82Bi4sCzVBdpYjyI4jY6aHX+YCUchUIrZrXKedjd2UM= +k8s.io/apimachinery v0.0.0-20220331225401-97e5df2d0258 h1:9TgQL4ndOPmFSnQoTVN/ur/sU3RXMxaSmhMUBbflUTU= +k8s.io/apimachinery v0.0.0-20220331225401-97e5df2d0258/go.mod h1:82Bi4sCzVBdpYjyI4jY6aHX+YCUchUIrZrXKedjd2UM= k8s.io/gengo v0.0.0-20210813121822-485abfe95c7c/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E= k8s.io/klog/v2 v2.0.0/go.mod h1:PBfzABfn139FHAV07az/IF9Wp1bkk3vpT2XSJ76fSDE= k8s.io/klog/v2 v2.2.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y= diff --git a/networking/v1alpha1/doc.go b/networking/v1alpha1/doc.go deleted file mode 100644 index 3827b0418f..0000000000 --- a/networking/v1alpha1/doc.go +++ /dev/null @@ -1,23 +0,0 @@ -/* -Copyright 2022 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// +k8s:deepcopy-gen=package -// +k8s:protobuf-gen=package -// +k8s:openapi-gen=true -// +k8s:prerelease-lifecycle-gen=true -// +groupName=networking.k8s.io - -package v1alpha1 // import "k8s.io/api/networking/v1alpha1" diff --git a/networking/v1alpha1/generated.pb.go b/networking/v1alpha1/generated.pb.go deleted file mode 100644 index 1f9d64f5a9..0000000000 --- a/networking/v1alpha1/generated.pb.go +++ /dev/null @@ -1,1082 +0,0 @@ -/* -Copyright The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: k8s.io/kubernetes/vendor/k8s.io/api/networking/v1alpha1/generated.proto - -package v1alpha1 - -import ( - fmt "fmt" - - io "io" - - proto "github.com/gogo/protobuf/proto" - v11 "k8s.io/api/core/v1" - - math "math" - math_bits "math/bits" - reflect "reflect" - strings "strings" -) - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package - -func (m *ClusterCIDRConfig) Reset() { *m = ClusterCIDRConfig{} } -func (*ClusterCIDRConfig) ProtoMessage() {} -func (*ClusterCIDRConfig) Descriptor() ([]byte, []int) { - return fileDescriptor_c1b7ac8d7d97acec, []int{0} -} -func (m *ClusterCIDRConfig) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ClusterCIDRConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ClusterCIDRConfig) XXX_Merge(src proto.Message) { - xxx_messageInfo_ClusterCIDRConfig.Merge(m, src) -} -func (m *ClusterCIDRConfig) XXX_Size() int { - return m.Size() -} -func (m *ClusterCIDRConfig) XXX_DiscardUnknown() { - xxx_messageInfo_ClusterCIDRConfig.DiscardUnknown(m) -} - -var xxx_messageInfo_ClusterCIDRConfig proto.InternalMessageInfo - -func (m *ClusterCIDRConfigList) Reset() { *m = ClusterCIDRConfigList{} } -func (*ClusterCIDRConfigList) ProtoMessage() {} -func (*ClusterCIDRConfigList) Descriptor() ([]byte, []int) { - return fileDescriptor_c1b7ac8d7d97acec, []int{1} -} -func (m *ClusterCIDRConfigList) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ClusterCIDRConfigList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ClusterCIDRConfigList) XXX_Merge(src proto.Message) { - xxx_messageInfo_ClusterCIDRConfigList.Merge(m, src) -} -func (m *ClusterCIDRConfigList) XXX_Size() int { - return m.Size() -} -func (m *ClusterCIDRConfigList) XXX_DiscardUnknown() { - xxx_messageInfo_ClusterCIDRConfigList.DiscardUnknown(m) -} - -var xxx_messageInfo_ClusterCIDRConfigList proto.InternalMessageInfo - -func (m *ClusterCIDRConfigSpec) Reset() { *m = ClusterCIDRConfigSpec{} } -func (*ClusterCIDRConfigSpec) ProtoMessage() {} -func (*ClusterCIDRConfigSpec) Descriptor() ([]byte, []int) { - return fileDescriptor_c1b7ac8d7d97acec, []int{2} -} -func (m *ClusterCIDRConfigSpec) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ClusterCIDRConfigSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ClusterCIDRConfigSpec) XXX_Merge(src proto.Message) { - xxx_messageInfo_ClusterCIDRConfigSpec.Merge(m, src) -} -func (m *ClusterCIDRConfigSpec) XXX_Size() int { - return m.Size() -} -func (m *ClusterCIDRConfigSpec) XXX_DiscardUnknown() { - xxx_messageInfo_ClusterCIDRConfigSpec.DiscardUnknown(m) -} - -var xxx_messageInfo_ClusterCIDRConfigSpec proto.InternalMessageInfo - -func (m *ClusterCIDRConfigStatus) Reset() { *m = ClusterCIDRConfigStatus{} } -func (*ClusterCIDRConfigStatus) ProtoMessage() {} -func (*ClusterCIDRConfigStatus) Descriptor() ([]byte, []int) { - return fileDescriptor_c1b7ac8d7d97acec, []int{3} -} -func (m *ClusterCIDRConfigStatus) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *ClusterCIDRConfigStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil -} -func (m *ClusterCIDRConfigStatus) XXX_Merge(src proto.Message) { - xxx_messageInfo_ClusterCIDRConfigStatus.Merge(m, src) -} -func (m *ClusterCIDRConfigStatus) XXX_Size() int { - return m.Size() -} -func (m *ClusterCIDRConfigStatus) XXX_DiscardUnknown() { - xxx_messageInfo_ClusterCIDRConfigStatus.DiscardUnknown(m) -} - -var xxx_messageInfo_ClusterCIDRConfigStatus proto.InternalMessageInfo - -func init() { - proto.RegisterType((*ClusterCIDRConfig)(nil), "k8s.io.api.networking.v1alpha1.ClusterCIDRConfig") - proto.RegisterType((*ClusterCIDRConfigList)(nil), "k8s.io.api.networking.v1alpha1.ClusterCIDRConfigList") - proto.RegisterType((*ClusterCIDRConfigSpec)(nil), "k8s.io.api.networking.v1alpha1.ClusterCIDRConfigSpec") - proto.RegisterType((*ClusterCIDRConfigStatus)(nil), "k8s.io.api.networking.v1alpha1.ClusterCIDRConfigStatus") -} - -func init() { - proto.RegisterFile("k8s.io/kubernetes/vendor/k8s.io/api/networking/v1alpha1/generated.proto", fileDescriptor_c1b7ac8d7d97acec) -} - -var fileDescriptor_c1b7ac8d7d97acec = []byte{ - // 550 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x94, 0xcd, 0x6e, 0xd3, 0x4c, - 0x14, 0x86, 0xe3, 0xb4, 0xa9, 0xf2, 0x4d, 0xf3, 0xd1, 0x62, 0x09, 0x35, 0x64, 0xe1, 0x44, 0x59, - 0x75, 0x01, 0x33, 0xa4, 0x2a, 0x81, 0x2d, 0x4e, 0x25, 0x88, 0xc4, 0x4f, 0xe5, 0x4a, 0x45, 0x42, - 0x48, 0x30, 0x71, 0x4e, 0x9d, 0x21, 0xb1, 0xc7, 0x9a, 0x19, 0x07, 0xb1, 0xe3, 0x0a, 0x10, 0x77, - 0xc2, 0x6d, 0x64, 0x83, 0xd4, 0x65, 0x57, 0x11, 0x31, 0x37, 0x82, 0x66, 0xe2, 0x26, 0x69, 0xdd, - 0x16, 0xba, 0xf3, 0x39, 0xf3, 0xbc, 0xef, 0xf9, 0x99, 0x91, 0xd1, 0xf3, 0xe1, 0x53, 0x89, 0x19, - 0x27, 0xc3, 0xa4, 0x07, 0x22, 0x02, 0x05, 0x92, 0x8c, 0x21, 0xea, 0x73, 0x41, 0xb2, 0x03, 0x1a, - 0x33, 0x12, 0x81, 0xfa, 0xcc, 0xc5, 0x90, 0x45, 0x01, 0x19, 0xb7, 0xe8, 0x28, 0x1e, 0xd0, 0x16, - 0x09, 0x20, 0x02, 0x41, 0x15, 0xf4, 0x71, 0x2c, 0xb8, 0xe2, 0xb6, 0x33, 0xe7, 0x31, 0x8d, 0x19, - 0x5e, 0xf2, 0xf8, 0x9c, 0xaf, 0x3d, 0x0c, 0x98, 0x1a, 0x24, 0x3d, 0xec, 0xf3, 0x90, 0x04, 0x3c, - 0xe0, 0xc4, 0xc8, 0x7a, 0xc9, 0x89, 0x89, 0x4c, 0x60, 0xbe, 0xe6, 0x76, 0xb5, 0xe6, 0x4a, 0x79, - 0x9f, 0x0b, 0x20, 0xe3, 0x5c, 0xc9, 0xda, 0xfe, 0x92, 0x09, 0xa9, 0x3f, 0x60, 0x11, 0x88, 0x2f, - 0x24, 0x1e, 0x06, 0x3a, 0x21, 0x49, 0x08, 0x8a, 0x5e, 0xa5, 0x22, 0xd7, 0xa9, 0x44, 0x12, 0x29, - 0x16, 0x42, 0x4e, 0xd0, 0xfe, 0x9b, 0x40, 0xfa, 0x03, 0x08, 0xe9, 0x65, 0x5d, 0xf3, 0x47, 0x11, - 0xdd, 0xed, 0x8c, 0x12, 0xa9, 0x40, 0x74, 0xba, 0x07, 0x5e, 0x87, 0x47, 0x27, 0x2c, 0xb0, 0x3f, - 0xa2, 0xb2, 0xee, 0xac, 0x4f, 0x15, 0xad, 0x5a, 0x0d, 0x6b, 0x77, 0x73, 0xef, 0x11, 0x5e, 0xae, - 0x6e, 0x51, 0x00, 0xc7, 0xc3, 0x40, 0x27, 0x24, 0xd6, 0x34, 0x1e, 0xb7, 0xf0, 0x9b, 0xde, 0x27, - 0xf0, 0xd5, 0x2b, 0x50, 0xd4, 0xb5, 0x27, 0xd3, 0x7a, 0x21, 0x9d, 0xd6, 0xd1, 0x32, 0xe7, 0x2d, - 0x5c, 0xed, 0xb7, 0x68, 0x5d, 0xc6, 0xe0, 0x57, 0x8b, 0xc6, 0xfd, 0x31, 0xbe, 0xf9, 0x62, 0x70, - 0xae, 0xc5, 0xa3, 0x18, 0x7c, 0xb7, 0x92, 0x95, 0x58, 0xd7, 0x91, 0x67, 0x0c, 0xed, 0x0f, 0x68, - 0x43, 0x2a, 0xaa, 0x12, 0x59, 0x5d, 0x33, 0xd6, 0x4f, 0x6e, 0x6f, 0x6d, 0xe4, 0xee, 0x9d, 0xcc, - 0x7c, 0x63, 0x1e, 0x7b, 0x99, 0x6d, 0xf3, 0xa7, 0x85, 0xee, 0xe5, 0x34, 0x2f, 0x99, 0x54, 0xf6, - 0xfb, 0xdc, 0xd6, 0xf0, 0xbf, 0x6d, 0x4d, 0xab, 0xcd, 0xce, 0xb6, 0xb3, 0x9a, 0xe5, 0xf3, 0xcc, - 0xca, 0xc6, 0x8e, 0x51, 0x89, 0x29, 0x08, 0x65, 0xb5, 0xd8, 0x58, 0xdb, 0xdd, 0xdc, 0x6b, 0xdd, - 0x7a, 0x2e, 0xf7, 0xff, 0xcc, 0xbd, 0xd4, 0xd5, 0x3e, 0xde, 0xdc, 0xae, 0xf9, 0xad, 0x78, 0xc5, - 0x3c, 0x7a, 0xa1, 0xf6, 0x31, 0xaa, 0x44, 0xbc, 0x0f, 0x47, 0x30, 0x02, 0x5f, 0x71, 0x91, 0xcd, - 0xd4, 0x58, 0x2d, 0xac, 0x5f, 0xbd, 0x9e, 0xe0, 0xf5, 0x0a, 0xe7, 0x6e, 0xa7, 0xd3, 0x7a, 0x65, - 0x35, 0xe3, 0x5d, 0xf0, 0xb1, 0x9f, 0xa1, 0xad, 0x18, 0x84, 0x06, 0x5e, 0x70, 0xa9, 0x5c, 0xa6, - 0xa4, 0x79, 0x06, 0x25, 0x77, 0x27, 0x6b, 0x70, 0xeb, 0xf0, 0xe2, 0xb1, 0x77, 0x99, 0xb7, 0x1f, - 0xa0, 0x32, 0x8b, 0xc7, 0xfb, 0xba, 0x61, 0x73, 0xcf, 0xff, 0x2d, 0x57, 0xd7, 0x3d, 0x9c, 0xe7, - 0xbd, 0x05, 0x91, 0xd1, 0x6d, 0x43, 0xaf, 0xe7, 0xe8, 0xf6, 0x82, 0x36, 0x5f, 0xcd, 0xfb, 0x68, - 0xe7, 0xba, 0x37, 0x71, 0x30, 0x99, 0x39, 0x85, 0xd3, 0x99, 0x53, 0x38, 0x9b, 0x39, 0x85, 0xaf, - 0xa9, 0x63, 0x4d, 0x52, 0xc7, 0x3a, 0x4d, 0x1d, 0xeb, 0x2c, 0x75, 0xac, 0x5f, 0xa9, 0x63, 0x7d, - 0xff, 0xed, 0x14, 0xde, 0x39, 0x37, 0xff, 0x95, 0xfe, 0x04, 0x00, 0x00, 0xff, 0xff, 0x6c, 0x03, - 0xd9, 0x8f, 0xcf, 0x04, 0x00, 0x00, -} - -func (m *ClusterCIDRConfig) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *ClusterCIDRConfig) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *ClusterCIDRConfig) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - { - size, err := m.Status.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x1a - { - size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - { - size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} - -func (m *ClusterCIDRConfigList) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *ClusterCIDRConfigList) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *ClusterCIDRConfigList) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if len(m.Items) > 0 { - for iNdEx := len(m.Items) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Items[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - } - } - { - size, err := m.ListMeta.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa - return len(dAtA) - i, nil -} - -func (m *ClusterCIDRConfigSpec) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *ClusterCIDRConfigSpec) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *ClusterCIDRConfigSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - i -= len(m.IPv6CIDR) - copy(dAtA[i:], m.IPv6CIDR) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.IPv6CIDR))) - i-- - dAtA[i] = 0x22 - i -= len(m.IPv4CIDR) - copy(dAtA[i:], m.IPv4CIDR) - i = encodeVarintGenerated(dAtA, i, uint64(len(m.IPv4CIDR))) - i-- - dAtA[i] = 0x1a - i = encodeVarintGenerated(dAtA, i, uint64(m.PerNodeHostBits)) - i-- - dAtA[i] = 0x10 - if m.NodeSelector != nil { - { - size, err := m.NodeSelector.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintGenerated(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *ClusterCIDRConfigStatus) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *ClusterCIDRConfigStatus) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *ClusterCIDRConfigStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - return len(dAtA) - i, nil -} - -func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { - offset -= sovGenerated(v) - base := offset - for v >= 1<<7 { - dAtA[offset] = uint8(v&0x7f | 0x80) - v >>= 7 - offset++ - } - dAtA[offset] = uint8(v) - return base -} -func (m *ClusterCIDRConfig) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *ClusterCIDRConfigList) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *ClusterCIDRConfigSpec) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - if m.NodeSelector != nil { - l = m.NodeSelector.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - n += 1 + sovGenerated(uint64(m.PerNodeHostBits)) - l = len(m.IPv4CIDR) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.IPv6CIDR) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *ClusterCIDRConfigStatus) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - return n -} - -func sovGenerated(x uint64) (n int) { - return (math_bits.Len64(x|1) + 6) / 7 -} -func sozGenerated(x uint64) (n int) { - return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) -} -func (this *ClusterCIDRConfig) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&ClusterCIDRConfig{`, - `ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "ClusterCIDRConfigSpec", "ClusterCIDRConfigSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "ClusterCIDRConfigStatus", "ClusterCIDRConfigStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *ClusterCIDRConfigList) String() string { - if this == nil { - return "nil" - } - repeatedStringForItems := "[]ClusterCIDRConfig{" - for _, f := range this.Items { - repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "ClusterCIDRConfig", "ClusterCIDRConfig", 1), `&`, ``, 1) + "," - } - repeatedStringForItems += "}" - s := strings.Join([]string{`&ClusterCIDRConfigList{`, - `ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + repeatedStringForItems + `,`, - `}`, - }, "") - return s -} -func (this *ClusterCIDRConfigSpec) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&ClusterCIDRConfigSpec{`, - `NodeSelector:` + strings.Replace(fmt.Sprintf("%v", this.NodeSelector), "NodeSelector", "v11.NodeSelector", 1) + `,`, - `PerNodeHostBits:` + fmt.Sprintf("%v", this.PerNodeHostBits) + `,`, - `IPv4CIDR:` + fmt.Sprintf("%v", this.IPv4CIDR) + `,`, - `IPv6CIDR:` + fmt.Sprintf("%v", this.IPv6CIDR) + `,`, - `}`, - }, "") - return s -} -func (this *ClusterCIDRConfigStatus) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&ClusterCIDRConfigStatus{`, - `}`, - }, "") - return s -} -func valueToStringGenerated(v interface{}) string { - rv := reflect.ValueOf(v) - if rv.IsNil() { - return "nil" - } - pv := reflect.Indirect(rv).Interface() - return fmt.Sprintf("*%v", pv) -} -func (m *ClusterCIDRConfig) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ClusterCIDRConfig: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ClusterCIDRConfig: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *ClusterCIDRConfigList) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ClusterCIDRConfigList: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ClusterCIDRConfigList: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Items = append(m.Items, ClusterCIDRConfig{}) - if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *ClusterCIDRConfigSpec) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ClusterCIDRConfigSpec: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ClusterCIDRConfigSpec: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field NodeSelector", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.NodeSelector == nil { - m.NodeSelector = &v11.NodeSelector{} - } - if err := m.NodeSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field PerNodeHostBits", wireType) - } - m.PerNodeHostBits = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.PerNodeHostBits |= int32(b&0x7F) << shift - if b < 0x80 { - break - } - } - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field IPv4CIDR", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.IPv4CIDR = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field IPv6CIDR", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthGenerated - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.IPv6CIDR = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *ClusterCIDRConfigStatus) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ClusterCIDRConfigStatus: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ClusterCIDRConfigStatus: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - default: - iNdEx = preIndex - skippy, err := skipGenerated(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func skipGenerated(dAtA []byte) (n int, err error) { - l := len(dAtA) - iNdEx := 0 - depth := 0 - for iNdEx < l { - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowGenerated - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - wireType := int(wire & 0x7) - switch wireType { - case 0: - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowGenerated - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - iNdEx++ - if dAtA[iNdEx-1] < 0x80 { - break - } - } - case 1: - iNdEx += 8 - case 2: - var length int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowGenerated - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - length |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if length < 0 { - return 0, ErrInvalidLengthGenerated - } - iNdEx += length - case 3: - depth++ - case 4: - if depth == 0 { - return 0, ErrUnexpectedEndOfGroupGenerated - } - depth-- - case 5: - iNdEx += 4 - default: - return 0, fmt.Errorf("proto: illegal wireType %d", wireType) - } - if iNdEx < 0 { - return 0, ErrInvalidLengthGenerated - } - if depth == 0 { - return iNdEx, nil - } - } - return 0, io.ErrUnexpectedEOF -} - -var ( - ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") - ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") - ErrUnexpectedEndOfGroupGenerated = fmt.Errorf("proto: unexpected end of group") -) diff --git a/networking/v1alpha1/generated.proto b/networking/v1alpha1/generated.proto deleted file mode 100644 index 7b256b2114..0000000000 --- a/networking/v1alpha1/generated.proto +++ /dev/null @@ -1,92 +0,0 @@ -/* -Copyright The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - - -// This file was autogenerated by go-to-protobuf. Do not edit it manually! - -syntax = "proto2"; - -package k8s.io.api.networking.v1alpha1; - -import "k8s.io/api/core/v1/generated.proto"; -import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; -import "k8s.io/apimachinery/pkg/runtime/generated.proto"; -import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; - -// Package-wide variables from generator "generated". -option go_package = "k8s.io/api/networking/v1alpha1"; - -// ClusterCIDRConfig is the Schema for the clustercidrconfigs API. -message ClusterCIDRConfig { - // Standard object's metadata. - // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata - // +optional - optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; - - // Spec is the desired state of the ClusterCIDRConfig. - // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status - // +optional - optional ClusterCIDRConfigSpec spec = 2; - - // Status is the current state of the ClusterCIDRConfig. - // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status - // +optional - optional ClusterCIDRConfigStatus status = 3; -} - -// ClusterCIDRConfigList contains a list of ClusterCIDRConfig. -message ClusterCIDRConfigList { - // Standard object's metadata. - // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata - // +optional - optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; - - // Items is the list of ClusterCIDRConfigs. - repeated ClusterCIDRConfig items = 2; -} - -// ClusterCIDRConfigSpec defines the desired state of ClusterCIDRConfig. -message ClusterCIDRConfigSpec { - // NodeSelector defines which nodes the config is applicable to. - // An empty or nil NodeSelector functions as a default that applies to all nodes. - // This field is immutable. - // +optional - optional k8s.io.api.core.v1.NodeSelector nodeSelector = 1; - - // PerNodeHostBits defines the number of host bits to be configured per node. - // A subnet mask determines how much of the address is used for network bits - // and host bits. For example and IPv4 address of 192.168.0.0/24, splits the - // address into 24 bits for the network portion and 8 bits for the host portion. - // For a /24 mask for IPv4 or a /120 for IPv6, configure PerNodeHostBits=8 - // This field is immutable. - // +optional - optional int32 perNodeHostBits = 2; - - // IPv4CIDR defines an IPv4 IP block in CIDR notation(e.g. "10.0.0.0/8"). - // This field is immutable. - // +optional - optional string ipv4CIDR = 3; - - // IPv6CIDR defines an IPv6 IP block in CIDR notation(e.g. "fd12:3456:789a:1::/64"). - // This field is immutable. - // +optional - optional string ipv6CIDR = 4; -} - -// ClusterCIDRConfigStatus defines the observed state of ClusterCIDRConfig. -message ClusterCIDRConfigStatus { -} - diff --git a/networking/v1alpha1/register.go b/networking/v1alpha1/register.go deleted file mode 100644 index dcc20dc5d6..0000000000 --- a/networking/v1alpha1/register.go +++ /dev/null @@ -1,56 +0,0 @@ -/* -Copyright 2022 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1alpha1 - -import ( - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime" - "k8s.io/apimachinery/pkg/runtime/schema" -) - -// GroupName is the group name use in this package. -const GroupName = "networking.k8s.io" - -// SchemeGroupVersion is group version used to register these objects. -var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"} - -// Resource takes an unqualified resource and returns a Group qualified GroupResource. -func Resource(resource string) schema.GroupResource { - return SchemeGroupVersion.WithResource(resource).GroupResource() -} - -var ( - // SchemeBuilder holds functions that add things to a scheme. - // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. - // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) - localSchemeBuilder = &SchemeBuilder - - // AddToScheme adds the types of this group into the given scheme. - AddToScheme = localSchemeBuilder.AddToScheme -) - -// Adds the list of known types to the given scheme. -func addKnownTypes(scheme *runtime.Scheme) error { - scheme.AddKnownTypes(SchemeGroupVersion, - &ClusterCIDRConfig{}, - &ClusterCIDRConfigList{}, - ) - // Add the watch version that applies. - metav1.AddToGroupVersion(scheme, SchemeGroupVersion) - return nil -} diff --git a/networking/v1alpha1/types.go b/networking/v1alpha1/types.go deleted file mode 100644 index 777022f0b8..0000000000 --- a/networking/v1alpha1/types.go +++ /dev/null @@ -1,93 +0,0 @@ -/* -Copyright 2022 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1alpha1 - -import ( - v1 "k8s.io/api/core/v1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" -) - -// +genclient -// +genclient:nonNamespaced -// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object -// +k8s:prerelease-lifecycle-gen:introduced=1.24 - -// ClusterCIDRConfig is the Schema for the clustercidrconfigs API. -type ClusterCIDRConfig struct { - metav1.TypeMeta `json:",inline"` - // Standard object's metadata. - // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata - // +optional - metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - - // Spec is the desired state of the ClusterCIDRConfig. - // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status - // +optional - Spec ClusterCIDRConfigSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - - // Status is the current state of the ClusterCIDRConfig. - // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status - // +optional - Status ClusterCIDRConfigStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` -} - -// ClusterCIDRConfigSpec defines the desired state of ClusterCIDRConfig. -type ClusterCIDRConfigSpec struct { - // NodeSelector defines which nodes the config is applicable to. - // An empty or nil NodeSelector functions as a default that applies to all nodes. - // This field is immutable. - // +optional - NodeSelector *v1.NodeSelector `json:"nodeSelector,omitempty" protobuf:"bytes,1,opt,name=nodeSelector"` - - // PerNodeHostBits defines the number of host bits to be configured per node. - // A subnet mask determines how much of the address is used for network bits - // and host bits. For example and IPv4 address of 192.168.0.0/24, splits the - // address into 24 bits for the network portion and 8 bits for the host portion. - // For a /24 mask for IPv4 or a /120 for IPv6, configure PerNodeHostBits=8 - // This field is immutable. - // +optional - PerNodeHostBits int32 `json:"perNodeHostBits" protobuf:"varint,2,opt,name=perNodeHostBits"` - - // IPv4CIDR defines an IPv4 IP block in CIDR notation(e.g. "10.0.0.0/8"). - // This field is immutable. - // +optional - IPv4CIDR string `json:"ipv4CIDR" protobuf:"bytes,3,opt,name=ipv4CIDR"` - - // IPv6CIDR defines an IPv6 IP block in CIDR notation(e.g. "fd12:3456:789a:1::/64"). - // This field is immutable. - // +optional - IPv6CIDR string `json:"ipv6CIDR" protobuf:"bytes,4,opt,name=ipv6CIDR"` -} - -// ClusterCIDRConfigStatus defines the observed state of ClusterCIDRConfig. -type ClusterCIDRConfigStatus struct { -} - -// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object -// +k8s:prerelease-lifecycle-gen:introduced=1.24 - -// ClusterCIDRConfigList contains a list of ClusterCIDRConfig. -type ClusterCIDRConfigList struct { - metav1.TypeMeta `json:",inline"` - // Standard object's metadata. - // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata - // +optional - metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - - // Items is the list of ClusterCIDRConfigs. - Items []ClusterCIDRConfig `json:"items" protobuf:"bytes,2,rep,name=items"` -} diff --git a/networking/v1alpha1/types_swagger_doc_generated.go b/networking/v1alpha1/types_swagger_doc_generated.go deleted file mode 100644 index 09368e6351..0000000000 --- a/networking/v1alpha1/types_swagger_doc_generated.go +++ /dev/null @@ -1,71 +0,0 @@ -/* -Copyright The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1alpha1 - -// This file contains a collection of methods that can be used from go-restful to -// generate Swagger API documentation for its models. Please read this PR for more -// information on the implementation: https://github.com/emicklei/go-restful/pull/215 -// -// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if -// they are on one line! For multiple line or blocks that you want to ignore use ---. -// Any context after a --- is ignored. -// -// Those methods can be generated by using hack/update-generated-swagger-docs.sh - -// AUTO-GENERATED FUNCTIONS START HERE. DO NOT EDIT. -var map_ClusterCIDRConfig = map[string]string{ - "": "ClusterCIDRConfig is the Schema for the clustercidrconfigs API.", - "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - "spec": "Spec is the desired state of the ClusterCIDRConfig. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", - "status": "Status is the current state of the ClusterCIDRConfig. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status", -} - -func (ClusterCIDRConfig) SwaggerDoc() map[string]string { - return map_ClusterCIDRConfig -} - -var map_ClusterCIDRConfigList = map[string]string{ - "": "ClusterCIDRConfigList contains a list of ClusterCIDRConfig.", - "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", - "items": "Items is the list of ClusterCIDRConfigs.", -} - -func (ClusterCIDRConfigList) SwaggerDoc() map[string]string { - return map_ClusterCIDRConfigList -} - -var map_ClusterCIDRConfigSpec = map[string]string{ - "": "ClusterCIDRConfigSpec defines the desired state of ClusterCIDRConfig.", - "nodeSelector": "NodeSelector defines which nodes the config is applicable to. An empty or nil NodeSelector functions as a default that applies to all nodes. This field is immutable.", - "perNodeHostBits": "PerNodeHostBits defines the number of host bits to be configured per node. A subnet mask determines how much of the address is used for network bits and host bits. For example and IPv4 address of 192.168.0.0/24, splits the address into 24 bits for the network portion and 8 bits for the host portion. For a /24 mask for IPv4 or a /120 for IPv6, configure PerNodeHostBits=8 This field is immutable.", - "ipv4CIDR": "IPv4CIDR defines an IPv4 IP block in CIDR notation(e.g. \"10.0.0.0/8\"). This field is immutable.", - "ipv6CIDR": "IPv6CIDR defines an IPv6 IP block in CIDR notation(e.g. \"fd12:3456:789a:1::/64\"). This field is immutable.", -} - -func (ClusterCIDRConfigSpec) SwaggerDoc() map[string]string { - return map_ClusterCIDRConfigSpec -} - -var map_ClusterCIDRConfigStatus = map[string]string{ - "": "ClusterCIDRConfigStatus defines the observed state of ClusterCIDRConfig.", -} - -func (ClusterCIDRConfigStatus) SwaggerDoc() map[string]string { - return map_ClusterCIDRConfigStatus -} - -// AUTO-GENERATED FUNCTIONS END HERE diff --git a/networking/v1alpha1/zz_generated.deepcopy.go b/networking/v1alpha1/zz_generated.deepcopy.go deleted file mode 100644 index 8e0348aa80..0000000000 --- a/networking/v1alpha1/zz_generated.deepcopy.go +++ /dev/null @@ -1,125 +0,0 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - -/* -Copyright The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Code generated by deepcopy-gen. DO NOT EDIT. - -package v1alpha1 - -import ( - v1 "k8s.io/api/core/v1" - runtime "k8s.io/apimachinery/pkg/runtime" -) - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterCIDRConfig) DeepCopyInto(out *ClusterCIDRConfig) { - *out = *in - out.TypeMeta = in.TypeMeta - in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) - in.Spec.DeepCopyInto(&out.Spec) - out.Status = in.Status - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterCIDRConfig. -func (in *ClusterCIDRConfig) DeepCopy() *ClusterCIDRConfig { - if in == nil { - return nil - } - out := new(ClusterCIDRConfig) - in.DeepCopyInto(out) - return out -} - -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *ClusterCIDRConfig) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterCIDRConfigList) DeepCopyInto(out *ClusterCIDRConfigList) { - *out = *in - out.TypeMeta = in.TypeMeta - in.ListMeta.DeepCopyInto(&out.ListMeta) - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]ClusterCIDRConfig, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterCIDRConfigList. -func (in *ClusterCIDRConfigList) DeepCopy() *ClusterCIDRConfigList { - if in == nil { - return nil - } - out := new(ClusterCIDRConfigList) - in.DeepCopyInto(out) - return out -} - -// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *ClusterCIDRConfigList) DeepCopyObject() runtime.Object { - if c := in.DeepCopy(); c != nil { - return c - } - return nil -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterCIDRConfigSpec) DeepCopyInto(out *ClusterCIDRConfigSpec) { - *out = *in - if in.NodeSelector != nil { - in, out := &in.NodeSelector, &out.NodeSelector - *out = new(v1.NodeSelector) - (*in).DeepCopyInto(*out) - } - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterCIDRConfigSpec. -func (in *ClusterCIDRConfigSpec) DeepCopy() *ClusterCIDRConfigSpec { - if in == nil { - return nil - } - out := new(ClusterCIDRConfigSpec) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ClusterCIDRConfigStatus) DeepCopyInto(out *ClusterCIDRConfigStatus) { - *out = *in - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterCIDRConfigStatus. -func (in *ClusterCIDRConfigStatus) DeepCopy() *ClusterCIDRConfigStatus { - if in == nil { - return nil - } - out := new(ClusterCIDRConfigStatus) - in.DeepCopyInto(out) - return out -} diff --git a/networking/v1alpha1/zz_generated.prerelease-lifecycle.go b/networking/v1alpha1/zz_generated.prerelease-lifecycle.go deleted file mode 100644 index 2e48788c84..0000000000 --- a/networking/v1alpha1/zz_generated.prerelease-lifecycle.go +++ /dev/null @@ -1,58 +0,0 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - -/* -Copyright The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Code generated by prerelease-lifecycle-gen. DO NOT EDIT. - -package v1alpha1 - -// APILifecycleIntroduced is an autogenerated function, returning the release in which the API struct was introduced as int versions of major and minor for comparison. -// It is controlled by "k8s:prerelease-lifecycle-gen:introduced" tags in types.go. -func (in *ClusterCIDRConfig) APILifecycleIntroduced() (major, minor int) { - return 1, 24 -} - -// APILifecycleDeprecated is an autogenerated function, returning the release in which the API struct was or will be deprecated as int versions of major and minor for comparison. -// It is controlled by "k8s:prerelease-lifecycle-gen:deprecated" tags in types.go or "k8s:prerelease-lifecycle-gen:introduced" plus three minor. -func (in *ClusterCIDRConfig) APILifecycleDeprecated() (major, minor int) { - return 1, 27 -} - -// APILifecycleRemoved is an autogenerated function, returning the release in which the API is no longer served as int versions of major and minor for comparison. -// It is controlled by "k8s:prerelease-lifecycle-gen:removed" tags in types.go or "k8s:prerelease-lifecycle-gen:deprecated" plus three minor. -func (in *ClusterCIDRConfig) APILifecycleRemoved() (major, minor int) { - return 1, 30 -} - -// APILifecycleIntroduced is an autogenerated function, returning the release in which the API struct was introduced as int versions of major and minor for comparison. -// It is controlled by "k8s:prerelease-lifecycle-gen:introduced" tags in types.go. -func (in *ClusterCIDRConfigList) APILifecycleIntroduced() (major, minor int) { - return 1, 24 -} - -// APILifecycleDeprecated is an autogenerated function, returning the release in which the API struct was or will be deprecated as int versions of major and minor for comparison. -// It is controlled by "k8s:prerelease-lifecycle-gen:deprecated" tags in types.go or "k8s:prerelease-lifecycle-gen:introduced" plus three minor. -func (in *ClusterCIDRConfigList) APILifecycleDeprecated() (major, minor int) { - return 1, 27 -} - -// APILifecycleRemoved is an autogenerated function, returning the release in which the API is no longer served as int versions of major and minor for comparison. -// It is controlled by "k8s:prerelease-lifecycle-gen:removed" tags in types.go or "k8s:prerelease-lifecycle-gen:deprecated" plus three minor. -func (in *ClusterCIDRConfigList) APILifecycleRemoved() (major, minor int) { - return 1, 30 -} diff --git a/roundtrip_test.go b/roundtrip_test.go index 6cdf8fcf24..e91ee93407 100644 --- a/roundtrip_test.go +++ b/roundtrip_test.go @@ -52,7 +52,6 @@ import ( flowcontrolv1beta1 "k8s.io/api/flowcontrol/v1beta1" imagepolicyv1alpha1 "k8s.io/api/imagepolicy/v1alpha1" networkingv1 "k8s.io/api/networking/v1" - networkingv1alpha1 "k8s.io/api/networking/v1alpha1" networkingv1beta1 "k8s.io/api/networking/v1beta1" nodev1 "k8s.io/api/node/v1" nodev1alpha1 "k8s.io/api/node/v1alpha1" @@ -111,7 +110,6 @@ var groups = []runtime.SchemeBuilder{ imagepolicyv1alpha1.SchemeBuilder, networkingv1.SchemeBuilder, networkingv1beta1.SchemeBuilder, - networkingv1alpha1.SchemeBuilder, nodev1.SchemeBuilder, nodev1alpha1.SchemeBuilder, nodev1beta1.SchemeBuilder, diff --git a/testdata/HEAD/networking.k8s.io.v1alpha1.ClusterCIDRConfig.json b/testdata/HEAD/networking.k8s.io.v1alpha1.ClusterCIDRConfig.json deleted file mode 100644 index bf7709baac..0000000000 --- a/testdata/HEAD/networking.k8s.io.v1alpha1.ClusterCIDRConfig.json +++ /dev/null @@ -1,77 +0,0 @@ -{ - "kind": "ClusterCIDRConfig", - "apiVersion": "networking.k8s.io/v1alpha1", - "metadata": { - "name": "nameValue", - "generateName": "generateNameValue", - "namespace": "namespaceValue", - "selfLink": "selfLinkValue", - "uid": "uidValue", - "resourceVersion": "resourceVersionValue", - "generation": 7, - "creationTimestamp": "2008-01-01T01:01:01Z", - "deletionTimestamp": "2009-01-01T01:01:01Z", - "deletionGracePeriodSeconds": 10, - "labels": { - "labelsKey": "labelsValue" - }, - "annotations": { - "annotationsKey": "annotationsValue" - }, - "ownerReferences": [ - { - "apiVersion": "apiVersionValue", - "kind": "kindValue", - "name": "nameValue", - "uid": "uidValue", - "controller": true, - "blockOwnerDeletion": true - } - ], - "finalizers": [ - "finalizersValue" - ], - "clusterName": "clusterNameValue", - "managedFields": [ - { - "manager": "managerValue", - "operation": "operationValue", - "apiVersion": "apiVersionValue", - "time": "2004-01-01T01:01:01Z", - "fieldsType": "fieldsTypeValue", - "fieldsV1": {}, - "subresource": "subresourceValue" - } - ] - }, - "spec": { - "nodeSelector": { - "nodeSelectorTerms": [ - { - "matchExpressions": [ - { - "key": "keyValue", - "operator": "operatorValue", - "values": [ - "valuesValue" - ] - } - ], - "matchFields": [ - { - "key": "keyValue", - "operator": "operatorValue", - "values": [ - "valuesValue" - ] - } - ] - } - ] - }, - "perNodeHostBits": 2, - "ipv4CIDR": "ipv4CIDRValue", - "ipv6CIDR": "ipv6CIDRValue" - }, - "status": {} -} \ No newline at end of file diff --git a/testdata/HEAD/networking.k8s.io.v1alpha1.ClusterCIDRConfig.pb b/testdata/HEAD/networking.k8s.io.v1alpha1.ClusterCIDRConfig.pb deleted file mode 100644 index bd3c3788f3..0000000000 Binary files a/testdata/HEAD/networking.k8s.io.v1alpha1.ClusterCIDRConfig.pb and /dev/null differ diff --git a/testdata/HEAD/networking.k8s.io.v1alpha1.ClusterCIDRConfig.yaml b/testdata/HEAD/networking.k8s.io.v1alpha1.ClusterCIDRConfig.yaml deleted file mode 100644 index 0f560e9378..0000000000 --- a/testdata/HEAD/networking.k8s.io.v1alpha1.ClusterCIDRConfig.yaml +++ /dev/null @@ -1,52 +0,0 @@ -apiVersion: networking.k8s.io/v1alpha1 -kind: ClusterCIDRConfig -metadata: - annotations: - annotationsKey: annotationsValue - clusterName: clusterNameValue - creationTimestamp: "2008-01-01T01:01:01Z" - deletionGracePeriodSeconds: 10 - deletionTimestamp: "2009-01-01T01:01:01Z" - finalizers: - - finalizersValue - generateName: generateNameValue - generation: 7 - labels: - labelsKey: labelsValue - managedFields: - - apiVersion: apiVersionValue - fieldsType: fieldsTypeValue - fieldsV1: {} - manager: managerValue - operation: operationValue - subresource: subresourceValue - time: "2004-01-01T01:01:01Z" - name: nameValue - namespace: namespaceValue - ownerReferences: - - apiVersion: apiVersionValue - blockOwnerDeletion: true - controller: true - kind: kindValue - name: nameValue - uid: uidValue - resourceVersion: resourceVersionValue - selfLink: selfLinkValue - uid: uidValue -spec: - ipv4CIDR: ipv4CIDRValue - ipv6CIDR: ipv6CIDRValue - nodeSelector: - nodeSelectorTerms: - - matchExpressions: - - key: keyValue - operator: operatorValue - values: - - valuesValue - matchFields: - - key: keyValue - operator: operatorValue - values: - - valuesValue - perNodeHostBits: 2 -status: {}