From 9ec2a40108a5ed9cbf57bcb16ce8b409204de698 Mon Sep 17 00:00:00 2001 From: Huabing Zhao Date: Tue, 20 Aug 2024 22:00:08 +0800 Subject: [PATCH] chore: remove BackendTrafficPolicyConnection (#4010) * remove BackendTrafficPolicyConnection Signed-off-by: Huabing Zhao * remove BackendTrafficPolicyConnection Signed-off-by: Huabing Zhao --------- Signed-off-by: Huabing Zhao --- api/v1alpha1/backendtrafficpolicy_types.go | 13 ------------ api/v1alpha1/zz_generated.deepcopy.go | 20 ------------------- site/content/en/latest/api/extension_types.md | 2 -- site/content/zh/latest/api/extension_types.md | 2 -- 4 files changed, 37 deletions(-) diff --git a/api/v1alpha1/backendtrafficpolicy_types.go b/api/v1alpha1/backendtrafficpolicy_types.go index 63e9767070e..9d15ccd6896 100644 --- a/api/v1alpha1/backendtrafficpolicy_types.go +++ b/api/v1alpha1/backendtrafficpolicy_types.go @@ -6,7 +6,6 @@ package v1alpha1 import ( - "k8s.io/apimachinery/pkg/api/resource" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" gwapiv1a2 "sigs.k8s.io/gateway-api/apis/v1alpha2" ) @@ -86,18 +85,6 @@ type BackendTrafficPolicyList struct { Items []BackendTrafficPolicy `json:"items"` } -// BackendTrafficPolicyConnection allows users to configure connection-level settings of backend -type BackendTrafficPolicyConnection struct { - // BufferLimit Soft limit on size of the cluster’s connections read and write buffers. - // If unspecified, an implementation defined default is applied (32768 bytes). - // For example, 20Mi, 1Gi, 256Ki etc. - // Note: that when the suffix is not provided, the value is interpreted as bytes. - // - // +kubebuilder:validation:XValidation:rule="type(self) == string ? self.matches(r\"^[1-9]+[0-9]*([EPTGMK]i|[EPTGMk])?$\") : type(self) == int",message="BufferLimit must be of the format \"^[1-9]+[0-9]*([EPTGMK]i|[EPTGMk])?$\"" - // +optional - BufferLimit *resource.Quantity `json:"bufferLimit,omitempty"` -} - // ClusterSettings provides the various knobs that can be set to control how traffic to a given // backend will be configured. type ClusterSettings struct { diff --git a/api/v1alpha1/zz_generated.deepcopy.go b/api/v1alpha1/zz_generated.deepcopy.go index 0e43f4cf493..1680d26cca4 100644 --- a/api/v1alpha1/zz_generated.deepcopy.go +++ b/api/v1alpha1/zz_generated.deepcopy.go @@ -488,26 +488,6 @@ func (in *BackendTrafficPolicy) DeepCopyObject() runtime.Object { return nil } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *BackendTrafficPolicyConnection) DeepCopyInto(out *BackendTrafficPolicyConnection) { - *out = *in - if in.BufferLimit != nil { - in, out := &in.BufferLimit, &out.BufferLimit - x := (*in).DeepCopy() - *out = &x - } -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BackendTrafficPolicyConnection. -func (in *BackendTrafficPolicyConnection) DeepCopy() *BackendTrafficPolicyConnection { - if in == nil { - return nil - } - out := new(BackendTrafficPolicyConnection) - in.DeepCopyInto(out) - return out -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *BackendTrafficPolicyList) DeepCopyInto(out *BackendTrafficPolicyList) { *out = *in diff --git a/site/content/en/latest/api/extension_types.md b/site/content/en/latest/api/extension_types.md index db902e65878..7807853c8e0 100644 --- a/site/content/en/latest/api/extension_types.md +++ b/site/content/en/latest/api/extension_types.md @@ -435,8 +435,6 @@ _Appears in:_ | `status` | _[PolicyStatus](https://gateway-api.sigs.k8s.io/reference/spec/#gateway.networking.k8s.io/v1alpha2.PolicyStatus)_ | true | status defines the current status of BackendTrafficPolicy. | - - #### BackendTrafficPolicyList diff --git a/site/content/zh/latest/api/extension_types.md b/site/content/zh/latest/api/extension_types.md index db902e65878..7807853c8e0 100644 --- a/site/content/zh/latest/api/extension_types.md +++ b/site/content/zh/latest/api/extension_types.md @@ -435,8 +435,6 @@ _Appears in:_ | `status` | _[PolicyStatus](https://gateway-api.sigs.k8s.io/reference/spec/#gateway.networking.k8s.io/v1alpha2.PolicyStatus)_ | true | status defines the current status of BackendTrafficPolicy. | - - #### BackendTrafficPolicyList