Skip to content

Commit

Permalink
Merge pull request #5691 from LavredisG/patch-3
Browse files Browse the repository at this point in the history
Update types.go
  • Loading branch information
karmada-bot authored Nov 22, 2024
2 parents 2f1fe6e + 6d2ae6b commit 2f5dc4f
Show file tree
Hide file tree
Showing 4 changed files with 74 additions and 74 deletions.
28 changes: 14 additions & 14 deletions api/openapi-spec/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -17253,7 +17253,7 @@
}
},
"com.github.karmada-io.karmada.pkg.apis.cluster.v1alpha1.Cluster": {
"description": "Cluster represents the desire state and status of a member cluster.",
"description": "Cluster represents the desired state and status of a member cluster.",
"type": "object",
"required": [
"spec"
Expand Down Expand Up @@ -17291,7 +17291,7 @@
]
},
"com.github.karmada-io.karmada.pkg.apis.cluster.v1alpha1.ClusterList": {
"description": "ClusterList contains a list of member cluster",
"description": "ClusterList contains a list of member clusters",
"type": "object",
"required": [
"items"
Expand Down Expand Up @@ -17338,11 +17338,11 @@
"type": "string"
},
"id": {
"description": "ID is the unique identifier for the cluster. It is different from the object uid(.metadata.uid) and typically collected automatically from member cluster during the progress of registration.\n\nThe value is collected in order: 1. If the registering cluster enabled ClusterProperty API and defined the cluster ID by\n creating a ClusterProperty object with name 'cluster.clusterset.k8s.io', Karmada would\n take the defined value in the ClusterProperty object.\n See https://github.com/kubernetes-sigs/about-api for more details about ClusterProperty API.\n2. Take the uid of 'kube-system' namespace on the registering cluster.\n\nPlease don't update this value unless you know what you are doing, because it will/may be used to : - uniquely identify the clusters within the Karmada system. - compose the DNS name of multi-cluster services.",
"description": "ID is the unique identifier for the cluster. It is different from the object uid(.metadata.uid) and is typically collected automatically from each member cluster during the process of registration.\n\nThe value is collected in order: 1. If the registering cluster enabled ClusterProperty API and defined the cluster ID by\n creating a ClusterProperty object with name 'cluster.clusterset.k8s.io', Karmada would\n take the defined value in the ClusterProperty object.\n See https://github.com/kubernetes-sigs/about-api for more details about ClusterProperty API.\n2. Take the uid of 'kube-system' namespace on the registering cluster.\n\nPlease don't update this value unless you know what you are doing, because it will/may be used to : - uniquely identify the clusters within the Karmada system. - compose the DNS name of multi-cluster services.",
"type": "string"
},
"impersonatorSecretRef": {
"description": "ImpersonatorSecretRef represents the secret contains the token of impersonator. The secret should hold credentials as follows: - secret.data.token",
"description": "ImpersonatorSecretRef represents the secret that contains the token of impersonator. The secret should hold credentials as follows: - secret.data.token",
"$ref": "#/definitions/com.github.karmada-io.karmada.pkg.apis.cluster.v1alpha1.LocalSecretReference"
},
"insecureSkipTLSVerification": {
Expand All @@ -17354,19 +17354,19 @@
"type": "string"
},
"proxyHeader": {
"description": "ProxyHeader is the HTTP header required by proxy server. The key in the key-value pair is HTTP header key and value is the associated header payloads. For the header with multiple values, the values should be separated by comma(e.g. 'k1': 'v1,v2,v3').",
"description": "ProxyHeader is the HTTP header required by proxy server. The key in the key-value pair is HTTP header key and the value is the associated header payloads. For the header with multiple values, the values should be separated by comma(e.g. 'k1': 'v1,v2,v3').",
"type": "object",
"additionalProperties": {
"type": "string",
"default": ""
}
},
"proxyURL": {
"description": "ProxyURL is the proxy URL for the cluster. If not empty, the karmada control plane will use this proxy to talk to the cluster. More details please refer to: https://github.com/kubernetes/client-go/issues/351",
"description": "ProxyURL is the proxy URL for the cluster. If not empty, the karmada control plane will use this proxy to talk to the cluster. For more details please refer to: https://github.com/kubernetes/client-go/issues/351",
"type": "string"
},
"region": {
"description": "Region represents the region of the member cluster locate in.",
"description": "Region represents the region in which the member cluster is located.",
"type": "string"
},
"resourceModels": {
Expand All @@ -17378,24 +17378,24 @@
}
},
"secretRef": {
"description": "SecretRef represents the secret contains mandatory credentials to access the member cluster. The secret should hold credentials as follows: - secret.data.token - secret.data.caBundle",
"description": "SecretRef represents the secret that contains mandatory credentials to access the member cluster. The secret should hold credentials as follows: - secret.data.token - secret.data.caBundle",
"$ref": "#/definitions/com.github.karmada-io.karmada.pkg.apis.cluster.v1alpha1.LocalSecretReference"
},
"syncMode": {
"description": "SyncMode describes how a cluster sync resources from karmada control plane.",
"description": "SyncMode describes how a cluster syncs resources from karmada control plane.",
"type": "string",
"default": ""
},
"taints": {
"description": "Taints attached to the member cluster. Taints on the cluster have the \"effect\" on any resource that does not tolerate the Taint.",
"description": "Taints are attached to the member cluster. Taints on the cluster have the \"effect\" on any resource that does not tolerate the Taint.",
"type": "array",
"items": {
"default": {},
"$ref": "#/definitions/io.k8s.api.core.v1.Taint"
}
},
"zone": {
"description": "Zone represents the zone of the member cluster locate in. Deprecated: This filed was never been used by Karmada, and it will not be removed from v1alpha1 for backward compatibility, use Zones instead.",
"description": "Zone represents the zone in which the member cluster is located. Deprecated: This field was never been used by Karmada, and it will not be removed from v1alpha1 for backward compatibility, use Zones instead.",
"type": "string"
},
"zones": {
Expand All @@ -17413,7 +17413,7 @@
"type": "object",
"properties": {
"apiEnablements": {
"description": "APIEnablements represents the list of APIs installed in the member cluster.",
"description": "APIEnablements represents the list of APIs installed on the member cluster.",
"type": "array",
"items": {
"default": {},
Expand Down Expand Up @@ -17459,7 +17459,7 @@
],
"properties": {
"name": {
"description": "Name is the name of resource being referenced.",
"description": "Name is the name of the resource being referenced.",
"type": "string",
"default": ""
},
Expand Down Expand Up @@ -17511,7 +17511,7 @@
}
},
"com.github.karmada-io.karmada.pkg.apis.cluster.v1alpha1.ResourceModelRange": {
"description": "ResourceModelRange describes the detail of each modeling quota that ranges from min to max. Please pay attention, by default, the value of min can be inclusive, and the value of max cannot be inclusive. E.g. in an interval, min = 2, max =10 is set, which means the interval [2,10). This rule ensure that all intervals have the same meaning. If the last interval is infinite, it is definitely unreachable. Therefore, we define the right interval as the open interval. For a valid interval, the value on the right is greater than the value on the left, in other words, max must be greater than min. It is strongly recommended that the [Min, Max) of all ResourceModelRanges can make a continuous interval.",
"description": "ResourceModelRange describes the detail of each modeling quota that ranges from min to max. Please pay attention, by default, the value of min can be inclusive, and the value of max cannot be inclusive. E.g. in an interval, min = 2, max = 10 is set, which means the interval [2,10). This rule ensures that all intervals have the same meaning. If the last interval is infinite, it is definitely unreachable. Therefore, we define the right interval as the open interval. For a valid interval, the value on the right is greater than the value on the left, in other words, max must be greater than min. It is strongly recommended that the [Min, Max) of all ResourceModelRanges can make a continuous interval.",
"type": "object",
"required": [
"name",
Expand Down
46 changes: 23 additions & 23 deletions pkg/apis/cluster/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ import (
// +genclient:nonNamespaced
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

// Cluster represents the desire state and status of a member cluster.
// Cluster represents the desired state and status of a member cluster.
type Cluster struct {
metav1.TypeMeta
metav1.ObjectMeta
Expand All @@ -44,8 +44,8 @@ type Cluster struct {
// ClusterSpec defines the desired state of a member cluster.
type ClusterSpec struct {
// ID is the unique identifier for the cluster.
// It is different from the object uid(.metadata.uid) and typically collected automatically
// from member cluster during the progress of registration.
// It is different from the object uid(.metadata.uid) and is typically collected automatically
// from each member cluster during the process of registration.
//
// The value is collected in order:
// 1. If the registering cluster enabled ClusterProperty API and defined the cluster ID by
Expand All @@ -63,7 +63,7 @@ type ClusterSpec struct {
// +kubebuilder:validation:Maxlength=128000
ID string `json:"id,omitempty"`

// SyncMode describes how a cluster sync resources from karmada control plane.
// SyncMode describes how a cluster syncs resources from karmada control plane.
// +required
SyncMode ClusterSyncMode

Expand All @@ -72,14 +72,14 @@ type ClusterSpec struct {
// +optional
APIEndpoint string

// SecretRef represents the secret contains mandatory credentials to access the member cluster.
// SecretRef represents the secret that contains mandatory credentials to access the member cluster.
// The secret should hold credentials as follows:
// - secret.data.token
// - secret.data.caBundle
// +optional
SecretRef *LocalSecretReference

// ImpersonatorSecretRef represents the secret contains the token of impersonator.
// ImpersonatorSecretRef represents the secret that contains the token of impersonator.
// The secret should hold credentials as follows:
// - secret.data.token
// +optional
Expand All @@ -94,12 +94,12 @@ type ClusterSpec struct {

// ProxyURL is the proxy URL for the cluster.
// If not empty, the karmada control plane will use this proxy to talk to the cluster.
// More details please refer to: https://github.com/kubernetes/client-go/issues/351
// For more details please refer to: https://github.com/kubernetes/client-go/issues/351
// +optional
ProxyURL string

// ProxyHeader is the HTTP header required by proxy server.
// The key in the key-value pair is HTTP header key and value is the associated header payloads.
// The key in the key-value pair is HTTP header key and the value is the associated header payloads.
// For the header with multiple values, the values should be separated by comma(e.g. 'k1': 'v1,v2,v3').
// +optional
ProxyHeader map[string]string
Expand All @@ -108,12 +108,12 @@ type ClusterSpec struct {
// +optional
Provider string

// Region represents the region of the member cluster locate in.
// Region represents the region in which the member cluster is located.
// +optional
Region string

// Zone represents the zone of the member cluster locate in.
// Deprecated: This filed was never been used by Karmada, and it will not be
// Zone represents the zone in which the member cluster is located.
// Deprecated: This field was never used by Karmada, and it will not be
// removed from v1alpha1 for backward compatibility, use Zones instead.
// +optional
Zone string
Expand All @@ -126,7 +126,7 @@ type ClusterSpec struct {
// +optional
Zones []string `json:"zones,omitempty"`

// Taints attached to the member cluster.
// Taints are attached to the member cluster.
// Taints on the cluster have the "effect" on
// any resource that does not tolerate the Taint.
// +optional
Expand Down Expand Up @@ -204,8 +204,8 @@ type ResourceModel struct {

// ResourceModelRange describes the detail of each modeling quota that ranges from min to max.
// Please pay attention, by default, the value of min can be inclusive, and the value of max cannot be inclusive.
// E.g. in an interval, min = 2, max =10 is set, which means the interval [2,10).
// This rule ensure that all intervals have the same meaning. If the last interval is infinite,
// E.g. in an interval, min = 2, max = 10 is set, which means the interval [2,10).
// This rule ensures that all intervals have the same meaning. If the last interval is infinite,
// it is definitely unreachable. Therefore, we define the right interval as the open interval.
// For a valid interval, the value on the right is greater than the value on the left,
// in other words, max must be greater than min.
Expand Down Expand Up @@ -242,13 +242,13 @@ const (
type ClusterSyncMode string

const (
// Push means that the controller on the karmada control plane will in charge of synchronization.
// The controller watches resources change on karmada control plane then pushes them to member cluster.
// Push means that the controller on the karmada control plane will be in charge of synchronization.
// The controller watches resources change on karmada control plane and then pushes them to member cluster.
Push ClusterSyncMode = "Push"

// Pull means that the controller running on the member cluster will in charge of synchronization.
// The controller, as well known as 'agent', watches resources change on karmada control plane then fetches them
// and applies locally on the member cluster.
// Pull means that the controller running on the member cluster will be in charge of synchronization.
// The controller, also known as 'agent', watches resources change on karmada control plane, then fetches them
// and applies them locally on the member cluster.
Pull ClusterSyncMode = "Pull"
)

Expand All @@ -258,7 +258,7 @@ type LocalSecretReference struct {
// Namespace is the namespace for the resource being referenced.
Namespace string

// Name is the name of resource being referenced.
// Name is the name of the resource being referenced.
Name string
}

Expand All @@ -267,7 +267,7 @@ const (
// ClusterConditionReady means the cluster is healthy and ready to accept workloads.
ClusterConditionReady = "Ready"

// ClusterConditionCompleteAPIEnablements indicates whether the cluster's API enablements(.status.apiEnablements) is complete.
// ClusterConditionCompleteAPIEnablements indicates whether the cluster's API enablements(.status.apiEnablements) are complete.
ClusterConditionCompleteAPIEnablements = "CompleteAPIEnablements"
)

Expand All @@ -278,7 +278,7 @@ type ClusterStatus struct {
// +optional
KubernetesVersion string

// APIEnablements represents the list of APIs installed in the member cluster.
// APIEnablements represents the list of APIs installed on the member cluster.
// +optional
APIEnablements []APIEnablement

Expand Down Expand Up @@ -369,7 +369,7 @@ type AllocatableModeling struct {

// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

// ClusterList contains a list of member cluster
// ClusterList contains a list of member clusters
type ClusterList struct {
metav1.TypeMeta
metav1.ListMeta
Expand Down
Loading

0 comments on commit 2f5dc4f

Please sign in to comment.