diff --git a/config/crd/bases/config.katalyst.kubewharf.io_adminqosconfigurations.yaml b/config/crd/bases/config.katalyst.kubewharf.io_adminqosconfigurations.yaml index 90ed97f..b706d11 100644 --- a/config/crd/bases/config.katalyst.kubewharf.io_adminqosconfigurations.yaml +++ b/config/crd/bases/config.katalyst.kubewharf.io_adminqosconfigurations.yaml @@ -257,13 +257,6 @@ spec: try to evict some pods. For example: "100000", "10%".' pattern: ^(0|[1-9]\d*)(\.\d+)?%?$|^\d+$ type: string - podMinimumUsedThreshold: - description: 'PodMinimumUsedThreshold is a threshold for - all pods. The eviction manager will ignore this pod - if its rootfs used in bytes is lower than this threshold. - For example: "200Gi", "1%".' - pattern: ^(0|[1-9][0-9]*)(\.[0-9]+)?%?$|^(0|[1-9][0-9]*)([kKmMGTPeE]i?)$ - type: string podMinimumInodesUsedThreshold: description: 'PodMinimumInodesUsedThreshold is a threshold for all pods. The eviction manager will ignore this @@ -271,11 +264,11 @@ spec: For example: "1000", "1%".' pattern: ^(0|[1-9]\d*)(\.\d+)?%?$|^\d+$ type: string - reclaimedQoSPodUsedPriorityThreshold: - description: 'ReclaimedQoSPodUsedPriorityThreshold is - a threshold for all offline pods. The eviction manager - will prioritize the eviction of offline pods that reach - this threshold. For example: "100Gi", "1%".' + podMinimumUsedThreshold: + description: 'PodMinimumUsedThreshold is a threshold for + all pods. The eviction manager will ignore this pod + if its rootfs used in bytes is lower than this threshold. + For example: "200Gi", "1%".' pattern: ^(0|[1-9][0-9]*)(\.[0-9]+)?%?$|^(0|[1-9][0-9]*)([kKmMGTPeE]i?)$ type: string reclaimedQoSPodInodesUsedPriorityThreshold: @@ -285,6 +278,13 @@ spec: reach this threshold. For example: "500", "1%".' pattern: ^(0|[1-9]\d*)(\.\d+)?%?$|^\d+$ type: string + reclaimedQoSPodUsedPriorityThreshold: + description: 'ReclaimedQoSPodUsedPriorityThreshold is + a threshold for all offline pods. The eviction manager + will prioritize the eviction of offline pods that reach + this threshold. For example: "100Gi", "1%".' + pattern: ^(0|[1-9][0-9]*)(\.[0-9]+)?%?$|^(0|[1-9][0-9]*)([kKmMGTPeE]i?)$ + type: string type: object systemLoadPressureEvictionConfig: description: SystemLoadPressureEvictionConfig is the config diff --git a/config/crd/bases/tide.katalyst.kubewharf.io_tidenodepools.yaml b/config/crd/bases/tide.katalyst.kubewharf.io_tidenodepools.yaml index aad3d73..107fd39 100644 --- a/config/crd/bases/tide.katalyst.kubewharf.io_tidenodepools.yaml +++ b/config/crd/bases/tide.katalyst.kubewharf.io_tidenodepools.yaml @@ -43,7 +43,7 @@ spec: properties: type: type: string - waterFlow: + watermark: properties: evictOfflinePodTaint: properties: diff --git a/pkg/apis/tide/v1alpha1/types.go b/pkg/apis/tide/v1alpha1/types.go index 623b7e1..34bb126 100644 --- a/pkg/apis/tide/v1alpha1/types.go +++ b/pkg/apis/tide/v1alpha1/types.go @@ -32,16 +32,16 @@ type TideNodePoolSpec struct { type EvictStrategy struct { Type string `json:"type"` // +optional - WaterFlow WaterFlow `json:"waterFlow,omitempty"` + Watermark Watermark `json:"watermark,omitempty"` } type EvictStrategyType string const ( - WaterFlowStrategy EvictStrategyType = "water-flow" + WatermarkStrategy EvictStrategyType = "watermark" ) -type WaterFlow struct { +type Watermark struct { // +optional EvictOnlinePodTaint *TaintOption `json:"evictOnlinePodTaint,omitempty"` // +optional @@ -87,12 +87,12 @@ type TideNodePoolStatus struct { // INSERT ADDITIONAL STATUS FIELD - define observed state of cluster // Important: Run "make" to regenerate code after modifying this file // +optional - ReverseNodes ReverseNodes `json:"reverseNodes,omitempty"` + ReserveNodes ReserveNodes `json:"reverseNodes,omitempty"` // +optional TideNodes TideNodes `json:"tideNodes,omitempty"` } -type ReverseNodes struct { +type ReserveNodes struct { OnlineNodes []string `json:"onlineNodes,omitempty"` OfflineNodes []string `json:"offlineNodes,omitempty"` } diff --git a/pkg/apis/tide/v1alpha1/zz_generated.deepcopy.go b/pkg/apis/tide/v1alpha1/zz_generated.deepcopy.go index 8813619..c3ed75e 100644 --- a/pkg/apis/tide/v1alpha1/zz_generated.deepcopy.go +++ b/pkg/apis/tide/v1alpha1/zz_generated.deepcopy.go @@ -29,7 +29,7 @@ import ( // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *EvictStrategy) DeepCopyInto(out *EvictStrategy) { *out = *in - in.WaterFlow.DeepCopyInto(&out.WaterFlow) + in.Watermark.DeepCopyInto(&out.Watermark) return } @@ -122,7 +122,7 @@ func (in *PodSelector) DeepCopy() *PodSelector { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *ReverseNodes) DeepCopyInto(out *ReverseNodes) { +func (in *ReserveNodes) DeepCopyInto(out *ReserveNodes) { *out = *in if in.OnlineNodes != nil { in, out := &in.OnlineNodes, &out.OnlineNodes @@ -137,12 +137,12 @@ func (in *ReverseNodes) DeepCopyInto(out *ReverseNodes) { return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReverseNodes. -func (in *ReverseNodes) DeepCopy() *ReverseNodes { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReserveNodes. +func (in *ReserveNodes) DeepCopy() *ReserveNodes { if in == nil { return nil } - out := new(ReverseNodes) + out := new(ReserveNodes) in.DeepCopyInto(out) return out } @@ -271,7 +271,7 @@ func (in *TideNodePoolSpec) DeepCopy() *TideNodePoolSpec { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TideNodePoolStatus) DeepCopyInto(out *TideNodePoolStatus) { *out = *in - in.ReverseNodes.DeepCopyInto(&out.ReverseNodes) + in.ReserveNodes.DeepCopyInto(&out.ReserveNodes) in.TideNodes.DeepCopyInto(&out.TideNodes) return } @@ -308,7 +308,7 @@ func (in *TideNodes) DeepCopy() *TideNodes { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *WaterFlow) DeepCopyInto(out *WaterFlow) { +func (in *Watermark) DeepCopyInto(out *Watermark) { *out = *in if in.EvictOnlinePodTaint != nil { in, out := &in.EvictOnlinePodTaint, &out.EvictOnlinePodTaint @@ -323,12 +323,12 @@ func (in *WaterFlow) DeepCopyInto(out *WaterFlow) { return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WaterFlow. -func (in *WaterFlow) DeepCopy() *WaterFlow { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Watermark. +func (in *Watermark) DeepCopy() *Watermark { if in == nil { return nil } - out := new(WaterFlow) + out := new(Watermark) in.DeepCopyInto(out) return out } diff --git a/pkg/client/clientset/versioned/fake/register.go b/pkg/client/clientset/versioned/fake/register.go index 0f7d311..9aaf89e 100644 --- a/pkg/client/clientset/versioned/fake/register.go +++ b/pkg/client/clientset/versioned/fake/register.go @@ -51,14 +51,14 @@ var localSchemeBuilder = runtime.SchemeBuilder{ // AddToScheme adds all types of this clientset into the given scheme. This allows composition // of clientsets, like in: // -// import ( -// "k8s.io/client-go/kubernetes" -// clientsetscheme "k8s.io/client-go/kubernetes/scheme" -// aggregatorclientsetscheme "k8s.io/kube-aggregator/pkg/client/clientset_generated/clientset/scheme" -// ) +// import ( +// "k8s.io/client-go/kubernetes" +// clientsetscheme "k8s.io/client-go/kubernetes/scheme" +// aggregatorclientsetscheme "k8s.io/kube-aggregator/pkg/client/clientset_generated/clientset/scheme" +// ) // -// kclientset, _ := kubernetes.NewForConfig(c) -// _ = aggregatorclientsetscheme.AddToScheme(clientsetscheme.Scheme) +// kclientset, _ := kubernetes.NewForConfig(c) +// _ = aggregatorclientsetscheme.AddToScheme(clientsetscheme.Scheme) // // After this, RawExtensions in Kubernetes types will serialize kube-aggregator types // correctly. diff --git a/pkg/client/clientset/versioned/scheme/register.go b/pkg/client/clientset/versioned/scheme/register.go index 17ad6fb..ffa9cdb 100644 --- a/pkg/client/clientset/versioned/scheme/register.go +++ b/pkg/client/clientset/versioned/scheme/register.go @@ -51,14 +51,14 @@ var localSchemeBuilder = runtime.SchemeBuilder{ // AddToScheme adds all types of this clientset into the given scheme. This allows composition // of clientsets, like in: // -// import ( -// "k8s.io/client-go/kubernetes" -// clientsetscheme "k8s.io/client-go/kubernetes/scheme" -// aggregatorclientsetscheme "k8s.io/kube-aggregator/pkg/client/clientset_generated/clientset/scheme" -// ) +// import ( +// "k8s.io/client-go/kubernetes" +// clientsetscheme "k8s.io/client-go/kubernetes/scheme" +// aggregatorclientsetscheme "k8s.io/kube-aggregator/pkg/client/clientset_generated/clientset/scheme" +// ) // -// kclientset, _ := kubernetes.NewForConfig(c) -// _ = aggregatorclientsetscheme.AddToScheme(clientsetscheme.Scheme) +// kclientset, _ := kubernetes.NewForConfig(c) +// _ = aggregatorclientsetscheme.AddToScheme(clientsetscheme.Scheme) // // After this, RawExtensions in Kubernetes types will serialize kube-aggregator types // correctly.