diff --git a/config/v1/0000_10_config-operator_01_node.crd.yaml b/config/v1/0000_10_config-operator_01_node.crd.yaml index 915961e1497..a4ef368c2c2 100644 --- a/config/v1/0000_10_config-operator_01_node.crd.yaml +++ b/config/v1/0000_10_config-operator_01_node.crd.yaml @@ -53,55 +53,6 @@ spec: status: description: status holds observed values. type: object - properties: - workerLatencyProfileStatus: - description: WorkerLatencyProfileStatus provides the current status of WorkerLatencyProfile - type: object - properties: - conditions: - description: conditions describes the state of the WorkerLatencyProfile and related components (Kubelet or Controller Manager or Kube API Server) whether progressing, degraded or complete - type: array - items: - description: "Condition contains details for one aspect of the current state of this API Resource. --- This struct is intended for direct use as an array at the field path .status.conditions. For example, type FooStatus struct{ // Represents the observations of a foo's current state. // Known .status.conditions.type are: \"Available\", \"Progressing\", and \"Degraded\" // +patchMergeKey=type // +patchStrategy=merge // +listType=map // +listMapKey=type Conditions []metav1.Condition `json:\"conditions,omitempty\" patchStrategy:\"merge\" patchMergeKey:\"type\" protobuf:\"bytes,1,rep,name=conditions\"` \n // other fields }" - type: object - required: - - lastTransitionTime - - message - - reason - - status - - type - properties: - lastTransitionTime: - description: lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable. - type: string - format: date-time - message: - description: message is a human readable message indicating details about the transition. This may be an empty string. - type: string - maxLength: 32768 - observedGeneration: - description: observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance. - type: integer - format: int64 - minimum: 0 - reason: - description: reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty. - type: string - maxLength: 1024 - minLength: 1 - pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$ - status: - description: status of the condition, one of True, False, Unknown. - type: string - enum: - - "True" - - "False" - - Unknown - type: - description: type of condition in CamelCase or in foo.example.com/CamelCase. --- Many .condition.type values are consistent across resources like Available, but because arbitrary conditions can be useful (see .node.status.conditions), the ability to deconflict is important. The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt) - type: string - maxLength: 316 - pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$ served: true storage: true subresources: diff --git a/config/v1/types_node.go b/config/v1/types_node.go index d927bd89446..10a8059027b 100644 --- a/config/v1/types_node.go +++ b/config/v1/types_node.go @@ -41,11 +41,7 @@ type NodeSpec struct { WorkerLatencyProfile WorkerLatencyProfileType `json:"workerLatencyProfile,omitempty"` } -type NodeStatus struct { - // WorkerLatencyProfileStatus provides the current status of WorkerLatencyProfile - // +optional - WorkerLatencyProfileStatus WorkerLatencyProfileStatus `json:"workerLatencyProfileStatus,omitempty"` -} +type NodeStatus struct{} // +kubebuilder:validation:Enum=v1;v2;"" type CgroupMode string @@ -100,43 +96,6 @@ const ( LowUnreachableTolerationSeconds = 60 ) -// WorkerLatencyProfileStatus provides status information about the WorkerLatencyProfile rollout -type WorkerLatencyProfileStatus struct { - // conditions describes the state of the WorkerLatencyProfile and related components - // (Kubelet or Controller Manager or Kube API Server) whether progressing, degraded or complete - // +patchMergeKey=type - // +patchStrategy=merge - // +optional - Conditions []metav1.Condition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type"` -} - -// Different condition types to be used by KubeletOperator, Kube Controller -// Manager Operator and Kube API Server Operator -const ( - // Progressing indicates that the updates to component (Kubelet or Controller - // Manager or Kube API Server) is actively rolling out, propagating changes to the - // respective arguments. - KubeletProgressing = "KubeletProgressing" - KubeControllerManagerProgressing = "KubeControllerManagerProgressing" - KubeAPIServerProgressing = "KubeAPIServerProgressing" - - // Complete indicates whether the component (Kubelet or Controller Manager or Kube API Server) - // is successfully updated the respective arguments. - KubeletComplete = "KubeletComplete" - KubeControllerManagerComplete = "KubeControllerManagerComplete" - KubeAPIServerComplete = "KubeAPIServerComplete" - - // Degraded indicates that the component (Kubelet or Controller Manager or Kube API Server) - // does not reach the state 'Complete' over a period of time - // resulting in either a lower quality or absence of service. - // If the component enters in this state, "Default" WorkerLatencyProfileType - // rollout will be initiated to restore the respective default arguments of all - // components. - KubeletDegraded = "KubeletDegraded" - KubeControllerManagerDegraded = "KubeControllerManagerDegraded" - KubeAPIServerDegraded = "KubeAPIServerDegraded" -) - // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // Compatibility level 1: Stable within a major release for a minimum of 12 months or 3 minor releases (whichever is longer). diff --git a/config/v1/zz_generated.deepcopy.go b/config/v1/zz_generated.deepcopy.go index d5f73e01f57..e3f6c3c68f6 100644 --- a/config/v1/zz_generated.deepcopy.go +++ b/config/v1/zz_generated.deepcopy.go @@ -3259,7 +3259,7 @@ func (in *Node) DeepCopyInto(out *Node) { out.TypeMeta = in.TypeMeta in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) out.Spec = in.Spec - in.Status.DeepCopyInto(&out.Status) + out.Status = in.Status return } @@ -3333,7 +3333,6 @@ func (in *NodeSpec) DeepCopy() *NodeSpec { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *NodeStatus) DeepCopyInto(out *NodeStatus) { *out = *in - in.WorkerLatencyProfileStatus.DeepCopyInto(&out.WorkerLatencyProfileStatus) return } @@ -4800,26 +4799,3 @@ func (in *WebhookTokenAuthenticator) DeepCopy() *WebhookTokenAuthenticator { in.DeepCopyInto(out) return out } - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *WorkerLatencyProfileStatus) DeepCopyInto(out *WorkerLatencyProfileStatus) { - *out = *in - if in.Conditions != nil { - in, out := &in.Conditions, &out.Conditions - *out = make([]metav1.Condition, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } - } - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerLatencyProfileStatus. -func (in *WorkerLatencyProfileStatus) DeepCopy() *WorkerLatencyProfileStatus { - if in == nil { - return nil - } - out := new(WorkerLatencyProfileStatus) - in.DeepCopyInto(out) - return out -} diff --git a/config/v1/zz_generated.swagger_doc_generated.go b/config/v1/zz_generated.swagger_doc_generated.go index 1e789e47523..c8f59db3a7d 100644 --- a/config/v1/zz_generated.swagger_doc_generated.go +++ b/config/v1/zz_generated.swagger_doc_generated.go @@ -1573,23 +1573,6 @@ func (NodeSpec) SwaggerDoc() map[string]string { return map_NodeSpec } -var map_NodeStatus = map[string]string{ - "workerLatencyProfileStatus": "WorkerLatencyProfileStatus provides the current status of WorkerLatencyProfile", -} - -func (NodeStatus) SwaggerDoc() map[string]string { - return map_NodeStatus -} - -var map_WorkerLatencyProfileStatus = map[string]string{ - "": "WorkerLatencyProfileStatus provides status information about the WorkerLatencyProfile rollout", - "conditions": "conditions describes the state of the WorkerLatencyProfile and related components (Kubelet or Controller Manager or Kube API Server) whether progressing, degraded or complete", -} - -func (WorkerLatencyProfileStatus) SwaggerDoc() map[string]string { - return map_WorkerLatencyProfileStatus -} - var map_BasicAuthIdentityProvider = map[string]string{ "": "BasicAuthPasswordIdentityProvider provides identities for users authenticating using HTTP basic auth credentials", }