From 51e30e6ac3449134e2447b2746decead4192e07b Mon Sep 17 00:00:00 2001 From: heng4fun Date: Mon, 19 Feb 2024 09:33:56 +0800 Subject: [PATCH] chore: tidy up API docs (#6625) --- Makefile | 2 +- apis/apis.go | 17 + .../v1alpha1/backuppolicytemplate_types.go | 6 + apis/apps/v1alpha1/cluster_types.go | 15 +- apis/apps/v1alpha1/clusterdefinition_types.go | 32 +- .../v1alpha1/componentdefinition_types.go | 23 +- apis/apps/v1alpha1/doc.go | 2 - apis/apps/v1alpha1/opsdefinition_types.go | 6 + apis/apps/v1alpha1/opsrequest_types.go | 3 + apis/dataprotection/v1alpha1/backup_types.go | 3 + .../v1alpha1/backuppolicy_types.go | 2 + .../v1alpha1/backupschedule_types.go | 3 + apis/dataprotection/v1alpha1/doc.go | 2 - .../storage/v1alpha1/storageprovider_types.go | 8 + apis/workloads/v1alpha1/doc.go | 23 + .../v1alpha1/replicatedstatemachine_types.go | 6 +- ...s.kubeblocks.io_backuppolicytemplates.yaml | 40 +- ...apps.kubeblocks.io_clusterdefinitions.yaml | 36 +- .../bases/apps.kubeblocks.io_clusters.yaml | 34 +- ...ps.kubeblocks.io_componentdefinitions.yaml | 243 +- .../bases/apps.kubeblocks.io_components.yaml | 4 +- .../apps.kubeblocks.io_opsdefinitions.yaml | 28 +- .../bases/apps.kubeblocks.io_opsrequests.yaml | 8 +- ...otection.kubeblocks.io_backuppolicies.yaml | 14 +- .../dataprotection.kubeblocks.io_backups.yaml | 20 +- ...tection.kubeblocks.io_backupschedules.yaml | 6 +- ...torage.kubeblocks.io_storageproviders.yaml | 25 +- ...kubeblocks.io_replicatedstatemachines.yaml | 12 +- ...s.kubeblocks.io_backuppolicytemplates.yaml | 40 +- ...apps.kubeblocks.io_clusterdefinitions.yaml | 36 +- .../crds/apps.kubeblocks.io_clusters.yaml | 34 +- ...ps.kubeblocks.io_componentdefinitions.yaml | 243 +- .../crds/apps.kubeblocks.io_components.yaml | 4 +- .../apps.kubeblocks.io_opsdefinitions.yaml | 28 +- .../crds/apps.kubeblocks.io_opsrequests.yaml | 8 +- ...otection.kubeblocks.io_backuppolicies.yaml | 14 +- .../dataprotection.kubeblocks.io_backups.yaml | 20 +- ...tection.kubeblocks.io_backupschedules.yaml | 6 +- ...torage.kubeblocks.io_storageproviders.yaml | 25 +- ...kubeblocks.io_replicatedstatemachines.yaml | 12 +- docs/developer_docs/api-reference/add-on.md | 176 +- docs/developer_docs/api-reference/backup.md | 1187 +++-- docs/developer_docs/api-reference/cluster.md | 4326 +++++++++++++---- hack/docgen/api/gen-api-doc-config.json | 21 + hack/docgen/api/generate.sh | 27 - hack/docgen/api/main.go | 95 +- .../workloads/v1alpha1/workloads_client.go | 2 +- .../informers/externalversions/generic.go | 2 +- 48 files changed, 5054 insertions(+), 1875 deletions(-) create mode 100644 apis/apis.go create mode 100644 apis/workloads/v1alpha1/doc.go delete mode 100755 hack/docgen/api/generate.sh diff --git a/Makefile b/Makefile index 73424246ca9..7b03cd520b0 100644 --- a/Makefile +++ b/Makefile @@ -261,7 +261,7 @@ lorryctl-doc: generate test-go-generate ## generate CLI command reference manual .PHONY: api-doc api-doc: ## generate API reference manual. - @./hack/docgen/api/generate.sh + $(GO) run ./hack/docgen/api/main.go -api-dir github.com/apecloud/kubeblocks/apis -config ./hack/docgen/api/gen-api-doc-config.json -template-dir ./hack/docgen/api/template -out-dir ./docs/developer_docs/api-reference/ .PHONY: doc doc: lorryctl-doc api-doc ## generate all documents. diff --git a/apis/apis.go b/apis/apis.go new file mode 100644 index 00000000000..d375ebd9da4 --- /dev/null +++ b/apis/apis.go @@ -0,0 +1,17 @@ +/* +Copyright (C) 2022-2024 ApeCloud Co., Ltd + +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 apis diff --git a/apis/apps/v1alpha1/backuppolicytemplate_types.go b/apis/apps/v1alpha1/backuppolicytemplate_types.go index 9f3ac04faf6..1e49bed5332 100644 --- a/apis/apps/v1alpha1/backuppolicytemplate_types.go +++ b/apis/apps/v1alpha1/backuppolicytemplate_types.go @@ -136,12 +136,14 @@ type SchedulePolicy struct { // controller will remove all backups that are older than the RetentionPeriod. // For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. // Sample duration format: + // // - years: 2y // - months: 6mo // - days: 30d // - hours: 12h // - minutes: 30m // You can also combine the above durations. For example: 30d12h30m + // // +optional // +kubebuilder:default="7d" RetentionPeriod dpv1alpha1.RetentionPeriod `json:"retentionPeriod,omitempty"` @@ -149,8 +151,10 @@ type SchedulePolicy struct { type TargetInstance struct { // select instance of corresponding role for backup, role are: + // // - the name of Leader/Follower/Leaner for Consensus component. // - primary or secondary for Replication component. + // // finally, invalid role of the component will be ignored. // such as if workload type is Replication and component's replicas is 1, // the secondary role is invalid. and it also will be ignored when component is Stateful/Stateless. @@ -167,8 +171,10 @@ type TargetInstance struct { // PodSelectionStrategy specifies the strategy to select when multiple pods are // selected for backup target. // Valid values are: + // // - Any: select any one pod that match the labelsSelector. // - All: select all pods that match the labelsSelector. + // // +optional Strategy dpv1alpha1.PodSelectionStrategy `json:"strategy,omitempty"` diff --git a/apis/apps/v1alpha1/cluster_types.go b/apis/apps/v1alpha1/cluster_types.go index 6defd69fe81..7106b9f098a 100644 --- a/apis/apps/v1alpha1/cluster_types.go +++ b/apis/apps/v1alpha1/cluster_types.go @@ -138,12 +138,15 @@ type ClusterBackup struct { // controller will remove all backups that are older than the RetentionPeriod. // For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. // Sample duration format: + // // - years: 2y // - months: 6mo // - days: 30d // - hours: 12h // - minutes: 30m + // // You can also combine the above durations. For example: 30d12h30m + // // +kubebuilder:default="7d" // +optional RetentionPeriod dpv1alpha1.RetentionPeriod `json:"retentionPeriod,omitempty"` @@ -317,21 +320,21 @@ type ShardingSpec struct { // ClusterComponentSpec defines the cluster component spec. // +kubebuilder:validation:XValidation:rule="has(self.componentDefRef) || has(self.componentDef)",message="either componentDefRef or componentDef should be provided" -// //(TODO) +kubebuilder:validation:XValidation:rule="!has(oldSelf.componentDefRef) || has(self.componentDefRef)", message="componentDefRef is required once set" -// //(TODO) +kubebuilder:validation:XValidation:rule="!has(oldSelf.componentDef) || has(self.componentDef)", message="componentDef is required once set" +// TODO +kubebuilder:validation:XValidation:rule="!has(oldSelf.componentDefRef) || has(self.componentDefRef)", message="componentDefRef is required once set" +// TODO +kubebuilder:validation:XValidation:rule="!has(oldSelf.componentDef) || has(self.componentDef)", message="componentDef is required once set" type ClusterComponentSpec struct { // name defines cluster's component name, this name is also part of Service DNS name, so this name will comply with IANA Service Naming rule. // When ClusterComponentSpec is referenced as a template, name is optional. Otherwise, it is required. // +kubebuilder:validation:MaxLength=22 // +kubebuilder:validation:Pattern:=`^[a-z]([a-z0-9\-]*[a-z0-9])?$` - // //(TODO) +kubebuilder:validation:XValidation:rule="self == oldSelf",message="name is immutable" + // TODO +kubebuilder:validation:XValidation:rule="self == oldSelf",message="name is immutable" // +optional Name string `json:"name"` // componentDefRef references componentDef defined in ClusterDefinition spec. Need to comply with IANA Service Naming rule. // +kubebuilder:validation:MaxLength=22 // +kubebuilder:validation:Pattern:=`^[a-z]([a-z0-9\-]*[a-z0-9])?$` - // //(TODO) +kubebuilder:validation:XValidation:rule="self == oldSelf",message="componentDefRef is immutable" + // TODO +kubebuilder:validation:XValidation:rule="self == oldSelf",message="componentDefRef is immutable" // +optional ComponentDefRef string `json:"componentDefRef,omitempty"` @@ -339,7 +342,7 @@ type ClusterComponentSpec struct { // If both componentDefRef and componentDef are provided, the componentDef will take precedence over componentDefRef. // +kubebuilder:validation:MaxLength=22 // +kubebuilder:validation:Pattern:=`^[a-z0-9]([a-z0-9\.\-]*[a-z0-9])?$` - // //(TODO) +kubebuilder:validation:XValidation:rule="self == oldSelf",message="componentDef is immutable" + // TODO +kubebuilder:validation:XValidation:rule="self == oldSelf",message="componentDef is immutable" // +optional ComponentDef string `json:"componentDef,omitempty"` @@ -600,8 +603,10 @@ type TLSConfig struct { type Issuer struct { // Name of issuer. // Options supported: + // // - KubeBlocks - Certificates signed by KubeBlocks Operator. // - UserProvided - User provided own CA-signed certificates. + // // +kubebuilder:validation:Enum={KubeBlocks, UserProvided} // +kubebuilder:default=KubeBlocks // +kubebuilder:validation:Required diff --git a/apis/apps/v1alpha1/clusterdefinition_types.go b/apis/apps/v1alpha1/clusterdefinition_types.go index c88d03a5fc3..32ee76cb32e 100644 --- a/apis/apps/v1alpha1/clusterdefinition_types.go +++ b/apis/apps/v1alpha1/clusterdefinition_types.go @@ -49,18 +49,20 @@ type ClusterDefinitionSpec struct { // secret for cluster.apps.kubeblocks.io object. // // Built-in objects are: - // - `$(RANDOM_PASSWD)` - random 8 characters. - // - `$(STRONG_RANDOM_PASSWD)` - random 16 characters, with mixed cases, digits and symbols. - // - `$(UUID)` - generate a random UUID v4 string. - // - `$(UUID_B64)` - generate a random UUID v4 BASE64 encoded string. - // - `$(UUID_STR_B64)` - generate a random UUID v4 string then BASE64 encoded. - // - `$(UUID_HEX)` - generate a random UUID v4 HEX representation. - // - `$(HEADLESS_SVC_FQDN)` - headless service FQDN placeholder, value pattern - $(CLUSTER_NAME)-$(1ST_COMP_NAME)-headless.$(NAMESPACE).svc, + // + // - `$(RANDOM_PASSWD)` random 8 characters. + // dfjksgks + // - `$(STRONG_RANDOM_PASSWD)` random 16 characters, with mixed cases, digits and symbols. + // - `$(UUID)` generate a random UUID v4 string. + // - `$(UUID_B64)` generate a random UUID v4 BASE64 encoded string. + // - `$(UUID_STR_B64)` generate a random UUID v4 string then BASE64 encoded. + // - `$(UUID_HEX)` generate a random UUID v4 HEX representation. + // - `$(HEADLESS_SVC_FQDN)` headless service FQDN placeholder, value pattern is `$(CLUSTER_NAME)-$(1ST_COMP_NAME)-headless.$(NAMESPACE).svc`, // where 1ST_COMP_NAME is the 1st component that provide `ClusterDefinition.spec.componentDefs[].service` attribute; - // - `$(SVC_FQDN)` - service FQDN placeholder, value pattern - $(CLUSTER_NAME)-$(1ST_COMP_NAME).$(NAMESPACE).svc, + // - `$(SVC_FQDN)` service FQDN placeholder, value pattern is `$(CLUSTER_NAME)-$(1ST_COMP_NAME).$(NAMESPACE).svc`, // where 1ST_COMP_NAME is the 1st component that provide `ClusterDefinition.spec.componentDefs[].service` attribute; - // - `$(SVC_PORT_{PORT-NAME})` - a ServicePort's port value with specified port name, i.e, a servicePort JSON struct: - // `{"name": "mysql", "targetPort": "mysqlContainerPort", "port": 3306}`, and "$(SVC_PORT_mysql)" in the + // - `$(SVC_PORT_{PORT-NAME})` is ServicePort's port value with specified port name, i.e, a servicePort JSON struct: + // `{"name": "mysql", "targetPort": "mysqlContainerPort", "port": 3306}`, and `$(SVC_PORT_mysql)` in the // connection credential value is 3306. // +optional ConnectionCredential map[string]string `json:"connectionCredential,omitempty"` @@ -388,22 +390,22 @@ type ClusterComponentDefinition struct { // statelessSpec defines stateless related spec if workloadType is Stateless. // +optional - //+kubebuilder:deprecatedversion:warning="This field is deprecated from KB 0.7.0, use RSMSpec instead." + // +kubebuilder:deprecatedversion:warning="This field is deprecated from KB 0.7.0, use RSMSpec instead." StatelessSpec *StatelessSetSpec `json:"statelessSpec,omitempty"` // statefulSpec defines stateful related spec if workloadType is Stateful. // +optional - //+kubebuilder:deprecatedversion:warning="This field is deprecated from KB 0.7.0, use RSMSpec instead." + // +kubebuilder:deprecatedversion:warning="This field is deprecated from KB 0.7.0, use RSMSpec instead." StatefulSpec *StatefulSetSpec `json:"statefulSpec,omitempty"` // consensusSpec defines consensus related spec if workloadType is Consensus, required if workloadType is Consensus. // +optional - //+kubebuilder:deprecatedversion:warning="This field is deprecated from KB 0.7.0, use RSMSpec instead." + // +kubebuilder:deprecatedversion:warning="This field is deprecated from KB 0.7.0, use RSMSpec instead." ConsensusSpec *ConsensusSetSpec `json:"consensusSpec,omitempty"` // replicationSpec defines replication related spec if workloadType is Replication. // +optional - //+kubebuilder:deprecatedversion:warning="This field is deprecated from KB 0.7.0, use RSMSpec instead." + // +kubebuilder:deprecatedversion:warning="This field is deprecated from KB 0.7.0, use RSMSpec instead." ReplicationSpec *ReplicationSetSpec `json:"replicationSpec,omitempty"` // RSMSpec defines workload related spec of this component. @@ -653,7 +655,7 @@ type ClusterDefinitionProbes struct { // Probe for DB role changed check. // +optional - //+kubebuilder:deprecatedversion:warning="This field is deprecated from KB 0.7.0, use RSMSpec instead." + // +kubebuilder:deprecatedversion:warning="This field is deprecated from KB 0.7.0, use RSMSpec instead." RoleProbe *ClusterDefinitionProbe `json:"roleProbe,omitempty"` // roleProbeTimeoutAfterPodsReady(in seconds), when all pods of the component are ready, diff --git a/apis/apps/v1alpha1/componentdefinition_types.go b/apis/apps/v1alpha1/componentdefinition_types.go index 3400f0c92d1..1a2fb8f969e 100644 --- a/apis/apps/v1alpha1/componentdefinition_types.go +++ b/apis/apps/v1alpha1/componentdefinition_types.go @@ -45,7 +45,7 @@ type ComponentDefinition struct { Status ComponentDefinitionStatus `json:"status,omitempty"` } -//+kubebuilder:object:root=true +// +kubebuilder:object:root=true // ComponentDefinitionList contains a list of ComponentDefinition type ComponentDefinitionList struct { @@ -482,13 +482,15 @@ type Action struct { RetryPolicy *RetryPolicy `json:"retryPolicy,omitempty"` // PreCondition defines the condition when the action will be executed. + // // - Immediately: The Action is executed immediately after the Component object is created, - // without guaranteeing the availability of the Component and its underlying resources. only after the action is successfully executed will the Component's state turn to ready. + // without guaranteeing the availability of the Component and its underlying resources. only after the action is successfully executed will the Component's state turn to ready. // - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. - // only after the action is successfully executed will the Component's state turn to ready. + // only after the action is successfully executed will the Component's state turn to ready. // - ComponentReady: The Action is executed after the Component object is created and once the Component is ready. - // the execution process does not impact the state of the Component and the Cluster. + // the execution process does not impact the state of the Component and the Cluster. // - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster is ready. + // // the execution process does not impact the state of the Component and the Cluster. // Cannot be updated. // +optional @@ -531,12 +533,15 @@ type ComponentLifecycleActions struct { // You can define the preCondition for executing PostProvision using Action.PreCondition. The default PostProvision action preCondition is ComponentReady. // The PostProvision Action will be executed only once. // Dedicated env vars for the action: + // // - KB_CLUSTER_COMPONENT_LIST: The list of all components in the cluster, joined by ',' (e.g., "comp1,comp2"). // - KB_CLUSTER_COMPONENT_POD_NAME_LIST: The list of all pods name in this component, joined by ',' (e.g., "pod1,pod2"). // - KB_CLUSTER_COMPONENT_POD_IP_LIST: The list of pod IPs where each pod resides in this component, corresponding one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. joined by ',' (e.g., "podIp1,podIp2"). // - KB_CLUSTER_COMPONENT_POD_HOST_NAME_LIST: The list of hostName where each pod resides in this component, corresponding one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. joined by ',' (e.g., "hostName1,hostName2"). // - KB_CLUSTER_COMPONENT_POD_HOST_IP_LIST: The list of host IPs where each pod resides in this component, corresponding one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. joined by ',' (e.g., "hostIp1,hostIp2"). + // // Cannot be updated. + // // +optional PostProvision *LifecycleActionHandler `json:"postProvision,omitempty"` @@ -554,20 +559,27 @@ type ComponentLifecycleActions struct { // Switchover defines how to proactively switch the current leader to a new replica to minimize the impact on availability. // This action is typically invoked when the leader is about to become unavailable due to events, such as: + // // - switchover // - stop // - restart // - scale-in + // // Dedicated env vars for the action: + // // - KB_SWITCHOVER_CANDIDATE_NAME: The name of the new candidate replica's Pod. It may be empty. // - KB_SWITCHOVER_CANDIDATE_FQDN: The FQDN of the new candidate replica. It may be empty. // - KB_LEADER_POD_IP: The IP address of the original leader's Pod before switchover. // - KB_LEADER_POD_NAME: The name of the original leader's Pod before switchover. // - KB_LEADER_POD_FQDN: The FQDN of the original leader's Pod before switchover. + // // The env vars with following prefix are deprecated and will be removed in the future: + // // - KB_REPLICATION_PRIMARY_POD_: The prefix of the environment variables of the original primary's Pod before switchover. // - KB_CONSENSUS_LEADER_POD_: The prefix of the environment variables of the original leader's Pod before switchover. + // // Cannot be updated. + // // +optional Switchover *ComponentSwitchover `json:"switchover,omitempty"` @@ -599,11 +611,14 @@ type ComponentLifecycleActions struct { // DataPopulate defines how to populate the data to create new replicas. // This action is typically used when a new replica needs to be constructed, such as: + // // - scale-out // - rebuild // - clone + // // It should write the valid data to stdout without including any extraneous information. // Cannot be updated. + // // +optional DataPopulate *LifecycleActionHandler `json:"dataPopulate,omitempty"` diff --git a/apis/apps/v1alpha1/doc.go b/apis/apps/v1alpha1/doc.go index c48dc169c76..04a076d65b4 100644 --- a/apis/apps/v1alpha1/doc.go +++ b/apis/apps/v1alpha1/doc.go @@ -17,8 +17,6 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -//go:generate go run ../../../hack/docgen/api/main.go -api-dir . -config ../../../hack/docgen/api/gen-api-doc-config.json -template-dir ../../../hack/docgen/api/template -out-file ../../../docs/developer_docs/api-reference/cluster.md - // +k8s:deepcopy-gen=package,register // +k8s:openapi-gen=true // +groupName=apps.kubeblocks.io diff --git a/apis/apps/v1alpha1/opsdefinition_types.go b/apis/apps/v1alpha1/opsdefinition_types.go index 208f7ed7e59..ee543b642c2 100644 --- a/apis/apps/v1alpha1/opsdefinition_types.go +++ b/apis/apps/v1alpha1/opsdefinition_types.go @@ -83,10 +83,12 @@ type ComponentDefinitionRef struct { type ParametersSchema struct { // openAPIV3Schema is the OpenAPI v3 schema to use for parameter schema. // supported properties types: + // // - string // - number // - integer // - array: only supported the item with string type. + // // +kubebuilder:validation:Schemaless // +kubebuilder:validation:Type=object // +kubebuilder:pruning:PreserveUnknownFields @@ -97,8 +99,10 @@ type ParametersSchema struct { type VarsRef struct { // podSelectionStrategy how to select the target component pod for variable references based on the strategy. + // // - PreferredAvailable: prioritize the selection of available pod. // - Available: only select available pod. if not found, terminating the operation. + // // +kubebuilder:validation:Required // +kubebuilder:default=PreferredAvailable PodSelectionStrategy PodSelectionStrategy `json:"podSelectionStrategy"` @@ -152,9 +156,11 @@ type PreCondition struct { type Rule struct { // expression declares how the operation can be executed using go template expression. // it should return "true" or "false", built-in objects: + // // - "params" are input parameters. // - "cluster" is referenced cluster object. // - "component" is referenced the component Object. + // // +kubebuilder:validation:Required Expression string `json:"expression"` diff --git a/apis/apps/v1alpha1/opsrequest_types.go b/apis/apps/v1alpha1/opsrequest_types.go index 41882908680..8030e0c504e 100644 --- a/apis/apps/v1alpha1/opsrequest_types.go +++ b/apis/apps/v1alpha1/opsrequest_types.go @@ -518,13 +518,16 @@ type BackupSpec struct { // Controller will remove all backups that are older than the RetentionPeriod. // For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. // Sample duration format: + // // - years: 2y // - months: 6mo // - days: 30d // - hours: 12h // - minutes: 30m + // // You can also combine the above durations. For example: 30d12h30m. // If not set, the backup will be kept forever. + // // +optional RetentionPeriod string `json:"retentionPeriod,omitempty"` diff --git a/apis/dataprotection/v1alpha1/backup_types.go b/apis/dataprotection/v1alpha1/backup_types.go index c728b31caf5..63f37419362 100644 --- a/apis/dataprotection/v1alpha1/backup_types.go +++ b/apis/dataprotection/v1alpha1/backup_types.go @@ -51,13 +51,16 @@ type BackupSpec struct { // Controller will remove all backups that are older than the RetentionPeriod. // For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. // Sample duration format: + // // - years: 2y // - months: 6mo // - days: 30d // - hours: 12h // - minutes: 30m + // // You can also combine the above durations. For example: 30d12h30m. // If not set, the backup will be kept forever. + // // +optional RetentionPeriod RetentionPeriod `json:"retentionPeriod,omitempty"` diff --git a/apis/dataprotection/v1alpha1/backuppolicy_types.go b/apis/dataprotection/v1alpha1/backuppolicy_types.go index ed5b82fbc7a..f1ac827b20d 100644 --- a/apis/dataprotection/v1alpha1/backuppolicy_types.go +++ b/apis/dataprotection/v1alpha1/backuppolicy_types.go @@ -88,8 +88,10 @@ type PodSelector struct { // strategy specifies the strategy to select the target pod when multiple pods // are selected. // Valid values are: + // // - Any: select any one pod that match the labelsSelector. // - All: select all pods that match the labelsSelector. + // // +kubebuilder:default=Any Strategy PodSelectionStrategy `json:"strategy,omitempty"` } diff --git a/apis/dataprotection/v1alpha1/backupschedule_types.go b/apis/dataprotection/v1alpha1/backupschedule_types.go index 88ad3b37d02..3a01039cc89 100644 --- a/apis/dataprotection/v1alpha1/backupschedule_types.go +++ b/apis/dataprotection/v1alpha1/backupschedule_types.go @@ -58,12 +58,15 @@ type SchedulePolicy struct { // controller will remove all backups that are older than the RetentionPeriod. // For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. // Sample duration format: + // // - years: 2y // - months: 6mo // - days: 30d // - hours: 12h // - minutes: 30m + // // You can also combine the above durations. For example: 30d12h30m + // // +optional // +kubebuilder:default="7d" RetentionPeriod RetentionPeriod `json:"retentionPeriod,omitempty"` diff --git a/apis/dataprotection/v1alpha1/doc.go b/apis/dataprotection/v1alpha1/doc.go index f84c24f9df5..6f53d292262 100644 --- a/apis/dataprotection/v1alpha1/doc.go +++ b/apis/dataprotection/v1alpha1/doc.go @@ -17,8 +17,6 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -//go:generate go run ../../../hack/docgen/api/main.go -api-dir . -config ../../../hack/docgen/api/gen-api-doc-config.json -template-dir ../../../hack/docgen/api/template -out-file ../../../docs/developer_docs/api-reference/backup.md - // +k8s:deepcopy-gen=package,register // +k8s:openapi-gen=true // +groupName=dataprotection.kubeblocks.io diff --git a/apis/storage/v1alpha1/storageprovider_types.go b/apis/storage/v1alpha1/storageprovider_types.go index a8f65f93c70..9c929887578 100644 --- a/apis/storage/v1alpha1/storageprovider_types.go +++ b/apis/storage/v1alpha1/storageprovider_types.go @@ -29,27 +29,35 @@ type StorageProviderSpec struct { // A Go template for rendering a secret which will be used by the CSI driver. // The template will be rendered with the following variables: + // // - Parameters: a map of parameters defined in the ParametersSchema. + // // +optional CSIDriverSecretTemplate string `json:"csiDriverSecretTemplate,omitempty"` // A Go template for rendering a storage class which will be used by the CSI driver. // The template will be rendered with the following variables: + // // - Parameters: a map of parameters defined in the ParametersSchema. // - CSIDriverSecretRef: the reference of the secret created by the CSIDriverSecretTemplate. + // // +optional StorageClassTemplate string `json:"storageClassTemplate,omitempty"` // A Go template for rendering a PersistentVolumeClaim. // The template will be rendered with the following variables: + // // - Parameters: a map of parameters defined in the ParametersSchema. // - GeneratedStorageClassName: the name of the storage class generated with the StorageClassTemplate. + // // +optional PersistentVolumeClaimTemplate string `json:"persistentVolumeClaimTemplate,omitempty"` // A Go template for rendering a config used by the datasafed command. // The template will be rendered with the following variables: + // // - Parameters: a map of parameters defined in the ParametersSchema. + // // +optional DatasafedConfigTemplate string `json:"datasafedConfigTemplate,omitempty"` diff --git a/apis/workloads/v1alpha1/doc.go b/apis/workloads/v1alpha1/doc.go new file mode 100644 index 00000000000..de3f055433e --- /dev/null +++ b/apis/workloads/v1alpha1/doc.go @@ -0,0 +1,23 @@ +/* +Copyright (C) 2022-2024 ApeCloud Co., Ltd + +This file is part of KubeBlocks project + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU Affero General Public License as published by +the Free Software Foundation, either version 3 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Affero General Public License for more details. + +You should have received a copy of the GNU Affero General Public License +along with this program. If not, see . +*/ + +// +k8s:deepcopy-gen=package,register +// +k8s:openapi-gen=true +// +groupName=workloads.kubeblocks.io +package v1alpha1 diff --git a/apis/workloads/v1alpha1/replicatedstatemachine_types.go b/apis/workloads/v1alpha1/replicatedstatemachine_types.go index 8e094749e0d..35c674166a4 100644 --- a/apis/workloads/v1alpha1/replicatedstatemachine_types.go +++ b/apis/workloads/v1alpha1/replicatedstatemachine_types.go @@ -291,9 +291,11 @@ type RoleProbe struct { // after all actions done, the final output should be a single string of the role name defined in spec.Roles // latest [BusyBox](https://busybox.net/) image will be used if Image not configured // Environment variables can be used in Command: + // // - v_KB_RSM_LAST_STDOUT stdout from last action, watch 'v_' prefixed // - KB_RSM_USERNAME username part of credential // - KB_RSM_PASSWORD password part of credential + // // +optional CustomHandler []Action `json:"customHandler,omitempty"` @@ -372,14 +374,16 @@ type CredentialVar struct { type MembershipReconfiguration struct { // Environment variables can be used in all following Actions: + // // - KB_RSM_USERNAME username part of credential // - KB_RSM_PASSWORD password part of credential // - KB_RSM_LEADER_HOST leader host // - KB_RSM_TARGET_HOST target host // - KB_RSM_SERVICE_PORT port - + // // SwitchoverAction specifies how to do switchover // latest [BusyBox](https://busybox.net/) image will be used if Image not configured + // // +optional SwitchoverAction *Action `json:"switchoverAction,omitempty"` diff --git a/config/crd/bases/apps.kubeblocks.io_backuppolicytemplates.yaml b/config/crd/bases/apps.kubeblocks.io_backuppolicytemplates.yaml index c999bda7864..acd3191ed4d 100644 --- a/config/crd/bases/apps.kubeblocks.io_backuppolicytemplates.yaml +++ b/config/crd/bases/apps.kubeblocks.io_backuppolicytemplates.yaml @@ -440,11 +440,11 @@ spec: type: object strategy: default: Any - description: 'strategy specifies the strategy + description: "strategy specifies the strategy to select the target pod when multiple pods - are selected. Valid values are: - Any: select + are selected. Valid values are: \n - Any: select any one pod that match the labelsSelector. - - All: select all pods that match the labelsSelector.' + All: select all pods that match the labelsSelector." enum: - Any - All @@ -528,27 +528,27 @@ spec: x-kubernetes-map-type: atomic type: object role: - description: 'select instance of corresponding role - for backup, role are: - the name of Leader/Follower/Leaner + description: "select instance of corresponding role + for backup, role are: \n - the name of Leader/Follower/Leaner for Consensus component. - primary or secondary - for Replication component. finally, invalid role + for Replication component. \n finally, invalid role of the component will be ignored. such as if workload - type is Replication and component''s replicas is + type is Replication and component's replicas is 1, the secondary role is invalid. and it also will be ignored when component is Stateful/Stateless. the role will be transformed to a role LabelSelector - for BackupPolicy''s target attribute.' + for BackupPolicy's target attribute." type: string serviceAccountName: description: serviceAccountName specifies the service account to run the backup workload. type: string strategy: - description: 'PodSelectionStrategy specifies the strategy + description: "PodSelectionStrategy specifies the strategy to select when multiple pods are selected for backup - target. Valid values are: - Any: select any one + target. Valid values are: \n - Any: select any one pod that match the labelsSelector. - All: select - all pods that match the labelsSelector.' + all pods that match the labelsSelector." enum: - Any - All @@ -653,7 +653,7 @@ spec: remove all backups that are older than the RetentionPeriod. For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. Sample duration format: - - years: \t2y - months: \t6mo - days: \t\t30d - hours: + \n - years: \t2y - months: \t6mo - days: \t\t30d - hours: \t12h - minutes: \t30m You can also combine the above durations. For example: 30d12h30m" type: string @@ -697,22 +697,22 @@ spec: type: string type: object role: - description: 'select instance of corresponding role for - backup, role are: - the name of Leader/Follower/Leaner + description: "select instance of corresponding role for + backup, role are: \n - the name of Leader/Follower/Leaner for Consensus component. - primary or secondary for Replication - component. finally, invalid role of the component will + component. \n finally, invalid role of the component will be ignored. such as if workload type is Replication and - component''s replicas is 1, the secondary role is invalid. + component's replicas is 1, the secondary role is invalid. and it also will be ignored when component is Stateful/Stateless. the role will be transformed to a role LabelSelector for - BackupPolicy''s target attribute.' + BackupPolicy's target attribute." type: string strategy: - description: 'PodSelectionStrategy specifies the strategy + description: "PodSelectionStrategy specifies the strategy to select when multiple pods are selected for backup target. - Valid values are: - Any: select any one pod that match + Valid values are: \n - Any: select any one pod that match the labelsSelector. - All: select all pods that match - the labelsSelector.' + the labelsSelector." enum: - Any - All diff --git a/config/crd/bases/apps.kubeblocks.io_clusterdefinitions.yaml b/config/crd/bases/apps.kubeblocks.io_clusterdefinitions.yaml index 7035c7dfe5e..92cdd92462f 100644 --- a/config/crd/bases/apps.kubeblocks.io_clusterdefinitions.yaml +++ b/config/crd/bases/apps.kubeblocks.io_clusterdefinitions.yaml @@ -8808,9 +8808,13 @@ spec: - command type: object switchoverAction: - description: SwitchoverAction specifies how to do switchover - latest [BusyBox](https://busybox.net/) image will - be used if Image not configured + description: "Environment variables can be used in all + following Actions: \n - KB_RSM_USERNAME username part + of credential - KB_RSM_PASSWORD password part of credential + - KB_RSM_LEADER_HOST leader host - KB_RSM_TARGET_HOST + target host - KB_RSM_SERVICE_PORT port \n SwitchoverAction + specifies how to do switchover latest [BusyBox](https://busybox.net/) + image will be used if Image not configured" properties: args: description: Args is used to perform statements. @@ -8851,7 +8855,7 @@ spec: string of the role name defined in spec.Roles latest [BusyBox](https://busybox.net/) image will be used if Image not configured Environment variables can - be used in Command: - v_KB_RSM_LAST_STDOUT stdout + be used in Command: \n - v_KB_RSM_LAST_STDOUT stdout from last action, watch 'v_' prefixed - KB_RSM_USERNAME username part of credential - KB_RSM_PASSWORD password part of credential" @@ -9992,22 +9996,22 @@ spec: type: string description: "Connection credential template used for creating a connection credential secret for cluster.apps.kubeblocks.io object. \n Built-in - objects are: - `$(RANDOM_PASSWD)` - random 8 characters. - `$(STRONG_RANDOM_PASSWD)` - - random 16 characters, with mixed cases, digits and symbols. - - `$(UUID)` - generate a random UUID v4 string. - `$(UUID_B64)` - - generate a random UUID v4 BASE64 encoded string. - `$(UUID_STR_B64)` - - generate a random UUID v4 string then BASE64 encoded. - `$(UUID_HEX)` - - generate a random UUID v4 HEX representation. - `$(HEADLESS_SVC_FQDN)` - - headless service FQDN placeholder, value pattern - $(CLUSTER_NAME)-$(1ST_COMP_NAME)-headless.$(NAMESPACE).svc, + objects are: \n - `$(RANDOM_PASSWD)` random 8 characters. dfjksgks + - `$(STRONG_RANDOM_PASSWD)` random 16 characters, with mixed cases, + digits and symbols. - `$(UUID)` generate a random UUID v4 string. + - `$(UUID_B64)` generate a random UUID v4 BASE64 encoded string. + - `$(UUID_STR_B64)` generate a random UUID v4 string then BASE64 + encoded. - `$(UUID_HEX)` generate a random UUID v4 HEX representation. + - `$(HEADLESS_SVC_FQDN)` headless service FQDN placeholder, value + pattern is `$(CLUSTER_NAME)-$(1ST_COMP_NAME)-headless.$(NAMESPACE).svc`, where 1ST_COMP_NAME is the 1st component that provide `ClusterDefinition.spec.componentDefs[].service` - attribute; - `$(SVC_FQDN)` - service FQDN placeholder, value pattern - - $(CLUSTER_NAME)-$(1ST_COMP_NAME).$(NAMESPACE).svc, where 1ST_COMP_NAME + attribute; - `$(SVC_FQDN)` service FQDN placeholder, value pattern + is `$(CLUSTER_NAME)-$(1ST_COMP_NAME).$(NAMESPACE).svc`, where 1ST_COMP_NAME is the 1st component that provide `ClusterDefinition.spec.componentDefs[].service` - attribute; - `$(SVC_PORT_{PORT-NAME})` - a ServicePort's port value + attribute; - `$(SVC_PORT_{PORT-NAME})` is ServicePort's port value with specified port name, i.e, a servicePort JSON struct: `{\"name\": \"mysql\", \"targetPort\": \"mysqlContainerPort\", \"port\": 3306}`, - and \"$(SVC_PORT_mysql)\" in the connection credential value is - 3306." + and `$(SVC_PORT_mysql)` in the connection credential value is 3306." type: object type: description: Cluster definition type defines well known application diff --git a/config/crd/bases/apps.kubeblocks.io_clusters.yaml b/config/crd/bases/apps.kubeblocks.io_clusters.yaml index ae09ba34d02..c987eca3040 100644 --- a/config/crd/bases/apps.kubeblocks.io_clusters.yaml +++ b/config/crd/bases/apps.kubeblocks.io_clusters.yaml @@ -135,9 +135,9 @@ spec: the backup should be kept. controller will remove all backups that are older than the RetentionPeriod. For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. Sample - duration format: - years: \t2y - months: \t6mo - days: \t\t30d - - hours: \t12h - minutes: \t30m You can also combine the above - durations. For example: 30d12h30m" + duration format: \n - years: \t2y - months: \t6mo - days: \t\t30d + - hours: \t12h - minutes: \t30m \n You can also combine the + above durations. For example: 30d12h30m" type: string startingDeadlineMinutes: description: startingDeadlineMinutes defines the deadline in minutes @@ -169,9 +169,9 @@ spec: both be empty at the same time. items: description: ClusterComponentSpec defines the cluster component - spec. //(TODO) +kubebuilder:validation:XValidation:rule="!has(oldSelf.componentDefRef) + spec. TODO +kubebuilder:validation:XValidation:rule="!has(oldSelf.componentDefRef) || has(self.componentDefRef)", message="componentDefRef is required - once set" //(TODO) +kubebuilder:validation:XValidation:rule="!has(oldSelf.componentDef) + once set" TODO +kubebuilder:validation:XValidation:rule="!has(oldSelf.componentDef) || has(self.componentDef)", message="componentDef is required once set" properties: @@ -235,7 +235,7 @@ spec: componentDef: description: componentDef references the name of the ComponentDefinition. If both componentDefRef and componentDef are provided, the - componentDef will take precedence over componentDefRef. //(TODO) + componentDef will take precedence over componentDefRef. TODO +kubebuilder:validation:XValidation:rule="self == oldSelf",message="componentDef is immutable" maxLength: 22 @@ -244,7 +244,7 @@ spec: componentDefRef: description: componentDefRef references componentDef defined in ClusterDefinition spec. Need to comply with IANA Service - Naming rule. //(TODO) +kubebuilder:validation:XValidation:rule="self + Naming rule. TODO +kubebuilder:validation:XValidation:rule="self == oldSelf",message="componentDefRef is immutable" maxLength: 22 pattern: ^[a-z]([a-z0-9\-]*[a-z0-9])?$ @@ -271,9 +271,9 @@ spec: properties: name: default: KubeBlocks - description: 'Name of issuer. Options supported: - KubeBlocks + description: "Name of issuer. Options supported: \n - KubeBlocks - Certificates signed by KubeBlocks Operator. - UserProvided - - User provided own CA-signed certificates.' + - User provided own CA-signed certificates." enum: - KubeBlocks - UserProvided @@ -316,7 +316,7 @@ spec: is also part of Service DNS name, so this name will comply with IANA Service Naming rule. When ClusterComponentSpec is referenced as a template, name is optional. Otherwise, it - is required. //(TODO) +kubebuilder:validation:XValidation:rule="self + is required. TODO +kubebuilder:validation:XValidation:rule="self == oldSelf",message="name is immutable" maxLength: 22 pattern: ^[a-z]([a-z0-9\-]*[a-z0-9])?$ @@ -1494,15 +1494,15 @@ spec: description: componentDef references the name of the ComponentDefinition. If both componentDefRef and componentDef are provided, the componentDef will take precedence over componentDefRef. - //(TODO) +kubebuilder:validation:XValidation:rule="self - == oldSelf",message="componentDef is immutable" + TODO +kubebuilder:validation:XValidation:rule="self == + oldSelf",message="componentDef is immutable" maxLength: 22 pattern: ^[a-z0-9]([a-z0-9\.\-]*[a-z0-9])?$ type: string componentDefRef: description: componentDefRef references componentDef defined in ClusterDefinition spec. Need to comply with IANA Service - Naming rule. //(TODO) +kubebuilder:validation:XValidation:rule="self + Naming rule. TODO +kubebuilder:validation:XValidation:rule="self == oldSelf",message="componentDefRef is immutable" maxLength: 22 pattern: ^[a-z]([a-z0-9\-]*[a-z0-9])?$ @@ -1530,9 +1530,9 @@ spec: properties: name: default: KubeBlocks - description: 'Name of issuer. Options supported: - KubeBlocks - - Certificates signed by KubeBlocks Operator. - UserProvided - - User provided own CA-signed certificates.' + description: "Name of issuer. Options supported: \n + - KubeBlocks - Certificates signed by KubeBlocks Operator. + - UserProvided - User provided own CA-signed certificates." enum: - KubeBlocks - UserProvided @@ -1575,7 +1575,7 @@ spec: name is also part of Service DNS name, so this name will comply with IANA Service Naming rule. When ClusterComponentSpec is referenced as a template, name is optional. Otherwise, - it is required. //(TODO) +kubebuilder:validation:XValidation:rule="self + it is required. TODO +kubebuilder:validation:XValidation:rule="self == oldSelf",message="name is immutable" maxLength: 22 pattern: ^[a-z]([a-z0-9\-]*[a-z0-9])?$ diff --git a/config/crd/bases/apps.kubeblocks.io_componentdefinitions.yaml b/config/crd/bases/apps.kubeblocks.io_componentdefinitions.yaml index a50c219c40b..0c715615608 100644 --- a/config/crd/bases/apps.kubeblocks.io_componentdefinitions.yaml +++ b/config/crd/bases/apps.kubeblocks.io_componentdefinitions.yaml @@ -408,23 +408,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -695,23 +695,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -749,11 +749,11 @@ spec: type: object type: object dataPopulate: - description: 'DataPopulate defines how to populate the data to + description: "DataPopulate defines how to populate the data to create new replicas. This action is typically used when a new - replica needs to be constructed, such as: - scale-out - rebuild - - clone It should write the valid data to stdout without including - any extraneous information. Cannot be updated.' + replica needs to be constructed, such as: \n - scale-out - rebuild + - clone \n It should write the valid data to stdout without + including any extraneous information. Cannot be updated." properties: builtinHandler: description: builtinHandler specifies the builtin action handler @@ -980,23 +980,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -1265,23 +1265,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -1551,23 +1551,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -1605,25 +1605,25 @@ spec: type: object type: object postProvision: - description: 'PostProvision defines the actions to be executed + description: "PostProvision defines the actions to be executed and the corresponding policy when a component is created. You can define the preCondition for executing PostProvision using Action.PreCondition. The default PostProvision action preCondition is ComponentReady. The PostProvision Action will be executed - only once. Dedicated env vars for the action: - KB_CLUSTER_COMPONENT_LIST: - The list of all components in the cluster, joined by '','' (e.g., - "comp1,comp2"). - KB_CLUSTER_COMPONENT_POD_NAME_LIST: The list - of all pods name in this component, joined by '','' (e.g., "pod1,pod2"). - - KB_CLUSTER_COMPONENT_POD_IP_LIST: The list of pod IPs where - each pod resides in this component, corresponding one-to-one - with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. joined - by '','' (e.g., "podIp1,podIp2"). - KB_CLUSTER_COMPONENT_POD_HOST_NAME_LIST: + only once. Dedicated env vars for the action: \n - KB_CLUSTER_COMPONENT_LIST: + The list of all components in the cluster, joined by ',' (e.g., + \"comp1,comp2\"). - KB_CLUSTER_COMPONENT_POD_NAME_LIST: The + list of all pods name in this component, joined by ',' (e.g., + \"pod1,pod2\"). - KB_CLUSTER_COMPONENT_POD_IP_LIST: The list + of pod IPs where each pod resides in this component, corresponding + one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. + joined by ',' (e.g., \"podIp1,podIp2\"). - KB_CLUSTER_COMPONENT_POD_HOST_NAME_LIST: The list of hostName where each pod resides in this component, corresponding one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. - joined by '','' (e.g., "hostName1,hostName2"). - KB_CLUSTER_COMPONENT_POD_HOST_IP_LIST: + joined by ',' (e.g., \"hostName1,hostName2\"). - KB_CLUSTER_COMPONENT_POD_HOST_IP_LIST: The list of host IPs where each pod resides in this component, corresponding one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. - joined by '','' (e.g., "hostIp1,hostIp2"). Cannot be updated.' + joined by ',' (e.g., \"hostIp1,hostIp2\"). \n Cannot be updated." properties: builtinHandler: description: builtinHandler specifies the builtin action handler @@ -1850,23 +1850,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -2137,23 +2137,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -2420,23 +2420,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -2702,23 +2702,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -2984,23 +2984,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -3266,23 +3266,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -3366,23 +3366,24 @@ spec: type: integer type: object switchover: - description: 'Switchover defines how to proactively switch the + description: "Switchover defines how to proactively switch the current leader to a new replica to minimize the impact on availability. This action is typically invoked when the leader is about to - become unavailable due to events, such as: - switchover - stop - - restart - scale-in Dedicated env vars for the action: - KB_SWITCHOVER_CANDIDATE_NAME: - The name of the new candidate replica''s Pod. It may be empty. - - KB_SWITCHOVER_CANDIDATE_FQDN: The FQDN of the new candidate - replica. It may be empty. - KB_LEADER_POD_IP: The IP address - of the original leader''s Pod before switchover. - KB_LEADER_POD_NAME: - The name of the original leader''s Pod before switchover. - - KB_LEADER_POD_FQDN: The FQDN of the original leader''s Pod before - switchover. The env vars with following prefix are deprecated - and will be removed in the future: - KB_REPLICATION_PRIMARY_POD_: - The prefix of the environment variables of the original primary''s - Pod before switchover. - KB_CONSENSUS_LEADER_POD_: The prefix - of the environment variables of the original leader''s Pod before - switchover. Cannot be updated.' + become unavailable due to events, such as: \n - switchover - + stop - restart - scale-in \n Dedicated env vars for the action: + \n - KB_SWITCHOVER_CANDIDATE_NAME: The name of the new candidate + replica's Pod. It may be empty. - KB_SWITCHOVER_CANDIDATE_FQDN: + The FQDN of the new candidate replica. It may be empty. - KB_LEADER_POD_IP: + The IP address of the original leader's Pod before switchover. + - KB_LEADER_POD_NAME: The name of the original leader's Pod + before switchover. - KB_LEADER_POD_FQDN: The FQDN of the original + leader's Pod before switchover. \n The env vars with following + prefix are deprecated and will be removed in the future: \n + - KB_REPLICATION_PRIMARY_POD_: The prefix of the environment + variables of the original primary's Pod before switchover. - + KB_CONSENSUS_LEADER_POD_: The prefix of the environment variables + of the original leader's Pod before switchover. \n Cannot be + updated." properties: scriptSpecSelectors: description: scriptSpecSelectors defines the selector of the @@ -3620,23 +3621,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -3892,23 +3893,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying diff --git a/config/crd/bases/apps.kubeblocks.io_components.yaml b/config/crd/bases/apps.kubeblocks.io_components.yaml index b49e190e113..406851134a3 100644 --- a/config/crd/bases/apps.kubeblocks.io_components.yaml +++ b/config/crd/bases/apps.kubeblocks.io_components.yaml @@ -401,9 +401,9 @@ spec: properties: name: default: KubeBlocks - description: 'Name of issuer. Options supported: - KubeBlocks + description: "Name of issuer. Options supported: \n - KubeBlocks - Certificates signed by KubeBlocks Operator. - UserProvided - - User provided own CA-signed certificates.' + - User provided own CA-signed certificates." enum: - KubeBlocks - UserProvided diff --git a/config/crd/bases/apps.kubeblocks.io_opsdefinitions.yaml b/config/crd/bases/apps.kubeblocks.io_opsdefinitions.yaml index 382123cb712..615f733f75b 100644 --- a/config/crd/bases/apps.kubeblocks.io_opsdefinitions.yaml +++ b/config/crd/bases/apps.kubeblocks.io_opsdefinitions.yaml @@ -77,11 +77,11 @@ spec: properties: podSelectionStrategy: default: PreferredAvailable - description: 'podSelectionStrategy how to select the target + description: "podSelectionStrategy how to select the target component pod for variable references based on the strategy. - - PreferredAvailable: prioritize the selection of available + \n - PreferredAvailable: prioritize the selection of available pod. - Available: only select available pod. if not found, - terminating the operation.' + terminating the operation." enum: - Available - PreferredAvailable @@ -8357,10 +8357,10 @@ spec: pruning, and defaulting. properties: openAPIV3Schema: - description: 'openAPIV3Schema is the OpenAPI v3 schema to use - for parameter schema. supported properties types: - string - - number - integer - array: only supported the item with string - type.' + description: "openAPIV3Schema is the OpenAPI v3 schema to use + for parameter schema. supported properties types: \n - string + - number - integer - array: only supported the item with string + type." type: object x-kubernetes-preserve-unknown-fields: true type: object @@ -8512,11 +8512,11 @@ spec: description: condition declares how the operation can be executed. properties: expression: - description: 'expression declares how the operation can + description: "expression declares how the operation can be executed using go template expression. it should return - "true" or "false", built-in objects: - "params" are input - parameters. - "cluster" is referenced cluster object. - - "component" is referenced the component Object.' + \"true\" or \"false\", built-in objects: \n - \"params\" + are input parameters. - \"cluster\" is referenced cluster + object. - \"component\" is referenced the component Object." type: string message: description: report the message if the rule is not matched. @@ -8536,10 +8536,10 @@ spec: properties: podSelectionStrategy: default: PreferredAvailable - description: 'podSelectionStrategy how to select the target component - pod for variable references based on the strategy. - PreferredAvailable: + description: "podSelectionStrategy how to select the target component + pod for variable references based on the strategy. \n - PreferredAvailable: prioritize the selection of available pod. - Available: only - select available pod. if not found, terminating the operation.' + select available pod. if not found, terminating the operation." enum: - Available - PreferredAvailable diff --git a/config/crd/bases/apps.kubeblocks.io_opsrequests.yaml b/config/crd/bases/apps.kubeblocks.io_opsrequests.yaml index 316a7cd2c37..2e151539551 100644 --- a/config/crd/bases/apps.kubeblocks.io_opsrequests.yaml +++ b/config/crd/bases/apps.kubeblocks.io_opsrequests.yaml @@ -94,10 +94,10 @@ spec: the backup should be kept. Controller will remove all backups that are older than the RetentionPeriod. For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. Sample - duration format: - years: \t2y - months: \t6mo - days: \t\t30d - - hours: \t12h - minutes: \t30m You can also combine the above - durations. For example: 30d12h30m. If not set, the backup will - be kept forever." + duration format: \n - years: \t2y - months: \t6mo - days: \t\t30d + - hours: \t12h - minutes: \t30m \n You can also combine the + above durations. For example: 30d12h30m. If not set, the backup + will be kept forever." type: string type: object cancel: diff --git a/config/crd/bases/dataprotection.kubeblocks.io_backuppolicies.yaml b/config/crd/bases/dataprotection.kubeblocks.io_backuppolicies.yaml index f18981c5a09..d2a77c6e08e 100644 --- a/config/crd/bases/dataprotection.kubeblocks.io_backuppolicies.yaml +++ b/config/crd/bases/dataprotection.kubeblocks.io_backuppolicies.yaml @@ -337,11 +337,11 @@ spec: type: object strategy: default: Any - description: 'strategy specifies the strategy to select + description: "strategy specifies the strategy to select the target pod when multiple pods are selected. Valid - values are: - Any: select any one pod that match the - labelsSelector. - All: select all pods that match - the labelsSelector.' + values are: \n - Any: select any one pod that match + the labelsSelector. - All: select all pods that match + the labelsSelector." enum: - Any - All @@ -575,10 +575,10 @@ spec: type: object strategy: default: Any - description: 'strategy specifies the strategy to select the + description: "strategy specifies the strategy to select the target pod when multiple pods are selected. Valid values - are: - Any: select any one pod that match the labelsSelector. - - All: select all pods that match the labelsSelector.' + are: \n - Any: select any one pod that match the labelsSelector. + - All: select all pods that match the labelsSelector." enum: - Any - All diff --git a/config/crd/bases/dataprotection.kubeblocks.io_backups.yaml b/config/crd/bases/dataprotection.kubeblocks.io_backups.yaml index 86a84e5b37a..1cf4b7dd7b6 100644 --- a/config/crd/bases/dataprotection.kubeblocks.io_backups.yaml +++ b/config/crd/bases/dataprotection.kubeblocks.io_backups.yaml @@ -111,9 +111,9 @@ spec: backup should be kept. Controller will remove all backups that are older than the RetentionPeriod. For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. Sample duration - format: - years: \t2y - months: \t6mo - days: \t\t30d - hours: \t12h - - minutes: \t30m You can also combine the above durations. For example: - 30d12h30m. If not set, the backup will be kept forever." + format: \n - years: \t2y - months: \t6mo - days: \t\t30d - hours: + \t12h - minutes: \t30m \n You can also combine the above durations. + For example: 30d12h30m. If not set, the backup will be kept forever." type: string required: - backupMethod @@ -513,11 +513,11 @@ spec: type: object strategy: default: Any - description: 'strategy specifies the strategy to select + description: "strategy specifies the strategy to select the target pod when multiple pods are selected. Valid - values are: - Any: select any one pod that match the - labelsSelector. - All: select all pods that match the - labelsSelector.' + values are: \n - Any: select any one pod that match + the labelsSelector. - All: select all pods that match + the labelsSelector." enum: - Any - All @@ -797,10 +797,10 @@ spec: type: object strategy: default: Any - description: 'strategy specifies the strategy to select the + description: "strategy specifies the strategy to select the target pod when multiple pods are selected. Valid values - are: - Any: select any one pod that match the labelsSelector. - - All: select all pods that match the labelsSelector.' + are: \n - Any: select any one pod that match the labelsSelector. + - All: select all pods that match the labelsSelector." enum: - Any - All diff --git a/config/crd/bases/dataprotection.kubeblocks.io_backupschedules.yaml b/config/crd/bases/dataprotection.kubeblocks.io_backupschedules.yaml index 40d07aa5fc7..be1f4f0807c 100644 --- a/config/crd/bases/dataprotection.kubeblocks.io_backupschedules.yaml +++ b/config/crd/bases/dataprotection.kubeblocks.io_backupschedules.yaml @@ -72,9 +72,9 @@ spec: the backup should be kept. controller will remove all backups that are older than the RetentionPeriod. For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. Sample - duration format: - years: \t2y - months: \t6mo - days: \t\t30d - - hours: \t12h - minutes: \t30m You can also combine the above - durations. For example: 30d12h30m" + duration format: \n - years: \t2y - months: \t6mo - days: + \t\t30d - hours: \t12h - minutes: \t30m \n You can also combine + the above durations. For example: 30d12h30m" type: string required: - backupMethod diff --git a/config/crd/bases/storage.kubeblocks.io_storageproviders.yaml b/config/crd/bases/storage.kubeblocks.io_storageproviders.yaml index 5c2b75b65b3..c7dc9518300 100644 --- a/config/crd/bases/storage.kubeblocks.io_storageproviders.yaml +++ b/config/crd/bases/storage.kubeblocks.io_storageproviders.yaml @@ -53,14 +53,14 @@ spec: description: The name of the CSI driver used by this StorageProvider. type: string csiDriverSecretTemplate: - description: 'A Go template for rendering a secret which will be used + description: "A Go template for rendering a secret which will be used by the CSI driver. The template will be rendered with the following - variables: - Parameters: a map of parameters defined in the ParametersSchema.' + variables: \n - Parameters: a map of parameters defined in the ParametersSchema." type: string datasafedConfigTemplate: - description: 'A Go template for rendering a config used by the datasafed + description: "A Go template for rendering a config used by the datasafed command. The template will be rendered with the following variables: - - Parameters: a map of parameters defined in the ParametersSchema.' + \n - Parameters: a map of parameters defined in the ParametersSchema." type: string parametersSchema: description: The schema describes the parameters required by this @@ -79,17 +79,18 @@ spec: x-kubernetes-preserve-unknown-fields: true type: object persistentVolumeClaimTemplate: - description: 'A Go template for rendering a PersistentVolumeClaim. - The template will be rendered with the following variables: - Parameters: - a map of parameters defined in the ParametersSchema. - GeneratedStorageClassName: - the name of the storage class generated with the StorageClassTemplate.' + description: "A Go template for rendering a PersistentVolumeClaim. + The template will be rendered with the following variables: \n - + Parameters: a map of parameters defined in the ParametersSchema. + - GeneratedStorageClassName: the name of the storage class generated + with the StorageClassTemplate." type: string storageClassTemplate: - description: 'A Go template for rendering a storage class which will + description: "A Go template for rendering a storage class which will be used by the CSI driver. The template will be rendered with the - following variables: - Parameters: a map of parameters defined in - the ParametersSchema. - CSIDriverSecretRef: the reference of the - secret created by the CSIDriverSecretTemplate.' + following variables: \n - Parameters: a map of parameters defined + in the ParametersSchema. - CSIDriverSecretRef: the reference of + the secret created by the CSIDriverSecretTemplate." type: string type: object status: diff --git a/config/crd/bases/workloads.kubeblocks.io_replicatedstatemachines.yaml b/config/crd/bases/workloads.kubeblocks.io_replicatedstatemachines.yaml index 96eceef31f0..ec60cbe4bda 100644 --- a/config/crd/bases/workloads.kubeblocks.io_replicatedstatemachines.yaml +++ b/config/crd/bases/workloads.kubeblocks.io_replicatedstatemachines.yaml @@ -918,9 +918,13 @@ spec: - command type: object switchoverAction: - description: SwitchoverAction specifies how to do switchover latest + description: "Environment variables can be used in all following + Actions: \n - KB_RSM_USERNAME username part of credential - + KB_RSM_PASSWORD password part of credential - KB_RSM_LEADER_HOST + leader host - KB_RSM_TARGET_HOST target host - KB_RSM_SERVICE_PORT + port \n SwitchoverAction specifies how to do switchover latest [BusyBox](https://busybox.net/) image will be used if Image - not configured + not configured" properties: args: description: Args is used to perform statements. @@ -1033,8 +1037,8 @@ spec: should be a single string of the role name defined in spec.Roles latest [BusyBox](https://busybox.net/) image will be used if Image not configured Environment variables can be used in Command: - - v_KB_RSM_LAST_STDOUT stdout from last action, watch 'v_' prefixed - - KB_RSM_USERNAME username part of credential - KB_RSM_PASSWORD + \n - v_KB_RSM_LAST_STDOUT stdout from last action, watch 'v_' + prefixed - KB_RSM_USERNAME username part of credential - KB_RSM_PASSWORD password part of credential" items: properties: diff --git a/deploy/helm/crds/apps.kubeblocks.io_backuppolicytemplates.yaml b/deploy/helm/crds/apps.kubeblocks.io_backuppolicytemplates.yaml index c999bda7864..acd3191ed4d 100644 --- a/deploy/helm/crds/apps.kubeblocks.io_backuppolicytemplates.yaml +++ b/deploy/helm/crds/apps.kubeblocks.io_backuppolicytemplates.yaml @@ -440,11 +440,11 @@ spec: type: object strategy: default: Any - description: 'strategy specifies the strategy + description: "strategy specifies the strategy to select the target pod when multiple pods - are selected. Valid values are: - Any: select + are selected. Valid values are: \n - Any: select any one pod that match the labelsSelector. - - All: select all pods that match the labelsSelector.' + All: select all pods that match the labelsSelector." enum: - Any - All @@ -528,27 +528,27 @@ spec: x-kubernetes-map-type: atomic type: object role: - description: 'select instance of corresponding role - for backup, role are: - the name of Leader/Follower/Leaner + description: "select instance of corresponding role + for backup, role are: \n - the name of Leader/Follower/Leaner for Consensus component. - primary or secondary - for Replication component. finally, invalid role + for Replication component. \n finally, invalid role of the component will be ignored. such as if workload - type is Replication and component''s replicas is + type is Replication and component's replicas is 1, the secondary role is invalid. and it also will be ignored when component is Stateful/Stateless. the role will be transformed to a role LabelSelector - for BackupPolicy''s target attribute.' + for BackupPolicy's target attribute." type: string serviceAccountName: description: serviceAccountName specifies the service account to run the backup workload. type: string strategy: - description: 'PodSelectionStrategy specifies the strategy + description: "PodSelectionStrategy specifies the strategy to select when multiple pods are selected for backup - target. Valid values are: - Any: select any one + target. Valid values are: \n - Any: select any one pod that match the labelsSelector. - All: select - all pods that match the labelsSelector.' + all pods that match the labelsSelector." enum: - Any - All @@ -653,7 +653,7 @@ spec: remove all backups that are older than the RetentionPeriod. For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. Sample duration format: - - years: \t2y - months: \t6mo - days: \t\t30d - hours: + \n - years: \t2y - months: \t6mo - days: \t\t30d - hours: \t12h - minutes: \t30m You can also combine the above durations. For example: 30d12h30m" type: string @@ -697,22 +697,22 @@ spec: type: string type: object role: - description: 'select instance of corresponding role for - backup, role are: - the name of Leader/Follower/Leaner + description: "select instance of corresponding role for + backup, role are: \n - the name of Leader/Follower/Leaner for Consensus component. - primary or secondary for Replication - component. finally, invalid role of the component will + component. \n finally, invalid role of the component will be ignored. such as if workload type is Replication and - component''s replicas is 1, the secondary role is invalid. + component's replicas is 1, the secondary role is invalid. and it also will be ignored when component is Stateful/Stateless. the role will be transformed to a role LabelSelector for - BackupPolicy''s target attribute.' + BackupPolicy's target attribute." type: string strategy: - description: 'PodSelectionStrategy specifies the strategy + description: "PodSelectionStrategy specifies the strategy to select when multiple pods are selected for backup target. - Valid values are: - Any: select any one pod that match + Valid values are: \n - Any: select any one pod that match the labelsSelector. - All: select all pods that match - the labelsSelector.' + the labelsSelector." enum: - Any - All diff --git a/deploy/helm/crds/apps.kubeblocks.io_clusterdefinitions.yaml b/deploy/helm/crds/apps.kubeblocks.io_clusterdefinitions.yaml index 7035c7dfe5e..92cdd92462f 100644 --- a/deploy/helm/crds/apps.kubeblocks.io_clusterdefinitions.yaml +++ b/deploy/helm/crds/apps.kubeblocks.io_clusterdefinitions.yaml @@ -8808,9 +8808,13 @@ spec: - command type: object switchoverAction: - description: SwitchoverAction specifies how to do switchover - latest [BusyBox](https://busybox.net/) image will - be used if Image not configured + description: "Environment variables can be used in all + following Actions: \n - KB_RSM_USERNAME username part + of credential - KB_RSM_PASSWORD password part of credential + - KB_RSM_LEADER_HOST leader host - KB_RSM_TARGET_HOST + target host - KB_RSM_SERVICE_PORT port \n SwitchoverAction + specifies how to do switchover latest [BusyBox](https://busybox.net/) + image will be used if Image not configured" properties: args: description: Args is used to perform statements. @@ -8851,7 +8855,7 @@ spec: string of the role name defined in spec.Roles latest [BusyBox](https://busybox.net/) image will be used if Image not configured Environment variables can - be used in Command: - v_KB_RSM_LAST_STDOUT stdout + be used in Command: \n - v_KB_RSM_LAST_STDOUT stdout from last action, watch 'v_' prefixed - KB_RSM_USERNAME username part of credential - KB_RSM_PASSWORD password part of credential" @@ -9992,22 +9996,22 @@ spec: type: string description: "Connection credential template used for creating a connection credential secret for cluster.apps.kubeblocks.io object. \n Built-in - objects are: - `$(RANDOM_PASSWD)` - random 8 characters. - `$(STRONG_RANDOM_PASSWD)` - - random 16 characters, with mixed cases, digits and symbols. - - `$(UUID)` - generate a random UUID v4 string. - `$(UUID_B64)` - - generate a random UUID v4 BASE64 encoded string. - `$(UUID_STR_B64)` - - generate a random UUID v4 string then BASE64 encoded. - `$(UUID_HEX)` - - generate a random UUID v4 HEX representation. - `$(HEADLESS_SVC_FQDN)` - - headless service FQDN placeholder, value pattern - $(CLUSTER_NAME)-$(1ST_COMP_NAME)-headless.$(NAMESPACE).svc, + objects are: \n - `$(RANDOM_PASSWD)` random 8 characters. dfjksgks + - `$(STRONG_RANDOM_PASSWD)` random 16 characters, with mixed cases, + digits and symbols. - `$(UUID)` generate a random UUID v4 string. + - `$(UUID_B64)` generate a random UUID v4 BASE64 encoded string. + - `$(UUID_STR_B64)` generate a random UUID v4 string then BASE64 + encoded. - `$(UUID_HEX)` generate a random UUID v4 HEX representation. + - `$(HEADLESS_SVC_FQDN)` headless service FQDN placeholder, value + pattern is `$(CLUSTER_NAME)-$(1ST_COMP_NAME)-headless.$(NAMESPACE).svc`, where 1ST_COMP_NAME is the 1st component that provide `ClusterDefinition.spec.componentDefs[].service` - attribute; - `$(SVC_FQDN)` - service FQDN placeholder, value pattern - - $(CLUSTER_NAME)-$(1ST_COMP_NAME).$(NAMESPACE).svc, where 1ST_COMP_NAME + attribute; - `$(SVC_FQDN)` service FQDN placeholder, value pattern + is `$(CLUSTER_NAME)-$(1ST_COMP_NAME).$(NAMESPACE).svc`, where 1ST_COMP_NAME is the 1st component that provide `ClusterDefinition.spec.componentDefs[].service` - attribute; - `$(SVC_PORT_{PORT-NAME})` - a ServicePort's port value + attribute; - `$(SVC_PORT_{PORT-NAME})` is ServicePort's port value with specified port name, i.e, a servicePort JSON struct: `{\"name\": \"mysql\", \"targetPort\": \"mysqlContainerPort\", \"port\": 3306}`, - and \"$(SVC_PORT_mysql)\" in the connection credential value is - 3306." + and `$(SVC_PORT_mysql)` in the connection credential value is 3306." type: object type: description: Cluster definition type defines well known application diff --git a/deploy/helm/crds/apps.kubeblocks.io_clusters.yaml b/deploy/helm/crds/apps.kubeblocks.io_clusters.yaml index ae09ba34d02..c987eca3040 100644 --- a/deploy/helm/crds/apps.kubeblocks.io_clusters.yaml +++ b/deploy/helm/crds/apps.kubeblocks.io_clusters.yaml @@ -135,9 +135,9 @@ spec: the backup should be kept. controller will remove all backups that are older than the RetentionPeriod. For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. Sample - duration format: - years: \t2y - months: \t6mo - days: \t\t30d - - hours: \t12h - minutes: \t30m You can also combine the above - durations. For example: 30d12h30m" + duration format: \n - years: \t2y - months: \t6mo - days: \t\t30d + - hours: \t12h - minutes: \t30m \n You can also combine the + above durations. For example: 30d12h30m" type: string startingDeadlineMinutes: description: startingDeadlineMinutes defines the deadline in minutes @@ -169,9 +169,9 @@ spec: both be empty at the same time. items: description: ClusterComponentSpec defines the cluster component - spec. //(TODO) +kubebuilder:validation:XValidation:rule="!has(oldSelf.componentDefRef) + spec. TODO +kubebuilder:validation:XValidation:rule="!has(oldSelf.componentDefRef) || has(self.componentDefRef)", message="componentDefRef is required - once set" //(TODO) +kubebuilder:validation:XValidation:rule="!has(oldSelf.componentDef) + once set" TODO +kubebuilder:validation:XValidation:rule="!has(oldSelf.componentDef) || has(self.componentDef)", message="componentDef is required once set" properties: @@ -235,7 +235,7 @@ spec: componentDef: description: componentDef references the name of the ComponentDefinition. If both componentDefRef and componentDef are provided, the - componentDef will take precedence over componentDefRef. //(TODO) + componentDef will take precedence over componentDefRef. TODO +kubebuilder:validation:XValidation:rule="self == oldSelf",message="componentDef is immutable" maxLength: 22 @@ -244,7 +244,7 @@ spec: componentDefRef: description: componentDefRef references componentDef defined in ClusterDefinition spec. Need to comply with IANA Service - Naming rule. //(TODO) +kubebuilder:validation:XValidation:rule="self + Naming rule. TODO +kubebuilder:validation:XValidation:rule="self == oldSelf",message="componentDefRef is immutable" maxLength: 22 pattern: ^[a-z]([a-z0-9\-]*[a-z0-9])?$ @@ -271,9 +271,9 @@ spec: properties: name: default: KubeBlocks - description: 'Name of issuer. Options supported: - KubeBlocks + description: "Name of issuer. Options supported: \n - KubeBlocks - Certificates signed by KubeBlocks Operator. - UserProvided - - User provided own CA-signed certificates.' + - User provided own CA-signed certificates." enum: - KubeBlocks - UserProvided @@ -316,7 +316,7 @@ spec: is also part of Service DNS name, so this name will comply with IANA Service Naming rule. When ClusterComponentSpec is referenced as a template, name is optional. Otherwise, it - is required. //(TODO) +kubebuilder:validation:XValidation:rule="self + is required. TODO +kubebuilder:validation:XValidation:rule="self == oldSelf",message="name is immutable" maxLength: 22 pattern: ^[a-z]([a-z0-9\-]*[a-z0-9])?$ @@ -1494,15 +1494,15 @@ spec: description: componentDef references the name of the ComponentDefinition. If both componentDefRef and componentDef are provided, the componentDef will take precedence over componentDefRef. - //(TODO) +kubebuilder:validation:XValidation:rule="self - == oldSelf",message="componentDef is immutable" + TODO +kubebuilder:validation:XValidation:rule="self == + oldSelf",message="componentDef is immutable" maxLength: 22 pattern: ^[a-z0-9]([a-z0-9\.\-]*[a-z0-9])?$ type: string componentDefRef: description: componentDefRef references componentDef defined in ClusterDefinition spec. Need to comply with IANA Service - Naming rule. //(TODO) +kubebuilder:validation:XValidation:rule="self + Naming rule. TODO +kubebuilder:validation:XValidation:rule="self == oldSelf",message="componentDefRef is immutable" maxLength: 22 pattern: ^[a-z]([a-z0-9\-]*[a-z0-9])?$ @@ -1530,9 +1530,9 @@ spec: properties: name: default: KubeBlocks - description: 'Name of issuer. Options supported: - KubeBlocks - - Certificates signed by KubeBlocks Operator. - UserProvided - - User provided own CA-signed certificates.' + description: "Name of issuer. Options supported: \n + - KubeBlocks - Certificates signed by KubeBlocks Operator. + - UserProvided - User provided own CA-signed certificates." enum: - KubeBlocks - UserProvided @@ -1575,7 +1575,7 @@ spec: name is also part of Service DNS name, so this name will comply with IANA Service Naming rule. When ClusterComponentSpec is referenced as a template, name is optional. Otherwise, - it is required. //(TODO) +kubebuilder:validation:XValidation:rule="self + it is required. TODO +kubebuilder:validation:XValidation:rule="self == oldSelf",message="name is immutable" maxLength: 22 pattern: ^[a-z]([a-z0-9\-]*[a-z0-9])?$ diff --git a/deploy/helm/crds/apps.kubeblocks.io_componentdefinitions.yaml b/deploy/helm/crds/apps.kubeblocks.io_componentdefinitions.yaml index a50c219c40b..0c715615608 100644 --- a/deploy/helm/crds/apps.kubeblocks.io_componentdefinitions.yaml +++ b/deploy/helm/crds/apps.kubeblocks.io_componentdefinitions.yaml @@ -408,23 +408,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -695,23 +695,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -749,11 +749,11 @@ spec: type: object type: object dataPopulate: - description: 'DataPopulate defines how to populate the data to + description: "DataPopulate defines how to populate the data to create new replicas. This action is typically used when a new - replica needs to be constructed, such as: - scale-out - rebuild - - clone It should write the valid data to stdout without including - any extraneous information. Cannot be updated.' + replica needs to be constructed, such as: \n - scale-out - rebuild + - clone \n It should write the valid data to stdout without + including any extraneous information. Cannot be updated." properties: builtinHandler: description: builtinHandler specifies the builtin action handler @@ -980,23 +980,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -1265,23 +1265,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -1551,23 +1551,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -1605,25 +1605,25 @@ spec: type: object type: object postProvision: - description: 'PostProvision defines the actions to be executed + description: "PostProvision defines the actions to be executed and the corresponding policy when a component is created. You can define the preCondition for executing PostProvision using Action.PreCondition. The default PostProvision action preCondition is ComponentReady. The PostProvision Action will be executed - only once. Dedicated env vars for the action: - KB_CLUSTER_COMPONENT_LIST: - The list of all components in the cluster, joined by '','' (e.g., - "comp1,comp2"). - KB_CLUSTER_COMPONENT_POD_NAME_LIST: The list - of all pods name in this component, joined by '','' (e.g., "pod1,pod2"). - - KB_CLUSTER_COMPONENT_POD_IP_LIST: The list of pod IPs where - each pod resides in this component, corresponding one-to-one - with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. joined - by '','' (e.g., "podIp1,podIp2"). - KB_CLUSTER_COMPONENT_POD_HOST_NAME_LIST: + only once. Dedicated env vars for the action: \n - KB_CLUSTER_COMPONENT_LIST: + The list of all components in the cluster, joined by ',' (e.g., + \"comp1,comp2\"). - KB_CLUSTER_COMPONENT_POD_NAME_LIST: The + list of all pods name in this component, joined by ',' (e.g., + \"pod1,pod2\"). - KB_CLUSTER_COMPONENT_POD_IP_LIST: The list + of pod IPs where each pod resides in this component, corresponding + one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. + joined by ',' (e.g., \"podIp1,podIp2\"). - KB_CLUSTER_COMPONENT_POD_HOST_NAME_LIST: The list of hostName where each pod resides in this component, corresponding one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. - joined by '','' (e.g., "hostName1,hostName2"). - KB_CLUSTER_COMPONENT_POD_HOST_IP_LIST: + joined by ',' (e.g., \"hostName1,hostName2\"). - KB_CLUSTER_COMPONENT_POD_HOST_IP_LIST: The list of host IPs where each pod resides in this component, corresponding one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. - joined by '','' (e.g., "hostIp1,hostIp2"). Cannot be updated.' + joined by ',' (e.g., \"hostIp1,hostIp2\"). \n Cannot be updated." properties: builtinHandler: description: builtinHandler specifies the builtin action handler @@ -1850,23 +1850,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -2137,23 +2137,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -2420,23 +2420,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -2702,23 +2702,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -2984,23 +2984,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -3266,23 +3266,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -3366,23 +3366,24 @@ spec: type: integer type: object switchover: - description: 'Switchover defines how to proactively switch the + description: "Switchover defines how to proactively switch the current leader to a new replica to minimize the impact on availability. This action is typically invoked when the leader is about to - become unavailable due to events, such as: - switchover - stop - - restart - scale-in Dedicated env vars for the action: - KB_SWITCHOVER_CANDIDATE_NAME: - The name of the new candidate replica''s Pod. It may be empty. - - KB_SWITCHOVER_CANDIDATE_FQDN: The FQDN of the new candidate - replica. It may be empty. - KB_LEADER_POD_IP: The IP address - of the original leader''s Pod before switchover. - KB_LEADER_POD_NAME: - The name of the original leader''s Pod before switchover. - - KB_LEADER_POD_FQDN: The FQDN of the original leader''s Pod before - switchover. The env vars with following prefix are deprecated - and will be removed in the future: - KB_REPLICATION_PRIMARY_POD_: - The prefix of the environment variables of the original primary''s - Pod before switchover. - KB_CONSENSUS_LEADER_POD_: The prefix - of the environment variables of the original leader''s Pod before - switchover. Cannot be updated.' + become unavailable due to events, such as: \n - switchover - + stop - restart - scale-in \n Dedicated env vars for the action: + \n - KB_SWITCHOVER_CANDIDATE_NAME: The name of the new candidate + replica's Pod. It may be empty. - KB_SWITCHOVER_CANDIDATE_FQDN: + The FQDN of the new candidate replica. It may be empty. - KB_LEADER_POD_IP: + The IP address of the original leader's Pod before switchover. + - KB_LEADER_POD_NAME: The name of the original leader's Pod + before switchover. - KB_LEADER_POD_FQDN: The FQDN of the original + leader's Pod before switchover. \n The env vars with following + prefix are deprecated and will be removed in the future: \n + - KB_REPLICATION_PRIMARY_POD_: The prefix of the environment + variables of the original primary's Pod before switchover. - + KB_CONSENSUS_LEADER_POD_: The prefix of the environment variables + of the original leader's Pod before switchover. \n Cannot be + updated." properties: scriptSpecSelectors: description: scriptSpecSelectors defines the selector of the @@ -3620,23 +3621,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying @@ -3892,23 +3893,23 @@ spec: matchingKey will be chosen. Cannot be updated. type: string preCondition: - description: 'PreCondition defines the condition when - the action will be executed. - Immediately: The Action + description: "PreCondition defines the condition when + the action will be executed. \n - Immediately: The Action is executed immediately after the Component object is created, without guaranteeing the availability of the Component and its underlying resources. only after the - action is successfully executed will the Component''s + action is successfully executed will the Component's state turn to ready. - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. only after the action is successfully - executed will the Component''s state turn to ready. - - ComponentReady: The Action is executed after the Component + executed will the Component's state turn to ready. - + ComponentReady: The Action is executed after the Component object is created and once the Component is ready. the execution process does not impact the state of the Component and the Cluster. - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster - is ready. the execution process does not impact the - state of the Component and the Cluster. Cannot be updated.' + is ready. \n the execution process does not impact the + state of the Component and the Cluster. Cannot be updated." type: string retryPolicy: description: RetryPolicy defines the strategy for retrying diff --git a/deploy/helm/crds/apps.kubeblocks.io_components.yaml b/deploy/helm/crds/apps.kubeblocks.io_components.yaml index b49e190e113..406851134a3 100644 --- a/deploy/helm/crds/apps.kubeblocks.io_components.yaml +++ b/deploy/helm/crds/apps.kubeblocks.io_components.yaml @@ -401,9 +401,9 @@ spec: properties: name: default: KubeBlocks - description: 'Name of issuer. Options supported: - KubeBlocks + description: "Name of issuer. Options supported: \n - KubeBlocks - Certificates signed by KubeBlocks Operator. - UserProvided - - User provided own CA-signed certificates.' + - User provided own CA-signed certificates." enum: - KubeBlocks - UserProvided diff --git a/deploy/helm/crds/apps.kubeblocks.io_opsdefinitions.yaml b/deploy/helm/crds/apps.kubeblocks.io_opsdefinitions.yaml index 382123cb712..615f733f75b 100644 --- a/deploy/helm/crds/apps.kubeblocks.io_opsdefinitions.yaml +++ b/deploy/helm/crds/apps.kubeblocks.io_opsdefinitions.yaml @@ -77,11 +77,11 @@ spec: properties: podSelectionStrategy: default: PreferredAvailable - description: 'podSelectionStrategy how to select the target + description: "podSelectionStrategy how to select the target component pod for variable references based on the strategy. - - PreferredAvailable: prioritize the selection of available + \n - PreferredAvailable: prioritize the selection of available pod. - Available: only select available pod. if not found, - terminating the operation.' + terminating the operation." enum: - Available - PreferredAvailable @@ -8357,10 +8357,10 @@ spec: pruning, and defaulting. properties: openAPIV3Schema: - description: 'openAPIV3Schema is the OpenAPI v3 schema to use - for parameter schema. supported properties types: - string - - number - integer - array: only supported the item with string - type.' + description: "openAPIV3Schema is the OpenAPI v3 schema to use + for parameter schema. supported properties types: \n - string + - number - integer - array: only supported the item with string + type." type: object x-kubernetes-preserve-unknown-fields: true type: object @@ -8512,11 +8512,11 @@ spec: description: condition declares how the operation can be executed. properties: expression: - description: 'expression declares how the operation can + description: "expression declares how the operation can be executed using go template expression. it should return - "true" or "false", built-in objects: - "params" are input - parameters. - "cluster" is referenced cluster object. - - "component" is referenced the component Object.' + \"true\" or \"false\", built-in objects: \n - \"params\" + are input parameters. - \"cluster\" is referenced cluster + object. - \"component\" is referenced the component Object." type: string message: description: report the message if the rule is not matched. @@ -8536,10 +8536,10 @@ spec: properties: podSelectionStrategy: default: PreferredAvailable - description: 'podSelectionStrategy how to select the target component - pod for variable references based on the strategy. - PreferredAvailable: + description: "podSelectionStrategy how to select the target component + pod for variable references based on the strategy. \n - PreferredAvailable: prioritize the selection of available pod. - Available: only - select available pod. if not found, terminating the operation.' + select available pod. if not found, terminating the operation." enum: - Available - PreferredAvailable diff --git a/deploy/helm/crds/apps.kubeblocks.io_opsrequests.yaml b/deploy/helm/crds/apps.kubeblocks.io_opsrequests.yaml index 316a7cd2c37..2e151539551 100644 --- a/deploy/helm/crds/apps.kubeblocks.io_opsrequests.yaml +++ b/deploy/helm/crds/apps.kubeblocks.io_opsrequests.yaml @@ -94,10 +94,10 @@ spec: the backup should be kept. Controller will remove all backups that are older than the RetentionPeriod. For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. Sample - duration format: - years: \t2y - months: \t6mo - days: \t\t30d - - hours: \t12h - minutes: \t30m You can also combine the above - durations. For example: 30d12h30m. If not set, the backup will - be kept forever." + duration format: \n - years: \t2y - months: \t6mo - days: \t\t30d + - hours: \t12h - minutes: \t30m \n You can also combine the + above durations. For example: 30d12h30m. If not set, the backup + will be kept forever." type: string type: object cancel: diff --git a/deploy/helm/crds/dataprotection.kubeblocks.io_backuppolicies.yaml b/deploy/helm/crds/dataprotection.kubeblocks.io_backuppolicies.yaml index f18981c5a09..d2a77c6e08e 100644 --- a/deploy/helm/crds/dataprotection.kubeblocks.io_backuppolicies.yaml +++ b/deploy/helm/crds/dataprotection.kubeblocks.io_backuppolicies.yaml @@ -337,11 +337,11 @@ spec: type: object strategy: default: Any - description: 'strategy specifies the strategy to select + description: "strategy specifies the strategy to select the target pod when multiple pods are selected. Valid - values are: - Any: select any one pod that match the - labelsSelector. - All: select all pods that match - the labelsSelector.' + values are: \n - Any: select any one pod that match + the labelsSelector. - All: select all pods that match + the labelsSelector." enum: - Any - All @@ -575,10 +575,10 @@ spec: type: object strategy: default: Any - description: 'strategy specifies the strategy to select the + description: "strategy specifies the strategy to select the target pod when multiple pods are selected. Valid values - are: - Any: select any one pod that match the labelsSelector. - - All: select all pods that match the labelsSelector.' + are: \n - Any: select any one pod that match the labelsSelector. + - All: select all pods that match the labelsSelector." enum: - Any - All diff --git a/deploy/helm/crds/dataprotection.kubeblocks.io_backups.yaml b/deploy/helm/crds/dataprotection.kubeblocks.io_backups.yaml index 86a84e5b37a..1cf4b7dd7b6 100644 --- a/deploy/helm/crds/dataprotection.kubeblocks.io_backups.yaml +++ b/deploy/helm/crds/dataprotection.kubeblocks.io_backups.yaml @@ -111,9 +111,9 @@ spec: backup should be kept. Controller will remove all backups that are older than the RetentionPeriod. For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. Sample duration - format: - years: \t2y - months: \t6mo - days: \t\t30d - hours: \t12h - - minutes: \t30m You can also combine the above durations. For example: - 30d12h30m. If not set, the backup will be kept forever." + format: \n - years: \t2y - months: \t6mo - days: \t\t30d - hours: + \t12h - minutes: \t30m \n You can also combine the above durations. + For example: 30d12h30m. If not set, the backup will be kept forever." type: string required: - backupMethod @@ -513,11 +513,11 @@ spec: type: object strategy: default: Any - description: 'strategy specifies the strategy to select + description: "strategy specifies the strategy to select the target pod when multiple pods are selected. Valid - values are: - Any: select any one pod that match the - labelsSelector. - All: select all pods that match the - labelsSelector.' + values are: \n - Any: select any one pod that match + the labelsSelector. - All: select all pods that match + the labelsSelector." enum: - Any - All @@ -797,10 +797,10 @@ spec: type: object strategy: default: Any - description: 'strategy specifies the strategy to select the + description: "strategy specifies the strategy to select the target pod when multiple pods are selected. Valid values - are: - Any: select any one pod that match the labelsSelector. - - All: select all pods that match the labelsSelector.' + are: \n - Any: select any one pod that match the labelsSelector. + - All: select all pods that match the labelsSelector." enum: - Any - All diff --git a/deploy/helm/crds/dataprotection.kubeblocks.io_backupschedules.yaml b/deploy/helm/crds/dataprotection.kubeblocks.io_backupschedules.yaml index 40d07aa5fc7..be1f4f0807c 100644 --- a/deploy/helm/crds/dataprotection.kubeblocks.io_backupschedules.yaml +++ b/deploy/helm/crds/dataprotection.kubeblocks.io_backupschedules.yaml @@ -72,9 +72,9 @@ spec: the backup should be kept. controller will remove all backups that are older than the RetentionPeriod. For example, RetentionPeriod of `30d` will keep only the backups of last 30 days. Sample - duration format: - years: \t2y - months: \t6mo - days: \t\t30d - - hours: \t12h - minutes: \t30m You can also combine the above - durations. For example: 30d12h30m" + duration format: \n - years: \t2y - months: \t6mo - days: + \t\t30d - hours: \t12h - minutes: \t30m \n You can also combine + the above durations. For example: 30d12h30m" type: string required: - backupMethod diff --git a/deploy/helm/crds/storage.kubeblocks.io_storageproviders.yaml b/deploy/helm/crds/storage.kubeblocks.io_storageproviders.yaml index 5c2b75b65b3..c7dc9518300 100644 --- a/deploy/helm/crds/storage.kubeblocks.io_storageproviders.yaml +++ b/deploy/helm/crds/storage.kubeblocks.io_storageproviders.yaml @@ -53,14 +53,14 @@ spec: description: The name of the CSI driver used by this StorageProvider. type: string csiDriverSecretTemplate: - description: 'A Go template for rendering a secret which will be used + description: "A Go template for rendering a secret which will be used by the CSI driver. The template will be rendered with the following - variables: - Parameters: a map of parameters defined in the ParametersSchema.' + variables: \n - Parameters: a map of parameters defined in the ParametersSchema." type: string datasafedConfigTemplate: - description: 'A Go template for rendering a config used by the datasafed + description: "A Go template for rendering a config used by the datasafed command. The template will be rendered with the following variables: - - Parameters: a map of parameters defined in the ParametersSchema.' + \n - Parameters: a map of parameters defined in the ParametersSchema." type: string parametersSchema: description: The schema describes the parameters required by this @@ -79,17 +79,18 @@ spec: x-kubernetes-preserve-unknown-fields: true type: object persistentVolumeClaimTemplate: - description: 'A Go template for rendering a PersistentVolumeClaim. - The template will be rendered with the following variables: - Parameters: - a map of parameters defined in the ParametersSchema. - GeneratedStorageClassName: - the name of the storage class generated with the StorageClassTemplate.' + description: "A Go template for rendering a PersistentVolumeClaim. + The template will be rendered with the following variables: \n - + Parameters: a map of parameters defined in the ParametersSchema. + - GeneratedStorageClassName: the name of the storage class generated + with the StorageClassTemplate." type: string storageClassTemplate: - description: 'A Go template for rendering a storage class which will + description: "A Go template for rendering a storage class which will be used by the CSI driver. The template will be rendered with the - following variables: - Parameters: a map of parameters defined in - the ParametersSchema. - CSIDriverSecretRef: the reference of the - secret created by the CSIDriverSecretTemplate.' + following variables: \n - Parameters: a map of parameters defined + in the ParametersSchema. - CSIDriverSecretRef: the reference of + the secret created by the CSIDriverSecretTemplate." type: string type: object status: diff --git a/deploy/helm/crds/workloads.kubeblocks.io_replicatedstatemachines.yaml b/deploy/helm/crds/workloads.kubeblocks.io_replicatedstatemachines.yaml index 96eceef31f0..ec60cbe4bda 100644 --- a/deploy/helm/crds/workloads.kubeblocks.io_replicatedstatemachines.yaml +++ b/deploy/helm/crds/workloads.kubeblocks.io_replicatedstatemachines.yaml @@ -918,9 +918,13 @@ spec: - command type: object switchoverAction: - description: SwitchoverAction specifies how to do switchover latest + description: "Environment variables can be used in all following + Actions: \n - KB_RSM_USERNAME username part of credential - + KB_RSM_PASSWORD password part of credential - KB_RSM_LEADER_HOST + leader host - KB_RSM_TARGET_HOST target host - KB_RSM_SERVICE_PORT + port \n SwitchoverAction specifies how to do switchover latest [BusyBox](https://busybox.net/) image will be used if Image - not configured + not configured" properties: args: description: Args is used to perform statements. @@ -1033,8 +1037,8 @@ spec: should be a single string of the role name defined in spec.Roles latest [BusyBox](https://busybox.net/) image will be used if Image not configured Environment variables can be used in Command: - - v_KB_RSM_LAST_STDOUT stdout from last action, watch 'v_' prefixed - - KB_RSM_USERNAME username part of credential - KB_RSM_PASSWORD + \n - v_KB_RSM_LAST_STDOUT stdout from last action, watch 'v_' + prefixed - KB_RSM_USERNAME username part of credential - KB_RSM_PASSWORD password part of credential" items: properties: diff --git a/docs/developer_docs/api-reference/add-on.md b/docs/developer_docs/api-reference/add-on.md index ec184f2cb1c..fd6ad8ecbcb 100644 --- a/docs/developer_docs/api-reference/add-on.md +++ b/docs/developer_docs/api-reference/add-on.md @@ -22,7 +22,7 @@ Resource Types:

Addon

-

Addon is the Schema for the add-ons API.


+

Addon is the Schema for the add-ons API.

@@ -83,7 +83,7 @@ string @@ -96,7 +96,7 @@ AddonType @@ -108,7 +108,7 @@ string @@ -120,7 +120,7 @@ string @@ -134,7 +134,7 @@ HelmTypeInstallSpec @@ -147,7 +147,7 @@ HelmTypeInstallSpec @@ -161,7 +161,7 @@ AddonInstallSpec @@ -175,7 +175,7 @@ InstallableSpec @@ -189,7 +189,7 @@ InstallableSpec
(Optional) -

Add-on description.


+

Add-on description.

-

Add-on type. The valid value is helm.


+

Add-on type. The valid value is helm.

(Optional) -

Add-on version.


+

Add-on version.

(Optional) -

Add-on provider.


+

Add-on provider.

(Optional) -

Helm installation spec. It’s processed only when type=helm.


+

Helm installation spec. It’s processed only when type=helm.

-

Default installation parameters.


+

Default installation parameters.

(Optional) -

Installation parameters.


+

Installation parameters.

(Optional) -

Addon installable spec. It provides selector and auto-install settings.


+

Addon installable spec. It provides selector and auto-install settings.

(Optional) -

Plugin installation spec.


+

Plugin installation spec.

@@ -250,7 +250,8 @@ AddonInstallSpec (Optional) -

Add-on installs parameters selectors by default. If multiple selectors are provided,
all selectors must evaluate to true.


+

Add-on installs parameters selectors by default. If multiple selectors are provided, +all selectors must evaluate to true.

@@ -293,7 +294,7 @@ string -

Name of the item.


+

Name of the item.

@@ -337,7 +338,7 @@ bool (Optional) -

enabled can be set if there are no specific installation attributes to be set.


+

enabled can be set if there are no specific installation attributes to be set.

@@ -351,7 +352,7 @@ bool (Optional) -

Installs spec. for extra items.


+

Installs spec. for extra items.

@@ -380,7 +381,7 @@ int32 (Optional) -

Replicas value.


+

Replicas value.

@@ -392,7 +393,7 @@ bool (Optional) -

Persistent Volume Enabled value.


+

Persistent Volume Enabled value.

@@ -404,7 +405,7 @@ string (Optional) -

Storage class name.


+

Storage class name.

@@ -416,7 +417,7 @@ string (Optional) -

Tolerations JSON array string value.


+

Tolerations JSON array string value.

@@ -430,7 +431,7 @@ ResourceRequirements (Optional) -

Resource requirements.


+

Resource requirements.

@@ -441,7 +442,7 @@ ResourceRequirements (Appears on:AddonStatus)

-

AddonPhase defines addon phases.


+

AddonPhase defines addon phases.

@@ -468,7 +469,7 @@ ResourceRequirements (Appears on:SelectorRequirement)

-

AddonSelectorKey are selector requirement key types.


+

AddonSelectorKey are selector requirement key types.

@@ -491,7 +492,7 @@ ResourceRequirements (Appears on:Addon)

-

AddonSpec defines the desired state of an add-on.


+

AddonSpec defines the desired state of an add-on.

@@ -510,7 +511,7 @@ string @@ -523,7 +524,7 @@ AddonType @@ -535,7 +536,7 @@ string @@ -547,7 +548,7 @@ string @@ -561,7 +562,7 @@ HelmTypeInstallSpec @@ -574,7 +575,7 @@ HelmTypeInstallSpec @@ -588,7 +589,7 @@ AddonInstallSpec @@ -602,7 +603,7 @@ InstallableSpec @@ -616,7 +617,7 @@ InstallableSpec @@ -627,7 +628,7 @@ InstallableSpec (Appears on:Addon)

-

AddonStatus defines the observed state of an add-on.


+

AddonStatus defines the observed state of an add-on.

(Optional) -

Add-on description.


+

Add-on description.

-

Add-on type. The valid value is helm.


+

Add-on type. The valid value is helm.

(Optional) -

Add-on version.


+

Add-on version.

(Optional) -

Add-on provider.


+

Add-on provider.

(Optional) -

Helm installation spec. It’s processed only when type=helm.


+

Helm installation spec. It’s processed only when type=helm.

-

Default installation parameters.


+

Default installation parameters.

(Optional) -

Installation parameters.


+

Installation parameters.

(Optional) -

Addon installable spec. It provides selector and auto-install settings.


+

Addon installable spec. It provides selector and auto-install settings.

(Optional) -

Plugin installation spec.


+

Plugin installation spec.

@@ -647,7 +648,7 @@ AddonPhase @@ -661,7 +662,7 @@ AddonPhase @@ -673,7 +674,9 @@ int64 @@ -684,7 +687,7 @@ int64 (Appears on:AddonSpec)

-

AddonType defines the addon types.


+

AddonType defines the addon types.

-

Add-on installation phases. Valid values are Disabled, Enabled, Failed, Enabling, Disabling.


+

Add-on installation phases. Valid values are Disabled, Enabled, Failed, Enabling, Disabling.

(Optional) -

Describes the current state of add-on API installation conditions.


+

Describes the current state of add-on API installation conditions.

(Optional) -

observedGeneration is the most recent generation observed for this
add-on. It corresponds to the add-on’s generation, which is
updated on mutation by the API Server.


+

observedGeneration is the most recent generation observed for this +add-on. It corresponds to the add-on’s generation, which is +updated on mutation by the API Server.

@@ -720,7 +723,7 @@ string @@ -731,7 +734,7 @@ string @@ -743,7 +746,7 @@ string @@ -771,7 +774,7 @@ string @@ -782,7 +785,7 @@ string @@ -831,7 +834,9 @@ string @@ -845,7 +850,9 @@ string @@ -857,7 +864,7 @@ string @@ -869,7 +876,7 @@ string @@ -898,7 +905,7 @@ string @@ -909,7 +916,7 @@ string (Appears on:AddonSpec)

-

HelmTypeInstallSpec defines the Helm installation spec.


+

HelmTypeInstallSpec defines the Helm installation spec.

-

Name of the plugin.


+

Name of the plugin.

-

The index repository of the plugin.


+

The index repository of the plugin.

(Optional) -

The description of the plugin.


+

The description of the plugin.

-

Object name of the referent.


+

Object name of the referent.

-

The key to select.


+

The key to select.

(Optional) -

Selects a key of a ConfigMap item list. The value of ConfigMap can be
a JSON or YAML string content. Use a key name with “.json” or “.yaml” or “.yml”
extension name to specify a content type.


+

Selects a key of a ConfigMap item list. The value of ConfigMap can be +a JSON or YAML string content. Use a key name with “.json” or “.yaml” or “.yml” +extension name to specify a content type.

(Optional) -

Selects a key of a Secrets item list. The value of Secrets can be
a JSON or YAML string content. Use a key name with “.json” or “.yaml” or “.yml”
extension name to specify a content type.


+

Selects a key of a Secrets item list. The value of Secrets can be +a JSON or YAML string content. Use a key name with “.json” or “.yaml” or “.yml” +extension name to specify a content type.

(Optional) -

Helm install set values. It can specify multiple or separate values with commas(key1=val1,key2=val2).


+

Helm install set values. It can specify multiple or separate values with commas(key1=val1,key2=val2).

(Optional) -

Helm install set JSON values. It can specify multiple or separate values with commas(key1=jsonval1,key2=jsonval2).


+

Helm install set JSON values. It can specify multiple or separate values with commas(key1=jsonval1,key2=jsonval2).

(Optional) -

tolerations sets the toleration mapping key.


+

tolerations sets the toleration mapping key.

@@ -927,7 +934,7 @@ string @@ -941,7 +948,7 @@ HelmInstallOptions @@ -955,7 +962,7 @@ HelmInstallValues @@ -969,7 +976,7 @@ HelmValuesMapping @@ -981,7 +988,7 @@ string @@ -993,7 +1000,8 @@ string @@ -1022,7 +1030,7 @@ string @@ -1034,7 +1042,7 @@ string @@ -1046,7 +1054,7 @@ string @@ -1092,7 +1100,7 @@ HelmValuesMappingItem @@ -1135,7 +1143,7 @@ string @@ -1166,7 +1174,11 @@ HelmValueMapType @@ -1180,7 +1192,9 @@ HelmJSONValueMapType @@ -1194,7 +1208,7 @@ ResourceMappingItem @@ -1225,7 +1239,8 @@ ResourceMappingItem @@ -1236,7 +1251,7 @@ bool @@ -1247,7 +1262,7 @@ bool (Appears on:SelectorRequirement)

-

LineSelectorOperator defines line selector operators.


+

LineSelectorOperator defines line selector operators.

-

A Helm Chart location URL.


+

A Helm Chart location URL.

(Optional) -

installOptions defines Helm release installation options.


+

installOptions defines Helm release installation options.

(Optional) -

HelmInstallValues defines Helm release installation set values.


+

HelmInstallValues defines Helm release installation set values.

(Optional) -

valuesMapping defines add-on normalized resources parameters mapped to Helm values’ keys.


+

valuesMapping defines add-on normalized resources parameters mapped to Helm values’ keys.

(Optional) -

chartsImage defines the image of Helm charts.


+

chartsImage defines the image of Helm charts.

(Optional) -

chartsPathInImage defines the path of Helm charts in the image. It’s used to copy
Helm charts from the image to the shared volume.


+

chartsPathInImage defines the path of Helm charts in the image. It’s used to copy +Helm charts from the image to the shared volume.

(Optional) -

replicaCount sets the replicaCount value mapping key.


+

replicaCount sets the replicaCount value mapping key.

(Optional) -

persistentVolumeEnabled sets the persistent volume enabled mapping key.


+

persistentVolumeEnabled sets the persistent volume enabled mapping key.

(Optional) -

storageClass sets the storageClass mapping key.


+

storageClass sets the storageClass mapping key.

(Optional) -

Helm value mapping items for extra items.


+

Helm value mapping items for extra items.

-

Name of the item.


+

Name of the item.

(Optional) -

valueMap define the “key” mapping values. Valid keys are replicaCount,
persistentVolumeEnabled, and storageClass. Enum values explained:
"replicaCount" sets the replicaCount value mapping key.
"persistentVolumeEnabled" sets the persistent volume enabled mapping key.
"storageClass" sets the storageClass mapping key.


+

valueMap define the “key” mapping values. Valid keys are replicaCount, +persistentVolumeEnabled, and storageClass. Enum values explained: +"replicaCount" sets the replicaCount value mapping key. +"persistentVolumeEnabled" sets the persistent volume enabled mapping key. +"storageClass" sets the storageClass mapping key.

(Optional) -

jsonMap defines the “key” mapping values. The valid key is tolerations.
Enum values explained:
"tolerations" sets the toleration mapping key.


+

jsonMap defines the “key” mapping values. The valid key is tolerations. +Enum values explained: +"tolerations" sets the toleration mapping key.

(Optional) -

resources sets resources related mapping keys.


+

resources sets resources related mapping keys.

(Optional) -

Add-on installable selectors. If multiple selectors are provided,
all selectors must evaluate to true.


+

Add-on installable selectors. If multiple selectors are provided, +all selectors must evaluate to true.

-

autoInstall defines an add-on should be installed automatically.


+

autoInstall defines an add-on should be installed automatically.

@@ -1290,7 +1305,7 @@ string @@ -1304,7 +1319,7 @@ ResourceReqLimItem @@ -1318,7 +1333,7 @@ ResourceReqLimItem @@ -1347,7 +1362,7 @@ string @@ -1359,7 +1374,7 @@ string @@ -1390,7 +1405,8 @@ Kubernetes core/v1.ResourceList @@ -1404,7 +1420,10 @@ Kubernetes core/v1.ResourceList @@ -1434,7 +1453,10 @@ AddonSelectorKey @@ -1447,7 +1469,13 @@ LineSelectorOperator @@ -1459,7 +1487,7 @@ LineSelectorOperator diff --git a/docs/developer_docs/api-reference/backup.md b/docs/developer_docs/api-reference/backup.md index ec013e0d8d7..08430c45bc8 100644 --- a/docs/developer_docs/api-reference/backup.md +++ b/docs/developer_docs/api-reference/backup.md @@ -11,6 +11,9 @@ sidebar_label: Backup
  • dataprotection.kubeblocks.io/v1alpha1
  • +
  • +storage.kubeblocks.io/v1alpha1 +
  • dataprotection.kubeblocks.io/v1alpha1

    @@ -32,7 +35,7 @@ Resource Types:

    ActionSet

    -

    ActionSet is the Schema for the actionsets API


    +

    ActionSet is the Schema for the actionsets API

    (Optional) -

    storage sets the storage size value mapping key.


    +

    storage sets the storage size value mapping key.

    (Optional) -

    cpu sets CPU requests and limits mapping keys.


    +

    cpu sets CPU requests and limits mapping keys.

    (Optional) -

    memory sets Memory requests and limits mapping keys.


    +

    memory sets Memory requests and limits mapping keys.

    (Optional) -

    Requests value mapping key.


    +

    Requests value mapping key.

    (Optional) -

    Limits value mapping key.


    +

    Limits value mapping key.

    (Optional) -

    Limits describes the maximum amount of compute resources allowed.
    More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/.


    +

    Limits describes the maximum amount of compute resources allowed. +More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/.

    (Optional) -

    Requests describes the minimum amount of compute resources required.
    If Requests is omitted for a container, it defaults to Limits if that is explicitly specified;
    otherwise, it defaults to an implementation-defined value.
    More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/.


    +

    Requests describes the minimum amount of compute resources required. +If Requests is omitted for a container, it defaults to Limits if that is explicitly specified; +otherwise, it defaults to an implementation-defined value. +More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/.

    -

    The selector key. Valid values are KubeVersion, KubeGitVersion and KubeProvider.
    “KubeVersion” the semver expression of Kubernetes versions, i.e., v1.24.
    “KubeGitVersion” may contain distro. info., i.e., v1.24.4+eks.
    “KubeProvider” the Kubernetes provider, i.e., aws, gcp, azure, huaweiCloud, tencentCloud etc.


    +

    The selector key. Valid values are KubeVersion, KubeGitVersion and KubeProvider. +“KubeVersion” the semver expression of Kubernetes versions, i.e., v1.24. +“KubeGitVersion” may contain distro. info., i.e., v1.24.4+eks. +“KubeProvider” the Kubernetes provider, i.e., aws, gcp, azure, huaweiCloud, tencentCloud etc.

    -

    Represents a key’s relationship to a set of values.
    Valid operators are Contains, NotIn, DoesNotContain, MatchRegex, and DoesNoteMatchRegex.



    Possible enum values:
    "Contains" line contains a string.
    "DoesNotContain" line does not contain a string.
    "MatchRegex" line contains a match to the regular expression.
    "DoesNotMatchRegex" line does not contain a match to the regular expression.


    +

    Represents a key’s relationship to a set of values. +Valid operators are Contains, NotIn, DoesNotContain, MatchRegex, and DoesNoteMatchRegex.

    +

    Possible enum values: +"Contains" line contains a string. +"DoesNotContain" line does not contain a string. +"MatchRegex" line contains a match to the regular expression. +"DoesNotMatchRegex" line does not contain a match to the regular expression.

    (Optional) -

    An array of string values. It serves as an “OR” expression to the operator.


    +

    An array of string values. It serves as an “OR” expression to the operator.

    @@ -94,7 +97,12 @@ BackupType @@ -108,7 +116,7 @@ BackupType @@ -122,7 +130,12 @@ BackupType @@ -136,7 +149,7 @@ BackupActionSpec @@ -150,7 +163,7 @@ RestoreActionSpec
    -

    backupType specifies the backup type, supported values: Full, Continuous.
    Full means full backup.
    Incremental means back up data that have changed since the last backup (full or incremental).
    Differential means back up data that have changed since the last full backup.
    Continuous will back up the transaction log continuously, the PITR (Point in Time Recovery).
    can be performed based on the continuous backup and full backup.


    +

    backupType specifies the backup type, supported values: Full, Continuous. +Full means full backup. +Incremental means back up data that have changed since the last backup (full or incremental). +Differential means back up data that have changed since the last full backup. +Continuous will back up the transaction log continuously, the PITR (Point in Time Recovery). +can be performed based on the continuous backup and full backup.

    (Optional) -

    List of environment variables to set in the container.


    +

    List of environment variables to set in the container.

    (Optional) -

    List of sources to populate environment variables in the container.
    The keys defined within a source must be a C_IDENTIFIER. All invalid keys
    will be reported as an event when the container is starting. When a key exists in multiple
    sources, the value associated with the last source will take precedence.
    Values defined by an Env with a duplicate key will take precedence.
    Cannot be updated.


    +

    List of sources to populate environment variables in the container. +The keys defined within a source must be a C_IDENTIFIER. All invalid keys +will be reported as an event when the container is starting. When a key exists in multiple +sources, the value associated with the last source will take precedence. +Values defined by an Env with a duplicate key will take precedence. +Cannot be updated.

    (Optional) -

    backup specifies the backup action.


    +

    backup specifies the backup action.

    (Optional) -

    restore specifies the restore action.


    +

    restore specifies the restore action.

    @@ -173,7 +186,7 @@ ActionSetStatus

    Backup

    -

    Backup is the Schema for the backups API.


    +

    Backup is the Schema for the backups API.

    @@ -233,7 +246,7 @@ string @@ -244,7 +257,7 @@ string @@ -257,7 +270,13 @@ BackupDeletionPolicy @@ -271,7 +290,19 @@ RetentionPeriod @@ -283,7 +314,8 @@ string
    -

    Which backupPolicy is applied to perform this backup.


    +

    Which backupPolicy is applied to perform this backup.

    -

    backupMethod specifies the backup method name that is defined in backupPolicy.


    +

    backupMethod specifies the backup method name that is defined in backupPolicy.

    -

    deletionPolicy determines whether the backup contents stored in backup repository
    should be deleted when the backup custom resource is deleted.
    Supported values are “Retain” and “Delete”.
    “Retain” means that the backup can not be deleted and remains in ‘Deleting’ phase.
    “Delete” means that the backup content and its physical snapshot on backup repository are deleted.
    TODO: for the retain policy, we should support in the future for only deleting
    the backup custom objects but retaining the backup contents in backup repository.
    The current implementation only prevent accidental deletion of backup data.


    +

    deletionPolicy determines whether the backup contents stored in backup repository +should be deleted when the backup custom resource is deleted. +Supported values are “Retain” and “Delete”. +“Retain” means that the backup can not be deleted and remains in ‘Deleting’ phase. +“Delete” means that the backup content and its physical snapshot on backup repository are deleted. +the backup custom objects but retaining the backup contents in backup repository. +The current implementation only prevent accidental deletion of backup data.

    (Optional) -

    retentionPeriod determines a duration up to which the backup should be kept.
    Controller will remove all backups that are older than the RetentionPeriod.
    For example, RetentionPeriod of 30d will keep only the backups of last 30 days.
    Sample duration format:
    - years: 2y
    - months: 6mo
    - days: 30d
    - hours: 12h
    - minutes: 30m
    You can also combine the above durations. For example: 30d12h30m.
    If not set, the backup will be kept forever.


    +

    retentionPeriod determines a duration up to which the backup should be kept. +Controller will remove all backups that are older than the RetentionPeriod. +For example, RetentionPeriod of 30d will keep only the backups of last 30 days. +Sample duration format:

    +
      +
    • years: 2y
    • +
    • months: 6mo
    • +
    • days: 30d
    • +
    • hours: 12h
    • +
    • minutes: 30m
    • +
    +

    You can also combine the above durations. For example: 30d12h30m. +If not set, the backup will be kept forever.

    (Optional) -

    parentBackupName determines the parent backup name for incremental or
    differential backup.


    +

    parentBackupName determines the parent backup name for incremental or +differential backup.

    @@ -306,7 +338,7 @@ BackupStatus

    BackupPolicy

    -

    BackupPolicy is the Schema for the backuppolicies API.


    +

    BackupPolicy is the Schema for the backuppolicies API.

    @@ -367,7 +399,9 @@ string @@ -379,7 +413,8 @@ string @@ -391,7 +426,7 @@ int32 @@ -404,7 +439,7 @@ BackupTarget @@ -417,7 +452,7 @@ BackupTarget @@ -429,7 +464,13 @@ bool
    (Optional) -

    backupRepoName is the name of BackupRepo and the backup data will be
    stored in this repository. If not set, will be stored in the default
    backup repository.


    +

    backupRepoName is the name of BackupRepo and the backup data will be +stored in this repository. If not set, will be stored in the default +backup repository.

    (Optional) -

    pathPrefix is the directory inside the backup repository to store the backup content.
    It is a relative to the path of the backup repository.


    +

    pathPrefix is the directory inside the backup repository to store the backup content. +It is a relative to the path of the backup repository.

    (Optional) -

    Specifies the number of retries before marking the backup failed.


    +

    Specifies the number of retries before marking the backup failed.

    -

    target specifies the target information to back up.


    +

    target specifies the target information to back up.

    -

    backupMethods defines the backup methods.


    +

    backupMethods defines the backup methods.

    (Optional) -

    useKopia specifies whether backup data should be stored in a Kopia repository.
    Data within the Kopia repository is both compressed and encrypted. Furthermore,
    data deduplication is implemented across various backups of the same cluster.
    This approach significantly reduces the actual storage usage, particularly for
    clusters with a low update frequency.
    NOTE: This feature should NOT be enabled when using KubeBlocks Community Edition,
    otherwise the backup will not be processed.


    +

    useKopia specifies whether backup data should be stored in a Kopia repository. +Data within the Kopia repository is both compressed and encrypted. Furthermore, +data deduplication is implemented across various backups of the same cluster. +This approach significantly reduces the actual storage usage, particularly for +clusters with a low update frequency. +NOTE: This feature should NOT be enabled when using KubeBlocks Community Edition, +otherwise the backup will not be processed.

    @@ -452,7 +493,7 @@ BackupPolicyStatus

    BackupRepo

    -

    BackupRepo is the Schema for the backuprepos API


    +

    BackupRepo is the Schema for the backuprepos API

    @@ -512,7 +553,7 @@ string @@ -526,7 +567,7 @@ AccessMethod @@ -540,7 +581,7 @@ Kubernetes resource.Quantity @@ -553,7 +594,7 @@ Kubernetes core/v1.PersistentVolumeReclaimPolicy @@ -565,7 +606,7 @@ map[string]string @@ -579,7 +620,7 @@ Kubernetes core/v1.SecretReference
    -

    The storage provider used by this backup repo.


    +

    The storage provider used by this backup repo.

    (Optional) -

    Specifies the access method of the backup repo.


    +

    Specifies the access method of the backup repo.

    (Optional) -

    The requested capacity for the PVC created by this backup repo.


    +

    The requested capacity for the PVC created by this backup repo.

    -

    The reclaim policy for the PV created by this backup repo.


    +

    The reclaim policy for the PV created by this backup repo.

    (Optional) -

    Non-secret configurations for the storage provider.


    +

    Non-secret configurations for the storage provider.

    (Optional) -

    A secret that contains the credentials needed by the storage provider.


    +

    A secret that contains the credentials needed by the storage provider.

    @@ -602,7 +643,7 @@ BackupRepoStatus

    BackupSchedule

    -

    BackupSchedule is the Schema for the backupschedules API.


    +

    BackupSchedule is the Schema for the backupschedules API.

    @@ -662,7 +703,7 @@ string @@ -674,7 +715,8 @@ int64 @@ -687,7 +729,7 @@ int64
    -

    Which backupPolicy is applied to perform this backup.


    +

    Which backupPolicy is applied to perform this backup.

    (Optional) -

    startingDeadlineMinutes defines the deadline in minutes for starting the
    backup workload if it misses scheduled time for any reason.


    +

    startingDeadlineMinutes defines the deadline in minutes for starting the +backup workload if it misses scheduled time for any reason.

    -

    schedules defines the list of backup schedules.


    +

    schedules defines the list of backup schedules.

    @@ -710,7 +752,7 @@ BackupScheduleStatus

    Restore

    -

    Restore is the Schema for the restores API


    +

    Restore is the Schema for the restores API

    @@ -772,7 +814,11 @@ BackupRef @@ -784,7 +830,7 @@ string @@ -798,7 +844,7 @@ RestoreKubeResources @@ -812,7 +858,8 @@ PrepareDataConfig @@ -824,7 +871,7 @@ string @@ -838,7 +885,7 @@ ReadyConfig @@ -852,7 +899,9 @@ ReadyConfig @@ -866,7 +915,7 @@ Kubernetes core/v1.ResourceRequirements @@ -878,7 +927,7 @@ int32
    -

    backup to be restored. The restore behavior based on the backup type:
    1. Full: will be restored the full backup directly.
    2. Incremental: will be restored sequentially from the most recent full backup of this incremental backup.
    3. Differential: will be restored sequentially from the parent backup of the differential backup.
    4. Continuous: will find the most recent full backup at this time point and the continuous backups after it to restore.


    +

    backup to be restored. The restore behavior based on the backup type: +1. Full: will be restored the full backup directly. +2. Incremental: will be restored sequentially from the most recent full backup of this incremental backup. +3. Differential: will be restored sequentially from the parent backup of the differential backup. +4. Continuous: will find the most recent full backup at this time point and the continuous backups after it to restore.

    (Optional) -

    restoreTime is the point in time for restoring.


    +

    restoreTime is the point in time for restoring.

    (Optional) -

    restore the specified resources of kubernetes.


    +

    restore the specified resources of kubernetes.

    (Optional) -

    configuration for the action of “prepareData” phase, including the persistent volume claims
    that need to be restored and scheduling strategy of temporary recovery pod.


    +

    configuration for the action of “prepareData” phase, including the persistent volume claims +that need to be restored and scheduling strategy of temporary recovery pod.

    (Optional) -

    service account name which needs for recovery pod.


    +

    service account name which needs for recovery pod.

    (Optional) -

    configuration for the action of “postReady” phase.


    +

    configuration for the action of “postReady” phase.

    (Optional) -

    list of environment variables to set in the container for restore and will be
    merged with the env of Backup and ActionSet.
    The priority of merging is as follows: Restore env > Backup env > ActionSet env.


    +

    list of environment variables to set in the container for restore and will be +merged with the env of Backup and ActionSet. +The priority of merging is as follows: Restore env > Backup env > ActionSet env.

    (Optional) -

    specified the required resources of restore job’s container.


    +

    specified the required resources of restore job’s container.

    (Optional) -

    Specifies the number of retries before marking the restore failed.


    +

    Specifies the number of retries before marking the restore failed.

    @@ -904,7 +953,7 @@ RestoreStatus (Appears on:BackupRepoSpec)

    -

    AccessMethod is an enum type that defines the access method of the backup repo.


    +

    AccessMethod is an enum type that defines the access method of the backup repo.

    @@ -914,9 +963,13 @@ RestoreStatus - + - +

    "Mount"

    AccessMethodMount means that the storage is mounted locally,
    so that remote files can be accessed just like a local file.


    AccessMethodMount means that the storage is mounted locally, +so that remote files can be accessed just like a local file.

    +

    "Tool"

    AccessMethodTool means to access the storage with a command-line tool,
    which helps to transfer files between the storage and local.


    AccessMethodTool means to access the storage with a command-line tool, +which helps to transfer files between the storage and local.

    +

    ActionErrorMode @@ -925,7 +978,7 @@ RestoreStatus (Appears on:ExecActionSpec, JobActionSpec)

    -

    ActionErrorMode defines how should treat an error from an action.
    TODO: now, only support Fail mode, will support Continue mode in the future.


    +

    ActionErrorMode defines how should treat an error from an action.

    @@ -935,9 +988,11 @@ RestoreStatus - + - +

    "Continue"

    ActionErrorModeContinue means that an error from an action is acceptable.


    ActionErrorModeContinue means that an error from an action is acceptable.

    +

    "Fail"

    ActionErrorModeFail means that an error from an action is problematic.


    ActionErrorModeFail means that an error from an action is problematic.

    +

    ActionPhase @@ -955,13 +1010,18 @@ RestoreStatus

    "Completed"

    -

    ActionPhaseCompleted means the action has run successfully without errors.


    +

    ActionPhaseCompleted means the action has run successfully without errors.

    +

    "Failed"

    -

    ActionPhaseFailed means the action ran but encountered an error that


    +

    ActionPhaseFailed means the action ran but encountered an error that

    +

    "New"

    -

    ActionPhaseNew means the action has been created but not yet processed by
    the BackupController.


    +

    ActionPhaseNew means the action has been created but not yet processed by +the BackupController.

    +

    "Running"

    -

    ActionPhaseRunning means the action is currently executing.


    +

    ActionPhaseRunning means the action is currently executing.

    +

    ActionSetSpec @@ -970,7 +1030,7 @@ RestoreStatus (Appears on:ActionSet)

    -

    ActionSetSpec defines the desired state of ActionSet


    +

    ActionSetSpec defines the desired state of ActionSet

    @@ -990,7 +1050,12 @@ BackupType @@ -1004,7 +1069,7 @@ BackupType @@ -1018,7 +1083,12 @@ BackupType @@ -1032,7 +1102,7 @@ BackupActionSpec @@ -1046,7 +1116,7 @@ RestoreActionSpec @@ -1057,7 +1127,7 @@ RestoreActionSpec (Appears on:ActionSet)

    -

    ActionSetStatus defines the observed state of ActionSet


    +

    ActionSetStatus defines the observed state of ActionSet

    -

    backupType specifies the backup type, supported values: Full, Continuous.
    Full means full backup.
    Incremental means back up data that have changed since the last backup (full or incremental).
    Differential means back up data that have changed since the last full backup.
    Continuous will back up the transaction log continuously, the PITR (Point in Time Recovery).
    can be performed based on the continuous backup and full backup.


    +

    backupType specifies the backup type, supported values: Full, Continuous. +Full means full backup. +Incremental means back up data that have changed since the last backup (full or incremental). +Differential means back up data that have changed since the last full backup. +Continuous will back up the transaction log continuously, the PITR (Point in Time Recovery). +can be performed based on the continuous backup and full backup.

    (Optional) -

    List of environment variables to set in the container.


    +

    List of environment variables to set in the container.

    (Optional) -

    List of sources to populate environment variables in the container.
    The keys defined within a source must be a C_IDENTIFIER. All invalid keys
    will be reported as an event when the container is starting. When a key exists in multiple
    sources, the value associated with the last source will take precedence.
    Values defined by an Env with a duplicate key will take precedence.
    Cannot be updated.


    +

    List of sources to populate environment variables in the container. +The keys defined within a source must be a C_IDENTIFIER. All invalid keys +will be reported as an event when the container is starting. When a key exists in multiple +sources, the value associated with the last source will take precedence. +Values defined by an Env with a duplicate key will take precedence. +Cannot be updated.

    (Optional) -

    backup specifies the backup action.


    +

    backup specifies the backup action.

    (Optional) -

    restore specifies the restore action.


    +

    restore specifies the restore action.

    @@ -1078,7 +1148,7 @@ Phase @@ -1090,7 +1160,7 @@ string @@ -1102,7 +1172,7 @@ int64 @@ -1113,7 +1183,7 @@ int64 (Appears on:BackupActionSpec, RestoreActionSpec)

    -

    ActionSpec defines an action that should be executed. Only one of the fields may be set.


    +

    ActionSpec defines an action that should be executed. Only one of the fields may be set.

    (Optional) -

    phase - in list of [Available,Unavailable]


    +

    phase - in list of [Available,Unavailable]

    (Optional) -

    A human-readable message indicating details about why the ActionSet is in this phase.


    +

    A human-readable message indicating details about why the ActionSet is in this phase.

    (Optional) -

    generation number


    +

    generation number

    @@ -1134,7 +1204,7 @@ ExecActionSpec @@ -1148,7 +1218,7 @@ JobActionSpec @@ -1176,7 +1246,7 @@ string @@ -1190,7 +1260,7 @@ ActionPhase @@ -1204,7 +1274,7 @@ Kubernetes meta/v1.Time @@ -1218,7 +1288,7 @@ Kubernetes meta/v1.Time @@ -1230,7 +1300,7 @@ string @@ -1244,7 +1314,7 @@ ActionType @@ -1256,7 +1326,7 @@ int32 @@ -1270,7 +1340,7 @@ Kubernetes core/v1.ObjectReference @@ -1282,7 +1352,8 @@ string @@ -1296,7 +1367,8 @@ BackupTimeRange @@ -1310,7 +1382,7 @@ BackupTimeRange @@ -1362,7 +1434,7 @@ BackupDataActionSpec @@ -1376,7 +1448,7 @@ BackupDataActionSpec @@ -1390,7 +1462,7 @@ BackupDataActionSpec @@ -1404,7 +1476,8 @@ BaseJobActionSpec @@ -1415,7 +1488,7 @@ BaseJobActionSpec (Appears on:BackupActionSpec)

    -

    BackupDataActionSpec defines how to back up data.


    +

    BackupDataActionSpec defines how to back up data.

    (Optional) -

    exec specifies the action should be executed by the pod exec API in a container.


    +

    exec specifies the action should be executed by the pod exec API in a container.

    (Optional) -

    job specifies the action should be executed by a Kubernetes Job.


    +

    job specifies the action should be executed by a Kubernetes Job.

    -

    name is the name of the action.


    +

    name is the name of the action.

    (Optional) -

    phase is the current state of the action.


    +

    phase is the current state of the action.

    (Optional) -

    startTimestamp records the time an action was started.


    +

    startTimestamp records the time an action was started.

    (Optional) -

    completionTimestamp records the time an action was completed.


    +

    completionTimestamp records the time an action was completed.

    (Optional) -

    failureReason is an error that caused the backup to fail.


    +

    failureReason is an error that caused the backup to fail.

    (Optional) -

    actionType is the type of the action.


    +

    actionType is the type of the action.

    (Optional) -

    availableReplicas available replicas for statefulSet action.


    +

    availableReplicas available replicas for statefulSet action.

    (Optional) -

    objectRef is the object reference for the action.


    +

    objectRef is the object reference for the action.

    (Optional) -

    totalSize is the total size of backed up data size.
    A string with capacity units in the format of “1Gi”, “1Mi”, “1Ki”.


    +

    totalSize is the total size of backed up data size. +A string with capacity units in the format of “1Gi”, “1Mi”, “1Ki”.

    (Optional) -

    timeRange records the time range of backed up data, for PITR, this is the
    time range of recoverable data.


    +

    timeRange records the time range of backed up data, for PITR, this is the +time range of recoverable data.

    (Optional) -

    volumeSnapshots records the volume snapshot status for the action.


    +

    volumeSnapshots records the volume snapshot status for the action.

    -

    backupData specifies the backup data action.


    +

    backupData specifies the backup data action.

    (Optional) -

    preBackup specifies a hook that should be executed before the backup.


    +

    preBackup specifies a hook that should be executed before the backup.

    (Optional) -

    postBackup specifies a hook that should be executed after the backup.


    +

    postBackup specifies a hook that should be executed after the backup.

    (Optional) -

    preDelete defines that custom deletion action which can be executed before executing the built-in deletion action.
    note that preDelete action job will ignore the env/envFrom.


    +

    preDelete defines that custom deletion action which can be executed before executing the built-in deletion action. +note that preDelete action job will ignore the env/envFrom.

    @@ -1451,7 +1524,7 @@ SyncProgress @@ -1462,7 +1535,7 @@ SyncProgress (Appears on:BackupSpec)

    -

    BackupDeletionPolicy describes a policy for end-of-life maintenance of backup content.


    +

    BackupDeletionPolicy describes a policy for end-of-life maintenance of backup content.

    (Optional) -

    syncProgress specifies whether to sync the backup progress and its interval seconds.


    +

    syncProgress specifies whether to sync the backup progress and its interval seconds.

    @@ -1483,7 +1556,7 @@ SyncProgress (Appears on:BackupPolicySpec, BackupStatus)

    -

    BackupMethod defines the backup method.


    +

    BackupMethod defines the backup method.

    @@ -1501,7 +1574,7 @@ string @@ -1513,7 +1586,9 @@ bool @@ -1525,7 +1600,9 @@ string @@ -1539,7 +1616,8 @@ TargetVolumeInfo @@ -1553,7 +1631,7 @@ TargetVolumeInfo @@ -1567,7 +1645,7 @@ RuntimeSettings @@ -1581,7 +1659,7 @@ BackupTarget @@ -1592,7 +1670,7 @@ BackupTarget (Appears on:BackupStatus)

    -

    BackupPhase is a string representation of the lifecycle phase of a Backup.


    +

    BackupPhase is a string representation of the lifecycle phase of a Backup.

    -

    the name of backup method.


    +

    the name of backup method.

    (Optional) -

    snapshotVolumes specifies whether to take snapshots of persistent volumes.
    if true, the BackupScript is not required, the controller will use the CSI
    volume snapshotter to create the snapshot.


    +

    snapshotVolumes specifies whether to take snapshots of persistent volumes. +if true, the BackupScript is not required, the controller will use the CSI +volume snapshotter to create the snapshot.

    (Optional) -

    actionSetName refers to the ActionSet object that defines the backup actions.
    For volume snapshot backup, the actionSet is not required, the controller
    will use the CSI volume snapshotter to create the snapshot.


    +

    actionSetName refers to the ActionSet object that defines the backup actions. +For volume snapshot backup, the actionSet is not required, the controller +will use the CSI volume snapshotter to create the snapshot.

    (Optional) -

    targetVolumes specifies which volumes from the target should be mounted in
    the backup workload.


    +

    targetVolumes specifies which volumes from the target should be mounted in +the backup workload.

    (Optional) -

    env specifies the environment variables for the backup workload.


    +

    env specifies the environment variables for the backup workload.

    (Optional) -

    runtimeSettings specifies runtime settings for the backup workload container.


    +

    runtimeSettings specifies runtime settings for the backup workload container.

    (Optional) -

    target specifies the target information to back up, it will override the global target policy.


    +

    target specifies the target information to back up, it will override the global target policy.

    @@ -1602,21 +1680,28 @@ BackupTarget - + - + - + - + - +

    "Completed"

    BackupPhaseCompleted means the backup has run successfully without errors.


    BackupPhaseCompleted means the backup has run successfully without errors.

    +

    "Deleting"

    BackupPhaseDeleting means the backup and all its associated data are being deleted.


    BackupPhaseDeleting means the backup and all its associated data are being deleted.

    +

    "Failed"

    BackupPhaseFailed means the backup ran but encountered an error that
    prevented it from completing successfully.


    BackupPhaseFailed means the backup ran but encountered an error that +prevented it from completing successfully.

    +

    "New"

    BackupPhaseNew means the backup has been created but not yet processed by
    the BackupController.


    BackupPhaseNew means the backup has been created but not yet processed by +the BackupController.

    +

    "Running"

    BackupPhaseRunning means the backup is currently executing.


    BackupPhaseRunning means the backup is currently executing.

    +

    BackupPolicyPhase (string alias)

    -

    BackupPolicyPhase defines phases for BackupPolicy.


    +

    BackupPolicyPhase defines phases for BackupPolicy.

    @@ -1637,7 +1722,7 @@ BackupTarget (Appears on:BackupPolicy)

    -

    BackupPolicySpec defines the desired state of BackupPolicy


    +

    BackupPolicySpec defines the desired state of BackupPolicy

    @@ -1656,7 +1741,9 @@ string @@ -1668,7 +1755,8 @@ string @@ -1680,7 +1768,7 @@ int32 @@ -1693,7 +1781,7 @@ BackupTarget @@ -1706,7 +1794,7 @@ BackupTarget @@ -1718,7 +1806,13 @@ bool @@ -1729,7 +1823,7 @@ bool (Appears on:BackupPolicy)

    -

    BackupPolicyStatus defines the observed state of BackupPolicy


    +

    BackupPolicyStatus defines the observed state of BackupPolicy

    (Optional) -

    backupRepoName is the name of BackupRepo and the backup data will be
    stored in this repository. If not set, will be stored in the default
    backup repository.


    +

    backupRepoName is the name of BackupRepo and the backup data will be +stored in this repository. If not set, will be stored in the default +backup repository.

    (Optional) -

    pathPrefix is the directory inside the backup repository to store the backup content.
    It is a relative to the path of the backup repository.


    +

    pathPrefix is the directory inside the backup repository to store the backup content. +It is a relative to the path of the backup repository.

    (Optional) -

    Specifies the number of retries before marking the backup failed.


    +

    Specifies the number of retries before marking the backup failed.

    -

    target specifies the target information to back up.


    +

    target specifies the target information to back up.

    -

    backupMethods defines the backup methods.


    +

    backupMethods defines the backup methods.

    (Optional) -

    useKopia specifies whether backup data should be stored in a Kopia repository.
    Data within the Kopia repository is both compressed and encrypted. Furthermore,
    data deduplication is implemented across various backups of the same cluster.
    This approach significantly reduces the actual storage usage, particularly for
    clusters with a low update frequency.
    NOTE: This feature should NOT be enabled when using KubeBlocks Community Edition,
    otherwise the backup will not be processed.


    +

    useKopia specifies whether backup data should be stored in a Kopia repository. +Data within the Kopia repository is both compressed and encrypted. Furthermore, +data deduplication is implemented across various backups of the same cluster. +This approach significantly reduces the actual storage usage, particularly for +clusters with a low update frequency. +NOTE: This feature should NOT be enabled when using KubeBlocks Community Edition, +otherwise the backup will not be processed.

    @@ -1750,7 +1844,7 @@ Phase @@ -1762,7 +1856,8 @@ string @@ -1774,7 +1869,9 @@ int64 @@ -1785,7 +1882,7 @@ int64 (Appears on:RestoreSpec)

    -

    BackupRef describes the backup name and namespace.


    +

    BackupRef describes the backup name and namespace.

    (Optional) -

    phase - in list of [Available,Unavailable]


    +

    phase - in list of [Available,Unavailable]

    (Optional) -

    A human-readable message indicating details about why the BackupPolicy is
    in this phase.


    +

    A human-readable message indicating details about why the BackupPolicy is +in this phase.

    (Optional) -

    observedGeneration is the most recent generation observed for this
    BackupPolicy. It refers to the BackupPolicy’s generation, which is
    updated on mutation by the API Server.


    +

    observedGeneration is the most recent generation observed for this +BackupPolicy. It refers to the BackupPolicy’s generation, which is +updated on mutation by the API Server.

    @@ -1803,7 +1900,7 @@ string @@ -1814,7 +1911,7 @@ string @@ -1825,7 +1922,7 @@ string (Appears on:BackupRepoStatus)

    -

    BackupRepoPhase defines phases for BackupRepo CR.


    +

    BackupRepoPhase defines phases for BackupRepo CR.

    -

    backup name


    +

    backup name

    -

    backup namespace


    +

    backup namespace

    @@ -1850,7 +1947,7 @@ string (Appears on:BackupRepo)

    -

    BackupRepoSpec defines the desired state of BackupRepo


    +

    BackupRepoSpec defines the desired state of BackupRepo

    @@ -1868,7 +1965,7 @@ string @@ -1882,7 +1979,7 @@ AccessMethod @@ -1896,7 +1993,7 @@ Kubernetes resource.Quantity @@ -1909,7 +2006,7 @@ Kubernetes core/v1.PersistentVolumeReclaimPolicy @@ -1921,7 +2018,7 @@ map[string]string @@ -1935,7 +2032,7 @@ Kubernetes core/v1.SecretReference @@ -1946,7 +2043,7 @@ Kubernetes core/v1.SecretReference (Appears on:BackupRepo)

    -

    BackupRepoStatus defines the observed state of BackupRepo


    +

    BackupRepoStatus defines the observed state of BackupRepo

    -

    The storage provider used by this backup repo.


    +

    The storage provider used by this backup repo.

    (Optional) -

    Specifies the access method of the backup repo.


    +

    Specifies the access method of the backup repo.

    (Optional) -

    The requested capacity for the PVC created by this backup repo.


    +

    The requested capacity for the PVC created by this backup repo.

    -

    The reclaim policy for the PV created by this backup repo.


    +

    The reclaim policy for the PV created by this backup repo.

    (Optional) -

    Non-secret configurations for the storage provider.


    +

    Non-secret configurations for the storage provider.

    (Optional) -

    A secret that contains the credentials needed by the storage provider.


    +

    A secret that contains the credentials needed by the storage provider.

    @@ -1967,7 +2064,7 @@ BackupRepoPhase @@ -1981,7 +2078,7 @@ BackupRepoPhase @@ -1993,7 +2090,7 @@ int64 @@ -2007,7 +2104,7 @@ Kubernetes core/v1.SecretReference @@ -2019,7 +2116,7 @@ string @@ -2031,7 +2128,7 @@ string @@ -2043,7 +2140,7 @@ string @@ -2055,7 +2152,7 @@ bool @@ -2066,7 +2163,7 @@ bool (Appears on:BackupScheduleStatus)

    -

    BackupSchedulePhase defines the phase of BackupSchedule


    +

    BackupSchedulePhase defines the phase of BackupSchedule

    (Optional) -

    Backup repo reconciliation phases. Valid values are PreChecking, Failed, Ready, Deleting.


    +

    Backup repo reconciliation phases. Valid values are PreChecking, Failed, Ready, Deleting.

    (Optional) -

    conditions describes the current state of the repo.


    +

    conditions describes the current state of the repo.

    (Optional) -

    observedGeneration is the latest generation observed by the controller.


    +

    observedGeneration is the latest generation observed by the controller.

    (Optional) -

    generatedCSIDriverSecret references the generated secret used by the CSI driver.


    +

    generatedCSIDriverSecret references the generated secret used by the CSI driver.

    (Optional) -

    generatedStorageClassName indicates the generated storage class name.


    +

    generatedStorageClassName indicates the generated storage class name.

    (Optional) -

    backupPVCName is the name of the PVC used to store backup data.


    +

    backupPVCName is the name of the PVC used to store backup data.

    (Optional) -

    toolConfigSecretName is the name of the secret containing the configuration for the access tool.


    +

    toolConfigSecretName is the name of the secret containing the configuration for the access tool.

    (Optional) -

    isDefault indicates whether this backup repo is the default one.


    +

    isDefault indicates whether this backup repo is the default one.

    @@ -2076,9 +2173,11 @@ bool - + - +

    "Available"

    BackupSchedulePhaseAvailable means the backup schedule is available.


    BackupSchedulePhaseAvailable means the backup schedule is available.

    +

    "Failed"

    BackupSchedulePhaseFailed means the backup schedule is failed.


    BackupSchedulePhaseFailed means the backup schedule is failed.

    +

    BackupScheduleSpec @@ -2087,7 +2186,7 @@ bool (Appears on:BackupSchedule)

    -

    BackupScheduleSpec defines the desired state of BackupSchedule.


    +

    BackupScheduleSpec defines the desired state of BackupSchedule.

    @@ -2105,7 +2204,7 @@ string @@ -2117,7 +2216,8 @@ int64 @@ -2130,7 +2230,7 @@ int64 @@ -2141,7 +2241,7 @@ int64 (Appears on:BackupSchedule)

    -

    BackupScheduleStatus defines the observed state of BackupSchedule.


    +

    BackupScheduleStatus defines the observed state of BackupSchedule.

    -

    Which backupPolicy is applied to perform this backup.


    +

    Which backupPolicy is applied to perform this backup.

    (Optional) -

    startingDeadlineMinutes defines the deadline in minutes for starting the
    backup workload if it misses scheduled time for any reason.


    +

    startingDeadlineMinutes defines the deadline in minutes for starting the +backup workload if it misses scheduled time for any reason.

    -

    schedules defines the list of backup schedules.


    +

    schedules defines the list of backup schedules.

    @@ -2162,7 +2262,7 @@ BackupSchedulePhase @@ -2174,7 +2274,9 @@ int64 @@ -2186,7 +2288,7 @@ string @@ -2194,13 +2296,13 @@ string schedules
    -map[string]..ScheduleStatus +map[string]github.com/apecloud/kubeblocks/apis/dataprotection/v1alpha1.ScheduleStatus @@ -2211,7 +2313,7 @@ map[string]..ScheduleStatus (Appears on:Backup)

    -

    BackupSpec defines the desired state of Backup.


    +

    BackupSpec defines the desired state of Backup.

    (Optional) -

    phase describes the phase of the BackupSchedule.


    +

    phase describes the phase of the BackupSchedule.

    (Optional) -

    observedGeneration is the most recent generation observed for this
    BackupSchedule. It refers to the BackupSchedule’s generation, which is
    updated on mutation by the API Server.


    +

    observedGeneration is the most recent generation observed for this +BackupSchedule. It refers to the BackupSchedule’s generation, which is +updated on mutation by the API Server.

    (Optional) -

    failureReason is an error that caused the backup to fail.


    +

    failureReason is an error that caused the backup to fail.

    (Optional) -

    schedules describes the status of each schedule.


    +

    schedules describes the status of each schedule.

    @@ -2229,7 +2331,7 @@ string @@ -2240,7 +2342,7 @@ string @@ -2253,7 +2355,13 @@ BackupDeletionPolicy @@ -2267,7 +2375,19 @@ RetentionPeriod @@ -2279,7 +2399,8 @@ string @@ -2290,7 +2411,7 @@ string (Appears on:Backup)

    -

    BackupStatus defines the observed state of Backup.


    +

    BackupStatus defines the observed state of Backup.

    -

    Which backupPolicy is applied to perform this backup.


    +

    Which backupPolicy is applied to perform this backup.

    -

    backupMethod specifies the backup method name that is defined in backupPolicy.


    +

    backupMethod specifies the backup method name that is defined in backupPolicy.

    -

    deletionPolicy determines whether the backup contents stored in backup repository
    should be deleted when the backup custom resource is deleted.
    Supported values are “Retain” and “Delete”.
    “Retain” means that the backup can not be deleted and remains in ‘Deleting’ phase.
    “Delete” means that the backup content and its physical snapshot on backup repository are deleted.
    TODO: for the retain policy, we should support in the future for only deleting
    the backup custom objects but retaining the backup contents in backup repository.
    The current implementation only prevent accidental deletion of backup data.


    +

    deletionPolicy determines whether the backup contents stored in backup repository +should be deleted when the backup custom resource is deleted. +Supported values are “Retain” and “Delete”. +“Retain” means that the backup can not be deleted and remains in ‘Deleting’ phase. +“Delete” means that the backup content and its physical snapshot on backup repository are deleted. +the backup custom objects but retaining the backup contents in backup repository. +The current implementation only prevent accidental deletion of backup data.

    (Optional) -

    retentionPeriod determines a duration up to which the backup should be kept.
    Controller will remove all backups that are older than the RetentionPeriod.
    For example, RetentionPeriod of 30d will keep only the backups of last 30 days.
    Sample duration format:
    - years: 2y
    - months: 6mo
    - days: 30d
    - hours: 12h
    - minutes: 30m
    You can also combine the above durations. For example: 30d12h30m.
    If not set, the backup will be kept forever.


    +

    retentionPeriod determines a duration up to which the backup should be kept. +Controller will remove all backups that are older than the RetentionPeriod. +For example, RetentionPeriod of 30d will keep only the backups of last 30 days. +Sample duration format:

    +
      +
    • years: 2y
    • +
    • months: 6mo
    • +
    • days: 30d
    • +
    • hours: 12h
    • +
    • minutes: 30m
    • +
    +

    You can also combine the above durations. For example: 30d12h30m. +If not set, the backup will be kept forever.

    (Optional) -

    parentBackupName determines the parent backup name for incremental or
    differential backup.


    +

    parentBackupName determines the parent backup name for incremental or +differential backup.

    @@ -2309,7 +2430,7 @@ string @@ -2323,7 +2444,7 @@ BackupPhase @@ -2337,7 +2458,8 @@ Kubernetes meta/v1.Time @@ -2351,7 +2473,8 @@ Kubernetes meta/v1.Time @@ -2365,7 +2488,9 @@ Kubernetes meta/v1.Time @@ -2379,7 +2504,8 @@ Kubernetes meta/v1.Duration @@ -2391,7 +2517,9 @@ string @@ -2403,7 +2531,7 @@ string @@ -2415,7 +2543,7 @@ string @@ -2427,7 +2555,8 @@ string @@ -2439,7 +2568,7 @@ string @@ -2451,7 +2580,8 @@ string @@ -2465,7 +2595,8 @@ BackupTimeRange @@ -2479,7 +2610,7 @@ BackupTarget @@ -2493,7 +2624,8 @@ BackupMethod @@ -2507,7 +2639,7 @@ BackupMethod @@ -2521,7 +2653,7 @@ BackupMethod @@ -2532,7 +2664,7 @@ BackupMethod @@ -2562,7 +2694,8 @@ PodSelector @@ -2576,7 +2709,8 @@ ConnectionCredential @@ -2590,7 +2724,7 @@ KubeResources @@ -2601,7 +2735,7 @@ string @@ -2612,7 +2746,8 @@ string (Appears on:ActionStatus, BackupStatus)

    -

    BackupTimeRange records the time range of backed up data, for PITR, this is the
    time range of recoverable data.


    +

    BackupTimeRange records the time range of backed up data, for PITR, this is the +time range of recoverable data.

    (Optional) -

    formatVersion is the backup format version, including major, minor and patch version.


    +

    formatVersion is the backup format version, including major, minor and patch version.

    (Optional) -

    phase is the current state of the Backup.


    +

    phase is the current state of the Backup.

    (Optional) -

    expiration is when this backup is eligible for garbage collection.
    ‘null’ means the Backup will NOT be cleaned except delete manual.


    +

    expiration is when this backup is eligible for garbage collection. +‘null’ means the Backup will NOT be cleaned except delete manual.

    (Optional) -

    startTimestamp records the time a backup was started.
    The server’s time is used for StartTimestamp.


    +

    startTimestamp records the time a backup was started. +The server’s time is used for StartTimestamp.

    (Optional) -

    completionTimestamp records the time a backup was completed.
    Completion time is recorded even on failed backups.
    The server’s time is used for CompletionTimestamp.


    +

    completionTimestamp records the time a backup was completed. +Completion time is recorded even on failed backups. +The server’s time is used for CompletionTimestamp.

    (Optional) -

    The duration time of backup execution.
    When converted to a string, the format is “1h2m0.5s”.


    +

    The duration time of backup execution. +When converted to a string, the format is “1h2m0.5s”.

    (Optional) -

    totalSize is the total size of backed up data size.
    A string with capacity units in the format of “1Gi”, “1Mi”, “1Ki”.
    If no capacity unit is specified, it is assumed to be in bytes.


    +

    totalSize is the total size of backed up data size. +A string with capacity units in the format of “1Gi”, “1Mi”, “1Ki”. +If no capacity unit is specified, it is assumed to be in bytes.

    (Optional) -

    failureReason is an error that caused the backup to fail.


    +

    failureReason is an error that caused the backup to fail.

    (Optional) -

    backupRepoName is the name of the backup repository.


    +

    backupRepoName is the name of the backup repository.

    (Optional) -

    path is the directory inside the backup repository where the backup data is stored.
    It is an absolute path in the backup repository.


    +

    path is the directory inside the backup repository where the backup data is stored. +It is an absolute path in the backup repository.

    (Optional) -

    kopiaRepoPath records the path of the Kopia repository.


    +

    kopiaRepoPath records the path of the Kopia repository.

    (Optional) -

    persistentVolumeClaimName is the name of the persistent volume claim that
    is used to store the backup data.


    +

    persistentVolumeClaimName is the name of the persistent volume claim that +is used to store the backup data.

    (Optional) -

    timeRange records the time range of backed up data, for PITR, this is the
    time range of recoverable data.


    +

    timeRange records the time range of backed up data, for PITR, this is the +time range of recoverable data.

    (Optional) -

    target records the target information for this backup.


    +

    target records the target information for this backup.

    (Optional) -

    backupMethod records the backup method information for this backup.
    Refer to BackupMethod for more details.


    +

    backupMethod records the backup method information for this backup. +Refer to BackupMethod for more details.

    (Optional) -

    actions records the actions information for this backup.


    +

    actions records the actions information for this backup.

    (Optional) -

    volumeSnapshots records the volume snapshot status for the action.


    +

    volumeSnapshots records the volume snapshot status for the action.

    -

    extra records the extra info for the backup.


    +

    extra records the extra info for the backup.

    -

    podSelector is used to find the target pod. The volumes of the target pod
    will be backed up.


    +

    podSelector is used to find the target pod. The volumes of the target pod +will be backed up.

    (Optional) -

    connectionCredential specifies the connection credential to connect to the
    target database cluster.


    +

    connectionCredential specifies the connection credential to connect to the +target database cluster.

    (Optional) -

    resources specifies the kubernetes resources to back up.


    +

    resources specifies the kubernetes resources to back up.

    -

    serviceAccountName specifies the service account to run the backup workload.


    +

    serviceAccountName specifies the service account to run the backup workload.

    @@ -2631,7 +2766,7 @@ string @@ -2645,7 +2780,7 @@ Kubernetes meta/v1.Time @@ -2659,7 +2794,7 @@ Kubernetes meta/v1.Time @@ -2670,7 +2805,7 @@ Kubernetes meta/v1.Time (Appears on:ActionSetSpec)

    -

    BackupType the backup type.


    +

    BackupType the backup type.

    (Optional) -

    time zone, only support zone offset, value range: “-12:59 ~ +13:00”


    +

    time zone, only support zone offset, value range: “-12:59 ~ +13:00”

    (Optional) -

    start records the start time of backup(Coordinated Universal Time, UTC).


    +

    start records the start time of backup(Coordinated Universal Time, UTC).

    (Optional) -

    end records the end time of backup(Coordinated Universal Time, UTC).


    +

    end records the end time of backup(Coordinated Universal Time, UTC).

    @@ -2695,7 +2830,7 @@ Kubernetes meta/v1.Time (Appears on:BackupActionSpec, JobActionSpec)

    -

    BaseJobActionSpec is an action that creates a Kubernetes Job to execute a command.


    +

    BaseJobActionSpec is an action that creates a Kubernetes Job to execute a command.

    @@ -2713,7 +2848,7 @@ string @@ -2724,7 +2859,7 @@ string @@ -2735,7 +2870,8 @@ string (Appears on:BackupTarget, ReadyConfig)

    -

    ConnectionCredential specifies the connection credential to connect to the
    target database cluster.


    +

    ConnectionCredential specifies the connection credential to connect to the +target database cluster.

    -

    image specifies the image of backup container.


    +

    image specifies the image of backup container.

    -

    command specifies the commands to back up the volume data.


    +

    command specifies the commands to back up the volume data.

    @@ -2753,7 +2889,7 @@ string @@ -2764,7 +2900,7 @@ string @@ -2775,7 +2911,9 @@ string @@ -2786,7 +2924,7 @@ string @@ -2797,7 +2935,7 @@ string @@ -2828,7 +2966,8 @@ ExecActionTarget @@ -2839,7 +2978,8 @@ ExecActionTarget (Appears on:ActionSpec)

    -

    ExecActionSpec is an action that uses the pod exec API to execute a command in a container
    in a pod.


    +

    ExecActionSpec is an action that uses the pod exec API to execute a command in a container +in a pod.

    -

    secretName refers to the Secret object that contains the connection credential.


    +

    secretName refers to the Secret object that contains the connection credential.

    -

    usernameKey specifies the map key of the user in the connection credential secret.


    +

    usernameKey specifies the map key of the user in the connection credential secret.

    -

    passwordKey specifies the map key of the password in the connection credential secret.
    This password will be saved in the backup annotation for full backup.
    You can use the environment variable DP_ENCRYPTION_KEY to specify encryption key.


    +

    passwordKey specifies the map key of the password in the connection credential secret. +This password will be saved in the backup annotation for full backup. +You can use the environment variable DP_ENCRYPTION_KEY to specify encryption key.

    -

    hostKey specifies the map key of the host in the connection credential secret.


    +

    hostKey specifies the map key of the host in the connection credential secret.

    -

    portKey specifies the map key of the port in the connection credential secret.


    +

    portKey specifies the map key of the port in the connection credential secret.

    (Optional) -

    execActionTarget defines the pods that need to be executed for the exec action.
    will execute on all pods that meet the conditions.


    +

    execActionTarget defines the pods that need to be executed for the exec action. +will execute on all pods that meet the conditions.

    @@ -2858,7 +2998,8 @@ string @@ -2869,7 +3010,7 @@ string @@ -2883,7 +3024,7 @@ ActionErrorMode @@ -2897,7 +3038,8 @@ Kubernetes meta/v1.Duration @@ -2927,7 +3069,7 @@ Kubernetes meta/v1.LabelSelector @@ -2968,7 +3110,7 @@ Kubernetes meta/v1.LabelSelector @@ -2998,7 +3140,8 @@ JobActionTarget @@ -3009,7 +3152,7 @@ JobActionTarget (Appears on:ActionSpec, BackupDataActionSpec, RestoreActionSpec)

    -

    JobActionSpec is an action that creates a Kubernetes Job to execute a command.


    +

    JobActionSpec is an action that creates a Kubernetes Job to execute a command.

    (Optional) -

    container is the container in the pod where the command should be executed.
    If not specified, the pod’s first container is used.


    +

    container is the container in the pod where the command should be executed. +If not specified, the pod’s first container is used.

    -

    Command is the command and arguments to execute.


    +

    Command is the command and arguments to execute.

    (Optional) -

    OnError specifies how should behave if it encounters an error executing this action.


    +

    OnError specifies how should behave if it encounters an error executing this action.

    (Optional) -

    Timeout defines the maximum amount of time should wait for the hook to complete before
    considering the execution a failure.


    +

    Timeout defines the maximum amount of time should wait for the hook to complete before +considering the execution a failure.

    -

    kubectl exec in all selected pods.


    +

    kubectl exec in all selected pods.

    (Optional) -

    select the specified resource for recovery by label.


    +

    select the specified resource for recovery by label.

    -

    jobActionTarget defines the pod that need to be executed for the job action.
    will select a pod that meets the conditions to execute.


    +

    jobActionTarget defines the pod that need to be executed for the job action. +will select a pod that meets the conditions to execute.

    @@ -3043,7 +3186,10 @@ bool @@ -3057,7 +3203,8 @@ ActionErrorMode @@ -3087,7 +3234,7 @@ Kubernetes meta/v1.LabelSelector @@ -3101,7 +3248,7 @@ Kubernetes meta/v1.LabelSelector @@ -3112,7 +3259,7 @@ Kubernetes meta/v1.LabelSelector (Appears on:BackupTarget)

    -

    KubeResources defines the kubernetes resources to back up.


    +

    KubeResources defines the kubernetes resources to back up.

    (Optional) -

    runOnTargetPodNode specifies whether to run the job workload on the
    target pod node. If backup container should mount the target pod’s
    volumes, this field should be set to true. otherwise the target pod’s
    volumes will be ignored.


    +

    runOnTargetPodNode specifies whether to run the job workload on the +target pod node. If backup container should mount the target pod’s +volumes, this field should be set to true. otherwise the target pod’s +volumes will be ignored.

    (Optional) -

    OnError specifies how should behave if it encounters an error executing
    this action.


    +

    OnError specifies how should behave if it encounters an error executing +this action.

    -

    select one of the pods which selected by labels to build the job spec, such as mount required volumes and inject built-in env of the selected pod.


    +

    select one of the pods which selected by labels to build the job spec, such as mount required volumes and inject built-in env of the selected pod.

    (Optional) -

    volumeMounts defines which volumes of the selected pod need to be mounted on the restoring pod.


    +

    volumeMounts defines which volumes of the selected pod need to be mounted on the restoring pod.

    @@ -3132,7 +3279,9 @@ Kubernetes meta/v1.LabelSelector @@ -3144,7 +3293,9 @@ Kubernetes meta/v1.LabelSelector @@ -3156,7 +3307,9 @@ Kubernetes meta/v1.LabelSelector @@ -3167,7 +3320,7 @@ Kubernetes meta/v1.LabelSelector (Appears on:ActionSetStatus, BackupPolicyStatus)

    -

    Phase defines the BackupPolicy and ActionSet CR .status.phase


    +

    Phase defines the BackupPolicy and ActionSet CR .status.phase

    -

    selector is a metav1.LabelSelector to filter the target kubernetes resources
    that need to be backed up.
    If not set, will do not back up any kubernetes resources.


    +

    selector is a metav1.LabelSelector to filter the target kubernetes resources +that need to be backed up. +If not set, will do not back up any kubernetes resources.

    (Optional) -

    included is a slice of namespaced-scoped resource type names to include in
    the kubernetes resources.
    The default value is “*”, which means all resource types will be included.


    +

    included is a slice of namespaced-scoped resource type names to include in +the kubernetes resources. +The default value is “*”, which means all resource types will be included.

    (Optional) -

    excluded is a slice of namespaced-scoped resource type names to exclude in
    the kubernetes resources.
    The default value is empty.


    +

    excluded is a slice of namespaced-scoped resource type names to exclude in +the kubernetes resources. +The default value is empty.

    @@ -3188,7 +3341,8 @@ Kubernetes meta/v1.LabelSelector (Appears on:PodSelector)

    -

    PodSelectionStrategy specifies the strategy to select when multiple pods are
    selected for backup target


    +

    PodSelectionStrategy specifies the strategy to select when multiple pods are +selected for backup target

    @@ -3198,9 +3352,11 @@ Kubernetes meta/v1.LabelSelector - + - +

    "All"

    PodSelectionStrategyAll selects all pods that match the labelsSelector.
    TODO: support PodSelectionStrategyAll


    PodSelectionStrategyAll selects all pods that match the labelsSelector.

    +

    "Any"

    PodSelectionStrategyAny selects any one pod that match the labelsSelector.


    PodSelectionStrategyAny selects any one pod that match the labelsSelector.

    +

    PodSelector @@ -3231,7 +3387,7 @@ Kubernetes meta/v1.LabelSelector

    (Members of LabelSelector are embedded into this type.)

    -

    labelsSelector is the label selector to filter the target pods.


    +

    labelsSelector is the label selector to filter the target pods.

    @@ -3244,7 +3400,13 @@ PodSelectionStrategy -

    strategy specifies the strategy to select the target pod when multiple pods
    are selected.
    Valid values are:
    - Any: select any one pod that match the labelsSelector.
    - All: select all pods that match the labelsSelector.


    +

    strategy specifies the strategy to select the target pod when multiple pods +are selected. +Valid values are:

    +
      +
    • Any: select any one pod that match the labelsSelector.
    • +
    • All: select all pods that match the labelsSelector.
    • +
    @@ -3275,7 +3437,8 @@ VolumeConfig (Optional) -

    dataSourceRef describes the configuration when using persistentVolumeClaim.spec.dataSourceRef method for restoring.
    it describes the source volume of the backup targetVolumes and how to mount path in the restoring container.


    +

    dataSourceRef describes the configuration when using persistentVolumeClaim.spec.dataSourceRef method for restoring. +it describes the source volume of the backup targetVolumes and how to mount path in the restoring container.

    @@ -3289,7 +3452,8 @@ VolumeConfig (Optional) -

    volumeClaims defines the persistent Volume claims that need to be restored and mount them together into the restore job.
    these persistent Volume claims will be created if not exist.


    +

    volumeClaims defines the persistent Volume claims that need to be restored and mount them together into the restore job. +these persistent Volume claims will be created if not exist.

    @@ -3303,7 +3467,8 @@ RestoreVolumeClaimsTemplate (Optional) -

    volumeClaimsTemplate defines a template to build persistent Volume claims that need to be restored.
    these claims will be created in an orderly manner based on the number of replicas or reused if already exist.


    +

    volumeClaimsTemplate defines a template to build persistent Volume claims that need to be restored. +these claims will be created in an orderly manner based on the number of replicas or reused if already exist.

    @@ -3316,7 +3481,10 @@ VolumeClaimRestorePolicy -

    VolumeClaimRestorePolicy defines restore policy for persistent volume claim.
    Supported policies are as follows:
    1. Parallel: parallel recovery of persistent volume claim.
    2. Serial: restore the persistent volume claim in sequence, and wait until the previous persistent volume claim is restored before restoring a new one.


    +

    VolumeClaimRestorePolicy defines restore policy for persistent volume claim. +Supported policies are as follows: +1. Parallel: parallel recovery of persistent volume claim. +2. Serial: restore the persistent volume claim in sequence, and wait until the previous persistent volume claim is restored before restoring a new one.

    @@ -3330,7 +3498,7 @@ SchedulingSpec (Optional) -

    scheduling spec for restoring pod.


    +

    scheduling spec for restoring pod.

    @@ -3359,7 +3527,7 @@ int (Optional) -

    number of seconds after the container has started before probe is initiated.


    +

    number of seconds after the container has started before probe is initiated.

    @@ -3371,7 +3539,8 @@ int (Optional) -

    number of seconds after which the probe times out.
    defaults to 30 second, minimum value is 1.


    +

    number of seconds after which the probe times out. +defaults to 30 second, minimum value is 1.

    @@ -3383,7 +3552,8 @@ int (Optional) -

    how often (in seconds) to perform the probe.
    defaults to 5 second, minimum value is 1.


    +

    how often (in seconds) to perform the probe. +defaults to 5 second, minimum value is 1.

    @@ -3396,7 +3566,7 @@ ReadinessProbeExecAction -

    exec specifies the action to take.


    +

    exec specifies the action to take.

    @@ -3424,7 +3594,7 @@ string -

    refer to container image.


    +

    refer to container image.

    @@ -3435,7 +3605,7 @@ string -

    refer to container command.


    +

    refer to container command.

    @@ -3466,7 +3636,7 @@ JobAction (Optional) -

    configuration for job action.


    +

    configuration for job action.

    @@ -3480,7 +3650,7 @@ ExecAction (Optional) -

    configuration for exec action.


    +

    configuration for exec action.

    @@ -3494,7 +3664,7 @@ ConnectionCredential (Optional) -

    credential template used for creating a connection credential


    +

    credential template used for creating a connection credential

    @@ -3508,7 +3678,8 @@ ReadinessProbe (Optional) -

    periodic probe of the service readiness.
    controller will perform postReadyHooks of BackupScript.spec.restore after the service readiness when readinessProbe is configured.


    +

    periodic probe of the service readiness. +controller will perform postReadyHooks of BackupScript.spec.restore after the service readiness when readinessProbe is configured.

    @@ -3519,7 +3690,7 @@ ReadinessProbe (Appears on:ActionSetSpec)

    -

    RestoreActionSpec defines how to restore data.


    +

    RestoreActionSpec defines how to restore data.

    @@ -3540,7 +3711,7 @@ JobActionSpec @@ -3554,7 +3725,7 @@ JobActionSpec @@ -3565,7 +3736,7 @@ JobActionSpec (Appears on:RestoreStatusAction)

    -

    RestoreActionStatus the status of restore action.


    +

    RestoreActionStatus the status of restore action.

    (Optional) -

    prepareData specifies the action to prepare data.


    +

    prepareData specifies the action to prepare data.

    (Optional) -

    postReady specifies the action to execute after the data is ready.


    +

    postReady specifies the action to execute after the data is ready.

    @@ -3607,7 +3778,7 @@ JobActionSpec @@ -3618,7 +3789,7 @@ JobActionSpec (Appears on:RestoreStatus)

    -

    RestorePhase The current phase. Valid values are Running, Completed, Failed, AsDataSource.


    +

    RestorePhase The current phase. Valid values are Running, Completed, Failed, AsDataSource.

    -

    will restore the specified resources


    +

    will restore the specified resources

    @@ -3643,7 +3814,7 @@ JobActionSpec (Appears on:Restore)

    -

    RestoreSpec defines the desired state of Restore


    +

    RestoreSpec defines the desired state of Restore

    @@ -3663,7 +3834,11 @@ BackupRef @@ -3675,7 +3850,7 @@ string @@ -3689,7 +3864,7 @@ RestoreKubeResources @@ -3703,7 +3878,8 @@ PrepareDataConfig @@ -3715,7 +3891,7 @@ string @@ -3729,7 +3905,7 @@ ReadyConfig @@ -3743,7 +3919,9 @@ ReadyConfig @@ -3757,7 +3935,7 @@ Kubernetes core/v1.ResourceRequirements @@ -3769,7 +3947,7 @@ int32 @@ -3797,7 +3975,7 @@ int32 (Appears on:Restore)

    -

    RestoreStatus defines the observed state of Restore


    +

    RestoreStatus defines the observed state of Restore

    -

    backup to be restored. The restore behavior based on the backup type:
    1. Full: will be restored the full backup directly.
    2. Incremental: will be restored sequentially from the most recent full backup of this incremental backup.
    3. Differential: will be restored sequentially from the parent backup of the differential backup.
    4. Continuous: will find the most recent full backup at this time point and the continuous backups after it to restore.


    +

    backup to be restored. The restore behavior based on the backup type: +1. Full: will be restored the full backup directly. +2. Incremental: will be restored sequentially from the most recent full backup of this incremental backup. +3. Differential: will be restored sequentially from the parent backup of the differential backup. +4. Continuous: will find the most recent full backup at this time point and the continuous backups after it to restore.

    (Optional) -

    restoreTime is the point in time for restoring.


    +

    restoreTime is the point in time for restoring.

    (Optional) -

    restore the specified resources of kubernetes.


    +

    restore the specified resources of kubernetes.

    (Optional) -

    configuration for the action of “prepareData” phase, including the persistent volume claims
    that need to be restored and scheduling strategy of temporary recovery pod.


    +

    configuration for the action of “prepareData” phase, including the persistent volume claims +that need to be restored and scheduling strategy of temporary recovery pod.

    (Optional) -

    service account name which needs for recovery pod.


    +

    service account name which needs for recovery pod.

    (Optional) -

    configuration for the action of “postReady” phase.


    +

    configuration for the action of “postReady” phase.

    (Optional) -

    list of environment variables to set in the container for restore and will be
    merged with the env of Backup and ActionSet.
    The priority of merging is as follows: Restore env > Backup env > ActionSet env.


    +

    list of environment variables to set in the container for restore and will be +merged with the env of Backup and ActionSet. +The priority of merging is as follows: Restore env > Backup env > ActionSet env.

    (Optional) -

    specified the required resources of restore job’s container.


    +

    specified the required resources of restore job’s container.

    (Optional) -

    Specifies the number of retries before marking the restore failed.


    +

    Specifies the number of retries before marking the restore failed.

    @@ -3831,7 +4009,7 @@ Kubernetes meta/v1.Time @@ -3845,7 +4023,7 @@ Kubernetes meta/v1.Time @@ -3859,7 +4037,8 @@ Kubernetes meta/v1.Duration @@ -3873,7 +4052,7 @@ RestoreStatusActions @@ -3887,7 +4066,7 @@ RestoreStatusActions @@ -3915,7 +4094,7 @@ string @@ -3926,7 +4105,7 @@ string @@ -3937,7 +4116,7 @@ string @@ -3949,7 +4128,7 @@ string @@ -3962,7 +4141,7 @@ RestoreActionStatus @@ -3976,7 +4155,7 @@ Kubernetes meta/v1.Time @@ -3990,7 +4169,7 @@ Kubernetes meta/v1.Time @@ -4021,7 +4200,7 @@ Kubernetes meta/v1.Time @@ -4035,7 +4214,7 @@ Kubernetes meta/v1.Time @@ -4065,7 +4244,8 @@ Kubernetes meta/v1.ObjectMeta @@ -4080,7 +4260,7 @@ Kubernetes core/v1.PersistentVolumeClaimSpec @@ -4096,7 +4276,7 @@ VolumeConfig

    (Members of VolumeConfig are embedded into this type.)

    -

    describing the source volume of the backup targetVolumes and how to mount path in the restoring container.


    +

    describing the source volume of the backup targetVolumes and how to mount path in the restoring container.

    @@ -4126,7 +4306,7 @@ VolumeConfig @@ -4137,7 +4317,8 @@ int32 @@ -4148,7 +4329,8 @@ int32 @@ -4159,7 +4341,8 @@ int32 (Appears on:BackupSpec, SchedulePolicy)

    -

    RetentionPeriod represents a duration in the format “1y2mo3w4d5h6m”, where
    y=year, mo=month, w=week, d=day, h=hour, m=minute.


    +

    RetentionPeriod represents a duration in the format “1y2mo3w4d5h6m”, where +y=year, mo=month, w=week, d=day, h=hour, m=minute.

    RuntimeSettings

    @@ -4187,7 +4370,8 @@ Kubernetes core/v1.ResourceRequirements @@ -4198,7 +4382,7 @@ Kubernetes core/v1.ResourceRequirements (Appears on:ScheduleStatus)

    -

    SchedulePhase defines the phase of schedule


    +

    SchedulePhase defines the phase of schedule

    (Optional) -

    Date/time when the restore started being processed.


    +

    Date/time when the restore started being processed.

    (Optional) -

    Date/time when the restore finished being processed.


    +

    Date/time when the restore finished being processed.

    (Optional) -

    The duration time of restore execution.
    When converted to a string, the form is “1h2m0.5s”.


    +

    The duration time of restore execution. +When converted to a string, the form is “1h2m0.5s”.

    (Optional) -

    recorded all restore actions performed.


    +

    recorded all restore actions performed.

    (Optional) -

    describe current state of restore API Resource, like warning.


    +

    describe current state of restore API Resource, like warning.

    -

    name describes the name of the recovery action based on the current backup.


    +

    name describes the name of the recovery action based on the current backup.

    -

    which backup’s restore action belongs to.


    +

    which backup’s restore action belongs to.

    -

    the execution object of the restore action.


    +

    the execution object of the restore action.

    (Optional) -

    message is a human-readable message indicating details about the object condition.


    +

    message is a human-readable message indicating details about the object condition.

    -

    the status of this action.


    +

    the status of this action.

    (Optional) -

    startTime is the start time for the restore job.


    +

    startTime is the start time for the restore job.

    (Optional) -

    endTime is the completion time for the restore job.


    +

    endTime is the completion time for the restore job.

    (Optional) -

    record the actions for prepareData phase.


    +

    record the actions for prepareData phase.

    (Optional) -

    record the actions for postReady phase.


    +

    record the actions for postReady phase.

    -

    Standard object’s metadata.
    More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata


    +

    Standard object’s metadata. +More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata

    Refer to the Kubernetes API documentation for the fields of the metadata field.
    -

    volumeClaimSpec defines the desired characteristics of a persistent volume claim.


    +

    volumeClaimSpec defines the desired characteristics of a persistent volume claim.

    -

    templates is a list of volume claims.


    +

    templates is a list of volume claims.

    -

    the replicas of persistent volume claim which need to be created and restored.
    the format of created claim name is $(template-name)-$(index).


    +

    the replicas of persistent volume claim which need to be created and restored. +the format of created claim name is $(template-name)-$(index).

    -

    the starting index for the created persistent volume claim by according to template.
    minimum is 0.


    +

    the starting index for the created persistent volume claim by according to template. +minimum is 0.

    (Optional) -

    resources specifies the resource required by container.
    More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/


    +

    resources specifies the resource required by container. +More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/

    @@ -4237,7 +4421,7 @@ bool @@ -4248,7 +4432,7 @@ string @@ -4259,7 +4443,8 @@ string @@ -4273,7 +4458,18 @@ RetentionPeriod @@ -4284,7 +4480,7 @@ RetentionPeriod (Appears on:BackupScheduleStatus)

    -

    ScheduleStatus defines the status of each schedule.


    +

    ScheduleStatus defines the status of each schedule.

    (Optional) -

    enabled specifies whether the backup schedule is enabled or not.


    +

    enabled specifies whether the backup schedule is enabled or not.

    -

    backupMethod specifies the backup method name that is defined in backupPolicy.


    +

    backupMethod specifies the backup method name that is defined in backupPolicy.

    -

    the cron expression for schedule, the timezone is in UTC.
    see https://en.wikipedia.org/wiki/Cron.


    +

    the cron expression for schedule, the timezone is in UTC. +see https://en.wikipedia.org/wiki/Cron.

    (Optional) -

    retentionPeriod determines a duration up to which the backup should be kept.
    controller will remove all backups that are older than the RetentionPeriod.
    For example, RetentionPeriod of 30d will keep only the backups of last 30 days.
    Sample duration format:
    - years: 2y
    - months: 6mo
    - days: 30d
    - hours: 12h
    - minutes: 30m
    You can also combine the above durations. For example: 30d12h30m


    +

    retentionPeriod determines a duration up to which the backup should be kept. +controller will remove all backups that are older than the RetentionPeriod. +For example, RetentionPeriod of 30d will keep only the backups of last 30 days. +Sample duration format:

    +
      +
    • years: 2y
    • +
    • months: 6mo
    • +
    • days: 30d
    • +
    • hours: 12h
    • +
    • minutes: 30m
    • +
    +

    You can also combine the above durations. For example: 30d12h30m

    @@ -4305,7 +4501,7 @@ SchedulePhase @@ -4317,7 +4513,7 @@ string @@ -4331,7 +4527,7 @@ Kubernetes meta/v1.Time @@ -4345,7 +4541,7 @@ Kubernetes meta/v1.Time @@ -4376,7 +4572,7 @@ Kubernetes meta/v1.Time @@ -4388,7 +4584,9 @@ map[string]string @@ -4400,7 +4598,9 @@ string @@ -4414,7 +4614,8 @@ Kubernetes core/v1.Affinity @@ -4428,7 +4629,9 @@ Kubernetes core/v1.Affinity @@ -4440,7 +4643,8 @@ string @@ -4469,7 +4673,9 @@ bool @@ -4481,7 +4687,7 @@ int32 @@ -4492,7 +4698,8 @@ int32 (Appears on:BackupMethod)

    -

    TargetVolumeInfo specifies the volumes and their mounts of the targeted application
    that should be mounted in backup workload.


    +

    TargetVolumeInfo specifies the volumes and their mounts of the targeted application +that should be mounted in backup workload.

    (Optional) -

    phase describes the phase of the schedule.


    +

    phase describes the phase of the schedule.

    (Optional) -

    failureReason is an error that caused the backup to fail.


    +

    failureReason is an error that caused the backup to fail.

    (Optional) -

    lastScheduleTime records the last time the backup was scheduled.


    +

    lastScheduleTime records the last time the backup was scheduled.

    (Optional) -

    lastSuccessfulTime records the last time the backup was successfully completed.


    +

    lastSuccessfulTime records the last time the backup was successfully completed.

    (Optional) -

    the restoring pod’s tolerations.


    +

    the restoring pod’s tolerations.

    (Optional) -

    nodeSelector is a selector which must be true for the pod to fit on a node.
    Selector which must match a node’s labels for the pod to be scheduled on that node.
    More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/


    +

    nodeSelector is a selector which must be true for the pod to fit on a node. +Selector which must match a node’s labels for the pod to be scheduled on that node. +More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/

    (Optional) -

    nodeName is a request to schedule this pod onto a specific node. If it is non-empty,
    the scheduler simply schedules this pod onto that node, assuming that it fits resource
    requirements.


    +

    nodeName is a request to schedule this pod onto a specific node. If it is non-empty, +the scheduler simply schedules this pod onto that node, assuming that it fits resource +requirements.

    (Optional) -

    affinity is a group of affinity scheduling rules.
    refer to https://kubernetes.io/docs/concepts/configuration/assign-pod-node/


    +

    affinity is a group of affinity scheduling rules. +refer to https://kubernetes.io/docs/concepts/configuration/assign-pod-node/

    (Optional) -

    topologySpreadConstraints describes how a group of pods ought to spread across topology
    domains. Scheduler will schedule pods in a way which abides by the constraints.
    refer to https://kubernetes.io/docs/concepts/scheduling-eviction/topology-spread-constraints/


    +

    topologySpreadConstraints describes how a group of pods ought to spread across topology +domains. Scheduler will schedule pods in a way which abides by the constraints. +refer to https://kubernetes.io/docs/concepts/scheduling-eviction/topology-spread-constraints/

    (Optional) -

    If specified, the pod will be dispatched by specified scheduler.
    If not specified, the pod will be dispatched by default scheduler.


    +

    If specified, the pod will be dispatched by specified scheduler. +If not specified, the pod will be dispatched by default scheduler.

    (Optional) -

    enabled specifies whether to sync the backup progress. If enabled,
    a sidecar container will be created to sync the backup progress to the
    Backup CR status.


    +

    enabled specifies whether to sync the backup progress. If enabled, +a sidecar container will be created to sync the backup progress to the +Backup CR status.

    (Optional) -

    intervalSeconds specifies the interval seconds to sync the backup progress.


    +

    intervalSeconds specifies the interval seconds to sync the backup progress.

    @@ -4511,7 +4718,8 @@ int32 @@ -4525,7 +4733,7 @@ int32 @@ -4536,7 +4744,11 @@ int32 (Appears on:PrepareDataConfig)

    -

    VolumeClaimRestorePolicy defines restore policy for persistent volume claim.
    Supported policies are as follows:
    1. Parallel: parallel recovery of persistent volume claim.
    2. Serial: restore the persistent volume claim in sequence, and wait until the
    previous persistent volume claim is restored before restoring a new one.


    +

    VolumeClaimRestorePolicy defines restore policy for persistent volume claim. +Supported policies are as follows: +1. Parallel: parallel recovery of persistent volume claim. +2. Serial: restore the persistent volume claim in sequence, and wait until the +previous persistent volume claim is restored before restoring a new one.

    (Optional) -

    Volumes indicates the list of volumes of targeted application that should
    be mounted on the backup job.


    +

    Volumes indicates the list of volumes of targeted application that should +be mounted on the backup job.

    (Optional) -

    volumeMounts specifies the mount for the volumes specified in Volumes section.


    +

    volumeMounts specifies the mount for the volumes specified in Volumes section.

    @@ -4575,7 +4787,8 @@ string @@ -4587,7 +4800,7 @@ string @@ -4615,7 +4828,7 @@ string @@ -4626,7 +4839,7 @@ string @@ -4638,7 +4851,7 @@ string @@ -4650,7 +4863,403 @@ string + + +
    (Optional) -

    volumeSource describes the volume will be restored from the specified volume of the backup targetVolumes.
    required if the backup uses volume snapshot.


    +

    volumeSource describes the volume will be restored from the specified volume of the backup targetVolumes. +required if the backup uses volume snapshot.

    (Optional) -

    mountPath path within the restoring container at which the volume should be mounted.


    +

    mountPath path within the restoring container at which the volume should be mounted.

    -

    name is the name of the volume snapshot.


    +

    name is the name of the volume snapshot.

    -

    contentName is the name of the volume snapshot content.


    +

    contentName is the name of the volume snapshot content.

    (Optional) -

    volumeName is the name of the volume.


    +

    volumeName is the name of the volume.

    (Optional) -

    size is the size of the volume snapshot.


    +

    size is the size of the volume snapshot.

    +
    +
    +

    storage.kubeblocks.io/v1alpha1

    +
    +
    +Resource Types: + +

    StorageProvider +

    +
    +

    StorageProvider is the Schema for the storageproviders API +StorageProvider describes how to provision PVCs for a specific storage system (e.g. S3, NFS, etc), +by using the CSI driver.

    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    FieldDescription
    +apiVersion
    +string
    +storage.kubeblocks.io/v1alpha1 +
    +kind
    +string +
    StorageProvider
    +metadata
    + + +Kubernetes meta/v1.ObjectMeta + + +
    +Refer to the Kubernetes API documentation for the fields of the +metadata field. +
    +spec
    + + +StorageProviderSpec + + +
    +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + +
    +csiDriverName
    + +string + +
    +(Optional) +

    The name of the CSI driver used by this StorageProvider.

    +
    +csiDriverSecretTemplate
    + +string + +
    +(Optional) +

    A Go template for rendering a secret which will be used by the CSI driver. +The template will be rendered with the following variables:

    +
      +
    • Parameters: a map of parameters defined in the ParametersSchema.
    • +
    +
    +storageClassTemplate
    + +string + +
    +(Optional) +

    A Go template for rendering a storage class which will be used by the CSI driver. +The template will be rendered with the following variables:

    +
      +
    • Parameters: a map of parameters defined in the ParametersSchema.
    • +
    • CSIDriverSecretRef: the reference of the secret created by the CSIDriverSecretTemplate.
    • +
    +
    +persistentVolumeClaimTemplate
    + +string + +
    +(Optional) +

    A Go template for rendering a PersistentVolumeClaim. +The template will be rendered with the following variables:

    +
      +
    • Parameters: a map of parameters defined in the ParametersSchema.
    • +
    • GeneratedStorageClassName: the name of the storage class generated with the StorageClassTemplate.
    • +
    +
    +datasafedConfigTemplate
    + +string + +
    +(Optional) +

    A Go template for rendering a config used by the datasafed command. +The template will be rendered with the following variables:

    +
      +
    • Parameters: a map of parameters defined in the ParametersSchema.
    • +
    +
    +parametersSchema
    + + +ParametersSchema + + +
    +(Optional) +

    The schema describes the parameters required by this StorageProvider, +when rendering the templates.

    +
    +
    +status
    + + +StorageProviderStatus + + +
    +
    +

    ParametersSchema +

    +

    +(Appears on:StorageProviderSpec) +

    +
    +

    ParametersSchema describes the parameters used by this StorageProvider.

    +
    + + + + + + + + + + + + + + + + + +
    FieldDescription
    +openAPIV3Schema
    + + +Kubernetes api extensions v1.JSONSchemaProps + + +
    +(Optional) +

    openAPIV3Schema is the OpenAPI v3 schema to use for validation and pruning.

    +
    +credentialFields
    + +[]string + +
    +(Optional) +

    credentialFields are the fields used to generate the secret.

    +
    +

    StorageProviderPhase +(string alias)

    +

    +(Appears on:StorageProviderStatus) +

    +
    +

    StorageProviderPhase defines phases of a storage provider.

    +
    + + + + + + + + + + + + +
    ValueDescription

    "NotReady"

    "Ready"

    +

    StorageProviderSpec +

    +

    +(Appears on:StorageProvider) +

    +
    +

    StorageProviderSpec defines the desired state of StorageProvider

    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    FieldDescription
    +csiDriverName
    + +string + +
    +(Optional) +

    The name of the CSI driver used by this StorageProvider.

    +
    +csiDriverSecretTemplate
    + +string + +
    +(Optional) +

    A Go template for rendering a secret which will be used by the CSI driver. +The template will be rendered with the following variables:

    +
      +
    • Parameters: a map of parameters defined in the ParametersSchema.
    • +
    +
    +storageClassTemplate
    + +string + +
    +(Optional) +

    A Go template for rendering a storage class which will be used by the CSI driver. +The template will be rendered with the following variables:

    +
      +
    • Parameters: a map of parameters defined in the ParametersSchema.
    • +
    • CSIDriverSecretRef: the reference of the secret created by the CSIDriverSecretTemplate.
    • +
    +
    +persistentVolumeClaimTemplate
    + +string + +
    +(Optional) +

    A Go template for rendering a PersistentVolumeClaim. +The template will be rendered with the following variables:

    +
      +
    • Parameters: a map of parameters defined in the ParametersSchema.
    • +
    • GeneratedStorageClassName: the name of the storage class generated with the StorageClassTemplate.
    • +
    +
    +datasafedConfigTemplate
    + +string + +
    +(Optional) +

    A Go template for rendering a config used by the datasafed command. +The template will be rendered with the following variables:

    +
      +
    • Parameters: a map of parameters defined in the ParametersSchema.
    • +
    +
    +parametersSchema
    + + +ParametersSchema + + +
    +(Optional) +

    The schema describes the parameters required by this StorageProvider, +when rendering the templates.

    +
    +

    StorageProviderStatus +

    +

    +(Appears on:StorageProvider) +

    +
    +

    StorageProviderStatus defines the observed state of StorageProvider

    +
    + + + + + + + + + + + + + + + diff --git a/docs/developer_docs/api-reference/cluster.md b/docs/developer_docs/api-reference/cluster.md index 7e99265f1be..2816f18e053 100644 --- a/docs/developer_docs/api-reference/cluster.md +++ b/docs/developer_docs/api-reference/cluster.md @@ -11,6 +11,9 @@ sidebar_label: Cluster
  • apps.kubeblocks.io/v1alpha1
  • +
  • +workloads.kubeblocks.io/v1alpha1 +
  • apps.kubeblocks.io/v1alpha1

    @@ -46,7 +49,7 @@ Resource Types:

    BackupPolicyTemplate

    -

    BackupPolicyTemplate is the Schema for the BackupPolicyTemplates API (defined by provider)


    +

    BackupPolicyTemplate is the Schema for the BackupPolicyTemplates API (defined by provider)

    FieldDescription
    +phase
    + + +StorageProviderPhase + + +
    +

    Storage provider reconciliation phases. Valid values are NotReady, Ready.

    +
    +conditions
    + + +[]Kubernetes meta/v1.Condition + + +
    +(Optional) +

    Describes the current state of the storage provider.

    @@ -106,7 +109,7 @@ string @@ -119,7 +122,7 @@ string @@ -131,7 +134,10 @@ string
    -

    clusterDefinitionRef references ClusterDefinition name, this is an immutable attribute.


    +

    clusterDefinitionRef references ClusterDefinition name, this is an immutable attribute.

    -

    backupPolicies is a list of backup policy template for the specified componentDefinition.


    +

    backupPolicies is a list of backup policy template for the specified componentDefinition.

    (Optional) -

    Identifier is a unique identifier for this BackupPolicyTemplate.
    this identifier will be the suffix of the automatically generated backupPolicy name.
    and must be added when multiple BackupPolicyTemplates exist,
    otherwise the generated backupPolicy override will occur.


    +

    Identifier is a unique identifier for this BackupPolicyTemplate. +this identifier will be the suffix of the automatically generated backupPolicy name. +and must be added when multiple BackupPolicyTemplates exist, +otherwise the generated backupPolicy override will occur.

    @@ -154,7 +160,7 @@ BackupPolicyTemplateStatus

    Cluster

    -

    Cluster is the Schema for the clusters API.


    +

    Cluster is the Schema for the clusters API.

    @@ -215,7 +221,8 @@ string @@ -227,7 +234,7 @@ string @@ -240,7 +247,11 @@ TerminationPolicyType @@ -254,7 +265,8 @@ TerminationPolicyType @@ -268,7 +280,8 @@ TerminationPolicyType @@ -282,7 +295,7 @@ TerminationPolicyType @@ -296,7 +309,7 @@ Affinity @@ -310,7 +323,7 @@ Affinity @@ -324,7 +337,9 @@ TenancyType @@ -338,7 +353,7 @@ AvailabilityPolicyType @@ -350,7 +365,7 @@ int32 @@ -364,7 +379,7 @@ ClusterResources @@ -378,7 +393,7 @@ ClusterStorage @@ -392,7 +407,7 @@ ClusterMonitor @@ -406,7 +421,7 @@ ClusterNetwork @@ -420,7 +435,7 @@ ClusterBackup
    (Optional) -

    Cluster referencing ClusterDefinition name. This is an immutable attribute.
    If ClusterDefRef is not specified, ComponentDef must be specified for each Component in ComponentSpecs.


    +

    Cluster referencing ClusterDefinition name. This is an immutable attribute. +If ClusterDefRef is not specified, ComponentDef must be specified for each Component in ComponentSpecs.

    (Optional) -

    Cluster referencing ClusterVersion name.


    +

    Cluster referencing ClusterVersion name.

    -

    Cluster termination policy. Valid values are DoNotTerminate, Halt, Delete, WipeOut.
    DoNotTerminate will block delete operation.
    Halt will delete workload resources such as statefulset, deployment workloads but keep PVCs.
    Delete is based on Halt and deletes PVCs.
    WipeOut is based on Delete and wipe out all volume snapshots and snapshot data from backup storage location.


    +

    Cluster termination policy. Valid values are DoNotTerminate, Halt, Delete, WipeOut. +DoNotTerminate will block delete operation. +Halt will delete workload resources such as statefulset, deployment workloads but keep PVCs. +Delete is based on Halt and deletes PVCs. +WipeOut is based on Delete and wipe out all volume snapshots and snapshot data from backup storage location.

    (Optional) -

    List of ShardingSpec which is used to define components with a sharding topology structure that make up a cluster.
    ShardingSpecs and ComponentSpecs cannot both be empty at the same time.


    +

    List of ShardingSpec which is used to define components with a sharding topology structure that make up a cluster. +ShardingSpecs and ComponentSpecs cannot both be empty at the same time.

    (Optional) -

    List of componentSpec which is used to define the components that make up a cluster.
    ComponentSpecs and ShardingSpecs cannot both be empty at the same time.


    +

    List of componentSpec which is used to define the components that make up a cluster. +ComponentSpecs and ShardingSpecs cannot both be empty at the same time.

    (Optional) -

    services defines the services to access a cluster.


    +

    services defines the services to access a cluster.

    (Optional) -

    affinity is a group of affinity scheduling rules.


    +

    affinity is a group of affinity scheduling rules.

    (Optional) -

    tolerations are attached to tolerate any taint that matches the triple key,value,effect using the matching operator operator.


    +

    tolerations are attached to tolerate any taint that matches the triple key,value,effect using the matching operator operator.

    (Optional) -

    tenancy describes how pods are distributed across node.
    SharedNode means multiple pods may share the same node.
    DedicatedNode means each pod runs on their own dedicated node.


    +

    tenancy describes how pods are distributed across node. +SharedNode means multiple pods may share the same node. +DedicatedNode means each pod runs on their own dedicated node.

    (Optional) -

    availabilityPolicy describes the availability policy, including zone, node, and none.


    +

    availabilityPolicy describes the availability policy, including zone, node, and none.

    (Optional) -

    replicas specifies the replicas of the first componentSpec, if the replicas of the first componentSpec is specified, this value will be ignored.


    +

    replicas specifies the replicas of the first componentSpec, if the replicas of the first componentSpec is specified, this value will be ignored.

    (Optional) -

    resources specifies the resources of the first componentSpec, if the resources of the first componentSpec is specified, this value will be ignored.


    +

    resources specifies the resources of the first componentSpec, if the resources of the first componentSpec is specified, this value will be ignored.

    (Optional) -

    storage specifies the storage of the first componentSpec, if the storage of the first componentSpec is specified, this value will be ignored.


    +

    storage specifies the storage of the first componentSpec, if the storage of the first componentSpec is specified, this value will be ignored.

    (Optional) -

    monitor specifies the configuration of monitor


    +

    monitor specifies the configuration of monitor

    (Optional) -

    network specifies the configuration of network


    +

    network specifies the configuration of network

    (Optional) -

    cluster backup configuration.


    +

    cluster backup configuration.

    @@ -443,7 +458,7 @@ ClusterStatus

    ClusterDefinition

    -

    ClusterDefinition is the Schema for the clusterdefinitions API


    +

    ClusterDefinition is the Schema for the clusterdefinitions API

    @@ -504,7 +519,7 @@ string @@ -517,7 +532,7 @@ string @@ -529,7 +544,25 @@ map[string]string
    (Optional) -

    Cluster definition type defines well known application cluster type, e.g. mysql/redis/mongodb


    +

    Cluster definition type defines well known application cluster type, e.g. mysql/redis/mongodb

    -

    componentDefs provides cluster components definitions.


    +

    componentDefs provides cluster components definitions.

    (Optional) -

    Connection credential template used for creating a connection credential
    secret for cluster.apps.kubeblocks.io object.



    Built-in objects are:
    - $(RANDOM_PASSWD) - random 8 characters.
    - $(STRONG_RANDOM_PASSWD) - random 16 characters, with mixed cases, digits and symbols.
    - $(UUID) - generate a random UUID v4 string.
    - $(UUID_B64) - generate a random UUID v4 BASE64 encoded string.
    - $(UUID_STR_B64) - generate a random UUID v4 string then BASE64 encoded.
    - $(UUID_HEX) - generate a random UUID v4 HEX representation.
    - $(HEADLESS_SVC_FQDN) - headless service FQDN placeholder, value pattern - $(CLUSTER_NAME)-$(1ST_COMP_NAME)-headless.$(NAMESPACE).svc,
    where 1ST_COMP_NAME is the 1st component that provide ClusterDefinition.spec.componentDefs[].service attribute;
    - $(SVC_FQDN) - service FQDN placeholder, value pattern - $(CLUSTER_NAME)-$(1ST_COMP_NAME).$(NAMESPACE).svc,
    where 1ST_COMP_NAME is the 1st component that provide ClusterDefinition.spec.componentDefs[].service attribute;
    - $(SVC_PORT_{PORT-NAME}) - a ServicePort’s port value with specified port name, i.e, a servicePort JSON struct:
    {"name": "mysql", "targetPort": "mysqlContainerPort", "port": 3306}, and “$(SVC_PORT_mysql)” in the
    connection credential value is 3306.


    +

    Connection credential template used for creating a connection credential +secret for cluster.apps.kubeblocks.io object.

    +

    Built-in objects are:

    +
      +
    • $(RANDOM_PASSWD) random 8 characters. +dfjksgks
    • +
    • $(STRONG_RANDOM_PASSWD) random 16 characters, with mixed cases, digits and symbols.
    • +
    • $(UUID) generate a random UUID v4 string.
    • +
    • $(UUID_B64) generate a random UUID v4 BASE64 encoded string.
    • +
    • $(UUID_STR_B64) generate a random UUID v4 string then BASE64 encoded.
    • +
    • $(UUID_HEX) generate a random UUID v4 HEX representation.
    • +
    • $(HEADLESS_SVC_FQDN) headless service FQDN placeholder, value pattern is $(CLUSTER_NAME)-$(1ST_COMP_NAME)-headless.$(NAMESPACE).svc, +where 1ST_COMP_NAME is the 1st component that provide ClusterDefinition.spec.componentDefs[].service attribute;
    • +
    • $(SVC_FQDN) service FQDN placeholder, value pattern is $(CLUSTER_NAME)-$(1ST_COMP_NAME).$(NAMESPACE).svc, +where 1ST_COMP_NAME is the 1st component that provide ClusterDefinition.spec.componentDefs[].service attribute;
    • +
    • $(SVC_PORT_{PORT-NAME}) is ServicePort’s port value with specified port name, i.e, a servicePort JSON struct: +{"name": "mysql", "targetPort": "mysqlContainerPort", "port": 3306}, and $(SVC_PORT_mysql) in the +connection credential value is 3306.
    • +
    @@ -552,7 +585,7 @@ ClusterDefinitionStatus

    ClusterVersion

    -

    ClusterVersion is the Schema for the ClusterVersions API


    +

    ClusterVersion is the Schema for the ClusterVersions API

    @@ -612,7 +645,7 @@ string @@ -625,7 +658,7 @@ string
    -

    ref ClusterDefinition.


    +

    ref ClusterDefinition.

    -

    List of components’ containers versioning context, i.e., container image ID, container commands, args., and environments.


    +

    List of components’ containers versioning context, i.e., container image ID, container commands, args., and environments.

    @@ -648,7 +681,7 @@ ClusterVersionStatus

    Component

    -

    Component is the Schema for the components API


    +

    Component is the Schema for the components API

    @@ -708,7 +741,7 @@ string @@ -722,7 +755,7 @@ ClassDefRef @@ -736,7 +769,11 @@ ClassDefRef @@ -750,7 +787,7 @@ Kubernetes core/v1.ResourceRequirements @@ -764,7 +801,7 @@ Kubernetes core/v1.ResourceRequirements @@ -775,7 +812,7 @@ int32 @@ -800,7 +837,10 @@ bool @@ -812,7 +852,8 @@ bool @@ -824,7 +865,7 @@ string @@ -838,7 +879,8 @@ Affinity @@ -852,7 +894,8 @@ Affinity @@ -872,24 +915,33 @@ TLSConfig @@ -901,7 +953,7 @@ github.com/apecloud/kubeblocks/apis/workloads/v1alpha1.RsmTransformPolicy
    -

    compDef is the name of the referenced componentDefinition.


    +

    compDef is the name of the referenced componentDefinition.

    (Optional) -

    classDefRef references the class defined in ComponentClassDefinition.


    +

    classDefRef references the class defined in ComponentClassDefinition.

    (Optional) -

    serviceRefs define service references for the current component. Based on the referenced services, they can be categorized into two types:
    Service provided by external sources: These services are provided by external sources and are not managed by KubeBlocks. They can be Kubernetes-based or non-Kubernetes services. For external services, you need to provide an additional ServiceDescriptor object to establish the service binding.
    Service provided by other KubeBlocks clusters: These services are provided by other KubeBlocks clusters. You can bind to these services by specifying the name of the hosting cluster.
    Each type of service reference requires specific configurations and bindings to establish the connection and interaction with the respective services.
    It should be noted that the ServiceRef has cluster-level semantic consistency, meaning that within the same Cluster, service references with the same ServiceRef.Name are considered to be the same service. It is only allowed to bind to the same Cluster or ServiceDescriptor.


    +

    serviceRefs define service references for the current component. Based on the referenced services, they can be categorized into two types: +Service provided by external sources: These services are provided by external sources and are not managed by KubeBlocks. They can be Kubernetes-based or non-Kubernetes services. For external services, you need to provide an additional ServiceDescriptor object to establish the service binding. +Service provided by other KubeBlocks clusters: These services are provided by other KubeBlocks clusters. You can bind to these services by specifying the name of the hosting cluster. +Each type of service reference requires specific configurations and bindings to establish the connection and interaction with the respective services. +It should be noted that the ServiceRef has cluster-level semantic consistency, meaning that within the same Cluster, service references with the same ServiceRef.Name are considered to be the same service. It is only allowed to bind to the same Cluster or ServiceDescriptor.

    (Optional) -

    Resources requests and limits of workload.


    +

    Resources requests and limits of workload.

    (Optional) -

    VolumeClaimTemplates information for statefulset.spec.volumeClaimTemplates.


    +

    VolumeClaimTemplates information for statefulset.spec.volumeClaimTemplates.

    -

    Replicas specifies the desired number of replicas for the component’s workload.


    +

    Replicas specifies the desired number of replicas for the component’s workload.

    (Optional) -

    monitor is a switch to enable monitoring and is set as false by default.
    KubeBlocks provides an extension mechanism to support component level monitoring,
    which will scrape metrics auto or manually from servers in component and export
    metrics to Time Series Database.


    +

    monitor is a switch to enable monitoring and is set as false by default. +KubeBlocks provides an extension mechanism to support component level monitoring, +which will scrape metrics auto or manually from servers in component and export +metrics to Time Series Database.

    (Optional) -

    enabledLogs indicates which log file takes effect in the database cluster,
    element is the log type which is defined in ComponentDefinition logConfig.name.


    +

    enabledLogs indicates which log file takes effect in the database cluster, +element is the log type which is defined in ComponentDefinition logConfig.name.

    (Optional) -

    serviceAccountName is the name of the ServiceAccount that running component depends on.


    +

    serviceAccountName is the name of the ServiceAccount that running component depends on.

    (Optional) -

    Affinity specifies the scheduling constraints for the component’s workload.
    If specified, it will override the cluster-wide affinity.


    +

    Affinity specifies the scheduling constraints for the component’s workload. +If specified, it will override the cluster-wide affinity.

    (Optional) -

    Tolerations specify the tolerations for the component’s workload.
    If specified, they will override the cluster-wide toleration settings.


    +

    Tolerations specify the tolerations for the component’s workload. +If specified, they will override the cluster-wide toleration settings.

    rsmTransformPolicy
    -github.com/apecloud/kubeblocks/apis/workloads/v1alpha1.RsmTransformPolicy + +RsmTransformPolicy +
    (Optional) -

    RsmTransformPolicy defines the policy generate sts using rsm.
    ToSts: rsm transform to statefulSet
    ToPod: rsm transform to pods


    +

    RsmTransformPolicy defines the policy generate sts using rsm. +ToSts: rsm transform to statefulSet +ToPod: rsm transform to pods

    nodes
    + []k8s.io/apimachinery/pkg/types.NodeName +
    (Optional) -

    Nodes defines the list of nodes that pods can schedule
    If the RsmTransformPolicy is specified as OneToMul,the list of nodes will be used. If the list of nodes is empty,
    no specific node will be assigned. However, if the list of node is filled, all pods will be evenly scheduled
    across the nodes in the list.


    +

    Nodes defines the list of nodes that pods can schedule +If the RsmTransformPolicy is specified as OneToMul,the list of nodes will be used. If the list of nodes is empty, +no specific node will be assigned. However, if the list of node is filled, all pods will be evenly scheduled +across the nodes in the list.

    (Optional) -

    Instances defines the list of instance to be deleted priorly


    +

    Instances defines the list of instance to be deleted priorly

    @@ -924,7 +976,7 @@ ComponentStatus

    ComponentClassDefinition

    -

    ComponentClassDefinition is the Schema for the componentclassdefinitions API


    +

    ComponentClassDefinition is the Schema for the componentclassdefinitions API

    @@ -987,7 +1039,7 @@ ComponentClassDefinitionSpec
    (Optional) -

    group defines a list of class series that conform to the same constraint.


    +

    group defines a list of class series that conform to the same constraint.

    @@ -1010,7 +1062,7 @@ ComponentClassDefinitionStatus

    ComponentDefinition

    -

    ComponentDefinition is the Schema for the componentdefinitions API


    +

    ComponentDefinition is the Schema for the componentdefinitions API

    @@ -1071,7 +1123,7 @@ string @@ -1083,7 +1135,7 @@ string @@ -1095,7 +1147,8 @@ string @@ -1107,7 +1160,8 @@ string @@ -1120,7 +1174,21 @@ Kubernetes core/v1.PodSpec @@ -1134,7 +1202,10 @@ Kubernetes core/v1.PodSpec @@ -1148,7 +1219,9 @@ Kubernetes core/v1.PodSpec @@ -1162,7 +1235,9 @@ Kubernetes core/v1.PodSpec @@ -1176,7 +1251,9 @@ Kubernetes core/v1.PodSpec @@ -1190,7 +1267,8 @@ Kubernetes core/v1.PodSpec @@ -1204,7 +1282,8 @@ MonitorConfig @@ -1218,7 +1297,9 @@ MonitorConfig @@ -1232,7 +1313,9 @@ MonitorConfig @@ -1244,7 +1327,9 @@ map[string]string @@ -1258,7 +1343,8 @@ ReplicasLimit @@ -1272,7 +1358,8 @@ ReplicasLimit @@ -1286,7 +1373,8 @@ UpdateStrategy @@ -1300,7 +1388,8 @@ UpdateStrategy @@ -1314,7 +1403,8 @@ RoleArbitrator @@ -1328,7 +1418,9 @@ ComponentLifecycleActions @@ -1342,7 +1434,8 @@ ComponentLifecycleActions @@ -1354,7 +1447,9 @@ int32
    (Optional) -

    Provider is the name of the component provider.


    +

    Provider is the name of the component provider.

    (Optional) -

    Description is a brief description of the component.


    +

    Description is a brief description of the component.

    (Optional) -

    ServiceKind defines what kind of well-known service that the component provides (e.g., MySQL, Redis, ETCD, case insensitive).
    Cannot be updated.


    +

    ServiceKind defines what kind of well-known service that the component provides (e.g., MySQL, Redis, ETCD, case insensitive). +Cannot be updated.

    (Optional) -

    ServiceVersion defines the version of the well-known service that the component provides.
    Cannot be updated.


    +

    ServiceVersion defines the version of the well-known service that the component provides. +Cannot be updated.

    -

    Runtime defines primarily runtime information for the component, including:
    - Init containers
    - Containers
    - Image
    - Commands
    - Args
    - Envs
    - Mounts
    - Ports
    - Security context
    - Probes
    - Lifecycle
    - Volumes
    CPU and memory resource limits, as well as scheduling settings (affinity, toleration, priority), should not be configured within this structure.
    Cannot be updated.


    +

    Runtime defines primarily runtime information for the component, including: +- Init containers +- Containers +- Image +- Commands +- Args +- Envs +- Mounts +- Ports +- Security context +- Probes +- Lifecycle +- Volumes +CPU and memory resource limits, as well as scheduling settings (affinity, toleration, priority), should not be configured within this structure. +Cannot be updated.

    (Optional) -

    Vars represents user-defined variables.
    These variables can be utilized as environment variables for Pods and Actions, or to render the templates of config and script.
    When used as environment variables, these variables are placed in front of the environment variables declared in the Pod.
    Cannot be updated.


    +

    Vars represents user-defined variables. +These variables can be utilized as environment variables for Pods and Actions, or to render the templates of config and script. +When used as environment variables, these variables are placed in front of the environment variables declared in the Pod. +Cannot be updated.

    (Optional) -

    Volumes defines the persistent volumes needed by the component.
    The users are responsible for providing these volumes when creating a component instance.
    Cannot be updated.


    +

    Volumes defines the persistent volumes needed by the component. +The users are responsible for providing these volumes when creating a component instance. +Cannot be updated.

    (Optional) -

    Services defines endpoints that can be used to access the component service to manage the component.
    In addition, a reserved headless service will be created by default, with the name pattern {clusterName}-{componentName}-headless.
    Cannot be updated.


    +

    Services defines endpoints that can be used to access the component service to manage the component. +In addition, a reserved headless service will be created by default, with the name pattern {clusterName}-{componentName}-headless. +Cannot be updated.

    (Optional) -

    The configs field provided by provider, and
    finally this configTemplateRefs will be rendered into the user’s own configuration file according to the user’s cluster.
    Cannot be updated.
    TODO: support referencing configs from other components or clusters.


    +

    The configs field provided by provider, and +finally this configTemplateRefs will be rendered into the user’s own configuration file according to the user’s cluster. +Cannot be updated.

    (Optional) -

    LogConfigs is detail log file config which provided by provider.
    Cannot be updated.


    +

    LogConfigs is detail log file config which provided by provider. +Cannot be updated.

    (Optional) -

    Monitor is monitoring config which provided by provider.
    Cannot be updated.


    +

    Monitor is monitoring config which provided by provider. +Cannot be updated.

    (Optional) -

    The scripts field provided by provider, and
    finally this configTemplateRefs will be rendered into the user’s own configuration file according to the user’s cluster.
    Cannot be updated.


    +

    The scripts field provided by provider, and +finally this configTemplateRefs will be rendered into the user’s own configuration file according to the user’s cluster. +Cannot be updated.

    (Optional) -

    PolicyRules defines the namespaced policy rules required by the component.
    If any rule application fails (e.g., due to lack of permissions), the provisioning of the component instance will also fail.
    Cannot be updated.


    +

    PolicyRules defines the namespaced policy rules required by the component. +If any rule application fails (e.g., due to lack of permissions), the provisioning of the component instance will also fail. +Cannot be updated.

    (Optional) -

    Labels defines static labels that will be patched to all k8s resources created for the component.
    If a label key conflicts with any other system labels or user-specified labels, it will be silently ignored.
    Cannot be updated.


    +

    Labels defines static labels that will be patched to all k8s resources created for the component. +If a label key conflicts with any other system labels or user-specified labels, it will be silently ignored. +Cannot be updated.

    (Optional) -

    ReplicasLimit defines the limit of valid replicas supported.
    Cannot be updated.


    +

    ReplicasLimit defines the limit of valid replicas supported. +Cannot be updated.

    (Optional) -

    SystemAccounts defines the pre-defined system accounts required to manage the component.
    TODO(component): accounts KB required
    Cannot be updated.


    +

    SystemAccounts defines the pre-defined system accounts required to manage the component. +Cannot be updated.

    (Optional) -

    UpdateStrategy defines the strategy for updating the component instance.
    Cannot be updated.


    +

    UpdateStrategy defines the strategy for updating the component instance. +Cannot be updated.

    (Optional) -

    Roles defines all the roles that the component can assume.
    Cannot be updated.


    +

    Roles defines all the roles that the component can assume. +Cannot be updated.

    (Optional) -

    RoleArbitrator defines the strategy for electing the component’s active role.
    Cannot be updated.


    +

    RoleArbitrator defines the strategy for electing the component’s active role. +Cannot be updated.

    (Optional) -

    LifecycleActions defines the operational actions that needed to interoperate with the component
    service and processes for lifecycle management.
    Cannot be updated.


    +

    LifecycleActions defines the operational actions that needed to interoperate with the component +service and processes for lifecycle management. +Cannot be updated.

    (Optional) -

    ServiceRefDeclarations is used to declare the service reference of the current component.
    Cannot be updated.


    +

    ServiceRefDeclarations is used to declare the service reference of the current component. +Cannot be updated.

    (Optional) -

    Minimum number of seconds for which a newly created pod should be ready
    without any of its container crashing for it to be considered available.
    Defaults to 0 (pod will be considered available as soon as it is ready)


    +

    Minimum number of seconds for which a newly created pod should be ready +without any of its container crashing for it to be considered available. +Defaults to 0 (pod will be considered available as soon as it is ready)

    @@ -1377,7 +1472,7 @@ ComponentDefinitionStatus

    ComponentResourceConstraint

    -

    ComponentResourceConstraint is the Schema for the componentresourceconstraints API


    +

    ComponentResourceConstraint is the Schema for the componentresourceconstraints API

    @@ -1439,7 +1534,7 @@ ComponentResourceConstraintSpec @@ -1453,7 +1548,7 @@ ComponentResourceConstraintSpec @@ -1467,7 +1562,7 @@ ComponentResourceConstraintSpec
    -

    Component resource constraint rules.


    +

    Component resource constraint rules.

    (Optional) -

    selector is used to bind the resource constraint to cluster definitions based on ClusterDefinition API.


    +

    selector is used to bind the resource constraint to cluster definitions based on ClusterDefinition API.

    (Optional) -

    componentSelector is used to bind the resource constraint to components based on ComponentDefinition API.


    +

    componentSelector is used to bind the resource constraint to components based on ComponentDefinition API.

    @@ -1478,7 +1573,7 @@ ComponentResourceConstraintSpec

    ConfigConstraint

    -

    ConfigConstraint is the Schema for the configconstraint API


    +

    ConfigConstraint is the Schema for the configconstraint API

    @@ -1541,7 +1636,9 @@ ReloadOptions @@ -1555,7 +1652,7 @@ ToolsImageSpec @@ -1569,7 +1666,7 @@ ToolsImageSpec @@ -1583,7 +1680,7 @@ ToolsImageSpec @@ -1595,7 +1692,7 @@ string @@ -1609,7 +1706,7 @@ CustomParametersValidation @@ -1621,7 +1718,7 @@ CustomParametersValidation @@ -1633,7 +1730,7 @@ CustomParametersValidation @@ -1645,7 +1742,7 @@ CustomParametersValidation @@ -1658,7 +1755,8 @@ Kubernetes meta/v1.LabelSelector @@ -1671,7 +1769,10 @@ FormatterConfig
    (Optional) -

    reloadOptions indicates whether the process supports reload.
    if set, the controller will determine the behavior of the engine instance based on the configuration templates,
    restart or reload depending on whether any parameters in the StaticParameters have been modified.


    +

    reloadOptions indicates whether the process supports reload. +if set, the controller will determine the behavior of the engine instance based on the configuration templates, +restart or reload depending on whether any parameters in the StaticParameters have been modified.

    (Optional) -

    toolConfig used to config init container.


    +

    toolConfig used to config init container.

    (Optional) -

    downwardAPIOptions is used to watch pod fields.


    +

    downwardAPIOptions is used to watch pod fields.

    (Optional) -

    scriptConfigs, list of ScriptConfig, witch these scripts can be used by volume trigger,downward trigger, or tool image


    +

    scriptConfigs, list of ScriptConfig, witch these scripts can be used by volume trigger,downward trigger, or tool image

    (Optional) -

    cfgSchemaTopLevelName is cue type name, which generates openapi schema.


    +

    cfgSchemaTopLevelName is cue type name, which generates openapi schema.

    (Optional) -

    configurationSchema imposes restrictions on database parameter’s rule.


    +

    configurationSchema imposes restrictions on database parameter’s rule.

    (Optional) -

    staticParameters, list of StaticParameter, modifications of them trigger a process restart.


    +

    staticParameters, list of StaticParameter, modifications of them trigger a process restart.

    (Optional) -

    dynamicParameters, list of DynamicParameter, modifications of them trigger a config dynamic reload without process restart.


    +

    dynamicParameters, list of DynamicParameter, modifications of them trigger a config dynamic reload without process restart.

    (Optional) -

    immutableParameters describes parameters that prohibit user from modification.


    +

    immutableParameters describes parameters that prohibit user from modification.

    -

    selector is used to match the label on the pod,
    for example, a pod of the primary is match on the patroni cluster.


    +

    selector is used to match the label on the pod, +for example, a pod of the primary is match on the patroni cluster.

    -

    formatterConfig describes the format of the configuration file, the controller
    1. parses configuration file
    2. analyzes the modified parameters
    3. applies corresponding policies.


    +

    formatterConfig describes the format of the configuration file, the controller +1. parses configuration file +2. analyzes the modified parameters +3. applies corresponding policies.

    @@ -1694,7 +1795,7 @@ ConfigConstraintStatus

    Configuration

    -

    Configuration is the Schema for the configurations API


    +

    Configuration is the Schema for the configurations API

    @@ -1754,7 +1855,7 @@ string @@ -1765,7 +1866,7 @@ string @@ -1779,7 +1880,7 @@ string
    -

    clusterRef references Cluster name.


    +

    clusterRef references Cluster name.

    -

    componentName is cluster component name.


    +

    componentName is cluster component name.

    (Optional) -

    customConfigurationItems describes user-defined config template.


    +

    customConfigurationItems describes user-defined config template.

    @@ -1802,7 +1903,7 @@ ConfigurationStatus

    OpsDefinition

    -

    OpsDefinition is the Schema for the opsdefinitions API


    +

    OpsDefinition is the Schema for the opsdefinitions API

    @@ -1864,7 +1965,9 @@ OpsDefinitionSpec @@ -1878,7 +1981,7 @@ VarsRef @@ -1892,7 +1995,7 @@ ParametersSchema @@ -1905,7 +2008,7 @@ Kubernetes batch/v1.JobSpec @@ -1919,7 +2022,7 @@ Kubernetes batch/v1.JobSpec
    -

    componentDefinitionRefs indicates which types of componentDefinitions are supported by the operation,
    and can refer some vars of the componentDefinition.
    if it is set, the component that does not meet the conditions will be intercepted.


    +

    componentDefinitionRefs indicates which types of componentDefinitions are supported by the operation, +and can refer some vars of the componentDefinition. +if it is set, the component that does not meet the conditions will be intercepted.

    (Optional) -

    varsRef defines the envs that need to be referenced from the target component pod, and will inject to job’s containers.


    +

    varsRef defines the envs that need to be referenced from the target component pod, and will inject to job’s containers.

    (Optional) -

    parametersSchema describes the schema used for validation, pruning, and defaulting.


    +

    parametersSchema describes the schema used for validation, pruning, and defaulting.

    -

    jobSpec describes the job spec for the operation.


    +

    jobSpec describes the job spec for the operation.

    (Optional) -

    preCondition if it meets the requirements to run the job for the operation.


    +

    preCondition if it meets the requirements to run the job for the operation.

    @@ -1942,7 +2045,7 @@ OpsDefinitionStatus

    OpsRequest

    -

    OpsRequest is the Schema for the opsrequests API


    +

    OpsRequest is the Schema for the opsrequests API

    @@ -2002,7 +2105,7 @@ string @@ -2014,7 +2117,8 @@ bool @@ -2027,7 +2131,7 @@ OpsType @@ -2039,7 +2143,7 @@ int32 @@ -2053,7 +2157,7 @@ Upgrade @@ -2067,7 +2171,7 @@ Upgrade @@ -2081,7 +2185,7 @@ Upgrade @@ -2095,7 +2199,7 @@ Upgrade @@ -2109,7 +2213,7 @@ Upgrade @@ -2123,7 +2227,7 @@ Upgrade @@ -2137,7 +2241,7 @@ Reconfigure @@ -2151,7 +2255,7 @@ Reconfigure @@ -2165,7 +2269,7 @@ Reconfigure @@ -2179,7 +2283,7 @@ RestoreFromSpec @@ -2191,7 +2295,8 @@ int32 @@ -2205,7 +2310,7 @@ ScriptSpec @@ -2219,7 +2324,7 @@ BackupSpec @@ -2233,7 +2338,8 @@ RestoreSpec @@ -2268,7 +2374,7 @@ OpsRequestStatus

    ServiceDescriptor

    -

    ServiceDescriptor is the Schema for the servicedescriptors API


    +

    ServiceDescriptor is the Schema for the servicedescriptors API

    -

    clusterRef references cluster object.


    +

    clusterRef references cluster object.

    (Optional) -

    cancel defines the action to cancel the Pending/Creating/Running opsRequest, supported types: [VerticalScaling, HorizontalScaling].
    once cancel is set to true, this opsRequest will be canceled and modifying this property again will not take effect.


    +

    cancel defines the action to cancel the Pending/Creating/Running opsRequest, supported types: [VerticalScaling, HorizontalScaling]. +once cancel is set to true, this opsRequest will be canceled and modifying this property again will not take effect.

    -

    type defines the operation type.


    +

    type defines the operation type.

    (Optional) -

    ttlSecondsAfterSucceed OpsRequest will be deleted after TTLSecondsAfterSucceed second when OpsRequest.status.phase is Succeed.


    +

    ttlSecondsAfterSucceed OpsRequest will be deleted after TTLSecondsAfterSucceed second when OpsRequest.status.phase is Succeed.

    (Optional) -

    upgrade specifies the cluster version by specifying clusterVersionRef.


    +

    upgrade specifies the cluster version by specifying clusterVersionRef.

    (Optional) -

    horizontalScaling defines what component need to horizontal scale the specified replicas.


    +

    horizontalScaling defines what component need to horizontal scale the specified replicas.

    (Optional) -

    volumeExpansion defines what component and volumeClaimTemplate need to expand the specified storage.


    +

    volumeExpansion defines what component and volumeClaimTemplate need to expand the specified storage.

    (Optional) -

    restart the specified components.


    +

    restart the specified components.

    (Optional) -

    switchover the specified components.


    +

    switchover the specified components.

    (Optional) -

    verticalScaling defines what component need to vertical scale the specified compute resources.


    +

    verticalScaling defines what component need to vertical scale the specified compute resources.

    (Optional) -

    reconfigure defines the variables that need to input when updating configuration.


    +

    reconfigure defines the variables that need to input when updating configuration.

    (Optional) -

    reconfigure defines the variables that need to input when updating configuration.


    +

    reconfigure defines the variables that need to input when updating configuration.

    (Optional) -

    expose defines services the component needs to expose.


    +

    expose defines services the component needs to expose.

    (Optional) -

    cluster RestoreFrom backup or point in time


    +

    cluster RestoreFrom backup or point in time

    (Optional) -

    ttlSecondsBeforeAbort OpsRequest will wait at most TTLSecondsBeforeAbort seconds for start-conditions to be met.
    If not specified, the default value is 0, which means that the start-conditions must be met immediately.


    +

    ttlSecondsBeforeAbort OpsRequest will wait at most TTLSecondsBeforeAbort seconds for start-conditions to be met. +If not specified, the default value is 0, which means that the start-conditions must be met immediately.

    (Optional) -

    scriptSpec defines the script to be executed.


    +

    scriptSpec defines the script to be executed.

    (Optional) -

    backupSpec defines how to backup the cluster.


    +

    backupSpec defines how to backup the cluster.

    (Optional) -

    restoreSpec defines how to restore the cluster.
    note that this restore operation will roll back cluster services.


    +

    restoreSpec defines how to restore the cluster. +note that this restore operation will roll back cluster services.

    @@ -2328,7 +2434,9 @@ string @@ -2339,7 +2447,7 @@ string @@ -2353,7 +2461,7 @@ CredentialVar @@ -2367,7 +2475,7 @@ ConnectionCredentialAuth @@ -2381,7 +2489,7 @@ CredentialVar
    -

    service kind, indicating the type or nature of the service. It should be well-known application cluster type, e.g. {mysql, redis, mongodb}.
    The serviceKind is case-insensitive and supports abbreviations for some well-known databases.
    For example, both ‘zk’ and ‘zookeeper’ will be considered as a ZooKeeper cluster, and ‘pg’, ‘postgres’, ‘postgresql’ will all be considered as a PostgreSQL cluster.


    +

    service kind, indicating the type or nature of the service. It should be well-known application cluster type, e.g. {mysql, redis, mongodb}. +The serviceKind is case-insensitive and supports abbreviations for some well-known databases. +For example, both ‘zk’ and ‘zookeeper’ will be considered as a ZooKeeper cluster, and ‘pg’, ‘postgres’, ‘postgresql’ will all be considered as a PostgreSQL cluster.

    -

    The version of the service reference.


    +

    The version of the service reference.

    (Optional) -

    endpoint is the endpoint of the service connection credential.


    +

    endpoint is the endpoint of the service connection credential.

    (Optional) -

    auth is the auth of the service connection credential.


    +

    auth is the auth of the service connection credential.

    (Optional) -

    port is the port of the service connection credential.


    +

    port is the port of the service connection credential.

    @@ -2407,7 +2515,7 @@ ServiceDescriptorStatus (Appears on:ConsensusMember)

    -

    AccessMode defines SVC access mode enums.


    +

    AccessMode defines SVC access mode enums.

    @@ -2430,7 +2538,7 @@ ServiceDescriptorStatus (Appears on:SystemAccountConfig)

    -

    AccountName defines system account names.


    +

    AccountName defines system account names.

    @@ -2457,7 +2565,13 @@ ServiceDescriptorStatus (Appears on:ComponentSwitchover, LifecycleActionHandler)

    -

    Action defines an operational action that can be performed by a component instance.
    There are some pre-defined environment variables that can be used when writing action commands, check @BuiltInVars for reference.



    An action is considered successful if it returns 0 (or HTTP 200 for HTTP(s) actions). Any other return value or
    HTTP status code is considered as a failure, and the action may be retried based on the configured retry policy.



    If an action exceeds the specified timeout duration, it will be terminated, and the action is considered failed.
    If an action produces any data as output, it should be written to stdout (or included in the HTTP response payload for HTTP(s) actions).
    If an action encounters any errors, error messages should be written to stderr (or included in the HTTP response payload with a non-200 HTTP status code).


    +

    Action defines an operational action that can be performed by a component instance. +There are some pre-defined environment variables that can be used when writing action commands, check @BuiltInVars for reference.

    +

    An action is considered successful if it returns 0 (or HTTP 200 for HTTP(s) actions). Any other return value or +HTTP status code is considered as a failure, and the action may be retried based on the configured retry policy.

    +

    If an action exceeds the specified timeout duration, it will be terminated, and the action is considered failed. +If an action produces any data as output, it should be written to stdout (or included in the HTTP response payload for HTTP(s) actions). +If an action encounters any errors, error messages should be written to stderr (or included in the HTTP response payload with a non-200 HTTP status code).

    @@ -2476,7 +2590,8 @@ string @@ -2490,7 +2605,8 @@ ExecAction @@ -2504,7 +2620,8 @@ HTTPAction @@ -2518,7 +2635,8 @@ HTTPAction @@ -2532,7 +2650,9 @@ TargetPodSelector @@ -2544,7 +2664,10 @@ string @@ -2556,7 +2679,10 @@ string @@ -2568,7 +2694,8 @@ int32 @@ -2582,7 +2709,8 @@ RetryPolicy @@ -2596,7 +2724,18 @@ PreConditionType @@ -2627,7 +2766,9 @@ PodAntiAffinity @@ -2639,7 +2780,11 @@ PodAntiAffinity @@ -2651,7 +2796,7 @@ map[string]string @@ -2665,7 +2810,9 @@ TenancyType @@ -2694,7 +2841,7 @@ string @@ -2705,7 +2852,7 @@ string (Appears on:ClusterSpec)

    -

    AvailabilityPolicyType for cluster affinity policy.


    +

    AvailabilityPolicyType for cluster affinity policy.

    (Optional) -

    Image defines the container image to run the action.
    Cannot be updated.


    +

    Image defines the container image to run the action. +Cannot be updated.

    (Optional) -

    Exec specifies the action to take.
    Cannot be updated.


    +

    Exec specifies the action to take. +Cannot be updated.

    (Optional) -

    HTTP specifies the http request to perform.
    Cannot be updated.


    +

    HTTP specifies the http request to perform. +Cannot be updated.

    (Optional) -

    List of environment variables to set in the container.
    Cannot be updated.


    +

    List of environment variables to set in the container. +Cannot be updated.

    (Optional) -

    TargetPodSelector defines the way that how to select the target Pod where the action will be performed,
    if there may not have a target replica by default.
    Cannot be updated.


    +

    TargetPodSelector defines the way that how to select the target Pod where the action will be performed, +if there may not have a target replica by default. +Cannot be updated.

    (Optional) -

    MatchingKey uses to select the target pod(s) actually.
    If the selector is AnyReplica or AllReplicas, the matchingKey will be ignored.
    If the selector is RoleSelector, any replica which has the same role with matchingKey will be chosen.
    Cannot be updated.


    +

    MatchingKey uses to select the target pod(s) actually. +If the selector is AnyReplica or AllReplicas, the matchingKey will be ignored. +If the selector is RoleSelector, any replica which has the same role with matchingKey will be chosen. +Cannot be updated.

    (Optional) -

    Container defines the name of the container within the target Pod where the action will be executed.
    If specified, it must be one of container declared in @Runtime.
    If not specified, the first container declared in @Runtime will be used.
    Cannot be updated.


    +

    Container defines the name of the container within the target Pod where the action will be executed. +If specified, it must be one of container declared in @Runtime. +If not specified, the first container declared in @Runtime will be used. +Cannot be updated.

    (Optional) -

    TimeoutSeconds defines the timeout duration for the action in seconds.
    Cannot be updated.


    +

    TimeoutSeconds defines the timeout duration for the action in seconds. +Cannot be updated.

    (Optional) -

    RetryPolicy defines the strategy for retrying the action in case of failure.
    Cannot be updated.


    +

    RetryPolicy defines the strategy for retrying the action in case of failure. +Cannot be updated.

    (Optional) -

    PreCondition defines the condition when the action will be executed.
    - Immediately: The Action is executed immediately after the Component object is created,
    without guaranteeing the availability of the Component and its underlying resources. only after the action is successfully executed will the Component’s state turn to ready.
    - RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready.
    only after the action is successfully executed will the Component’s state turn to ready.
    - ComponentReady: The Action is executed after the Component object is created and once the Component is ready.
    the execution process does not impact the state of the Component and the Cluster.
    - ClusterReady: The Action is executed after the Cluster object is created and once the Cluster is ready.
    the execution process does not impact the state of the Component and the Cluster.
    Cannot be updated.


    +

    PreCondition defines the condition when the action will be executed.

    +
      +
    • Immediately: The Action is executed immediately after the Component object is created, +without guaranteeing the availability of the Component and its underlying resources. only after the action is successfully executed will the Component’s state turn to ready.
    • +
    • RuntimeReady: The Action is executed after the Component object is created and once all underlying Runtimes are ready. +only after the action is successfully executed will the Component’s state turn to ready.
    • +
    • ComponentReady: The Action is executed after the Component object is created and once the Component is ready. +the execution process does not impact the state of the Component and the Cluster.
    • +
    • ClusterReady: The Action is executed after the Cluster object is created and once the Cluster is ready.
    • +
    +

    the execution process does not impact the state of the Component and the Cluster. +Cannot be updated.

    (Optional) -

    podAntiAffinity describes the anti-affinity level of pods within a component.
    Preferred means try spread pods by TopologyKeys.
    Required means must spread pods by TopologyKeys.


    +

    podAntiAffinity describes the anti-affinity level of pods within a component. +Preferred means try spread pods by TopologyKeys. +Required means must spread pods by TopologyKeys.

    (Optional) -

    topologyKey is the key of node labels.
    Nodes that have a label with this key and identical values are considered to be in the same topology.
    It’s used as the topology domain for pod anti-affinity and pod spread constraint.
    Some well-known label keys, such as “kubernetes.io/hostname” and “topology.kubernetes.io/zone”
    are often used as TopologyKey, as well as any other custom label key.


    +

    topologyKey is the key of node labels. +Nodes that have a label with this key and identical values are considered to be in the same topology. +It’s used as the topology domain for pod anti-affinity and pod spread constraint. +Some well-known label keys, such as “kubernetes.io/hostname” and “topology.kubernetes.io/zone” +are often used as TopologyKey, as well as any other custom label key.

    (Optional) -

    nodeLabels describes that pods must be scheduled to the nodes with the specified node labels.


    +

    nodeLabels describes that pods must be scheduled to the nodes with the specified node labels.

    (Optional) -

    tenancy describes how pods are distributed across node.
    SharedNode means multiple pods may share the same node.
    DedicatedNode means each pod runs on their own dedicated node.


    +

    tenancy describes how pods are distributed across node. +SharedNode means multiple pods may share the same node. +DedicatedNode means each pod runs on their own dedicated node.

    (Optional) -

    processName is process name


    +

    processName is process name

    @@ -2761,7 +2908,7 @@ TargetInstance @@ -2775,7 +2922,7 @@ TargetInstance @@ -2804,7 +2951,8 @@ string @@ -2816,7 +2964,8 @@ string @@ -2830,7 +2979,7 @@ TargetInstance @@ -2844,7 +2993,7 @@ TargetInstance @@ -2857,7 +3006,7 @@ TargetInstance @@ -2869,7 +3018,7 @@ int32 @@ -2880,7 +3029,7 @@ int32 (Appears on:BackupPolicyTemplate)

    -

    BackupPolicyTemplateSpec defines the desired state of BackupPolicyTemplate


    +

    BackupPolicyTemplateSpec defines the desired state of BackupPolicyTemplate

    (Optional) -

    target instance for backup.


    +

    target instance for backup.

    (Optional) -

    envMapping defines the variables of cluster mapped to env values’ keys.


    +

    envMapping defines the variables of cluster mapped to env values’ keys.

    (Optional) -

    componentDefRef references componentDef defined in ClusterDefinition spec. Need to
    comply with IANA Service Naming rule.


    +

    componentDefRef references componentDef defined in ClusterDefinition spec. Need to +comply with IANA Service Naming rule.

    (Optional) -

    componentDef references componentDefinition. Need to
    comply with IANA Service Naming rule.


    +

    componentDef references componentDefinition. Need to +comply with IANA Service Naming rule.

    (Optional) -

    target instance for backup.


    +

    target instance for backup.

    (Optional) -

    schedule policy for backup.


    +

    schedule policy for backup.

    -

    backupMethods defines the backup methods.


    +

    backupMethods defines the backup methods.

    (Optional) -

    Specifies the number of retries before marking the backup failed.


    +

    Specifies the number of retries before marking the backup failed.

    @@ -2898,7 +3047,7 @@ string @@ -2911,7 +3060,7 @@ string @@ -2923,7 +3072,10 @@ string @@ -2934,7 +3086,7 @@ string (Appears on:BackupPolicyTemplate)

    -

    BackupPolicyTemplateStatus defines the observed state of BackupPolicyTemplate


    +

    BackupPolicyTemplateStatus defines the observed state of BackupPolicyTemplate

    BackupRefSpec

    @@ -2962,7 +3114,7 @@ RefNamespaceName @@ -2991,7 +3143,7 @@ string @@ -3003,7 +3155,7 @@ string @@ -3015,7 +3167,7 @@ string @@ -3027,7 +3179,11 @@ string @@ -3039,7 +3195,19 @@ string @@ -3051,7 +3219,7 @@ string @@ -3059,12 +3227,12 @@ string

    BackupStatusUpdateStage (string alias)

    -

    BackupStatusUpdateStage defines the stage of backup status update.


    +

    BackupStatusUpdateStage defines the stage of backup status update.

    BaseBackupType (string alias)

    -

    BaseBackupType the base backup type, keep synchronized with the BaseBackupType of the data protection API.


    +

    BaseBackupType the base backup type, keep synchronized with the BaseBackupType of the data protection API.

    BuiltinActionHandlerType (string alias)

    @@ -3072,7 +3240,7 @@ string (Appears on:LifecycleActionHandler)

    -

    BuiltinActionHandlerType defines build-in action handlers provided by Lorry.


    +

    BuiltinActionHandlerType defines build-in action handlers provided by Lorry.

    -

    clusterDefinitionRef references ClusterDefinition name, this is an immutable attribute.


    +

    clusterDefinitionRef references ClusterDefinition name, this is an immutable attribute.

    -

    backupPolicies is a list of backup policy template for the specified componentDefinition.


    +

    backupPolicies is a list of backup policy template for the specified componentDefinition.

    (Optional) -

    Identifier is a unique identifier for this BackupPolicyTemplate.
    this identifier will be the suffix of the automatically generated backupPolicy name.
    and must be added when multiple BackupPolicyTemplates exist,
    otherwise the generated backupPolicy override will occur.


    +

    Identifier is a unique identifier for this BackupPolicyTemplate. +this identifier will be the suffix of the automatically generated backupPolicy name. +and must be added when multiple BackupPolicyTemplates exist, +otherwise the generated backupPolicy override will occur.

    (Optional) -

    specify a reference backup to restore


    +

    specify a reference backup to restore

    (Optional) -

    backupName is the name of the backup.


    +

    backupName is the name of the backup.

    (Optional) -

    Which backupPolicy is applied to perform this backup


    +

    Which backupPolicy is applied to perform this backup

    (Optional) -

    Backup method name that is defined in backupPolicy.


    +

    Backup method name that is defined in backupPolicy.

    (Optional) -

    deletionPolicy determines whether the backup contents stored in backup repository
    should be deleted when the backup custom resource is deleted.
    Supported values are “Retain” and “Delete”.
    “Retain” means that the backup content and its physical snapshot on backup repository are kept.
    “Delete” means that the backup content and its physical snapshot on backup repository are deleted.


    +

    deletionPolicy determines whether the backup contents stored in backup repository +should be deleted when the backup custom resource is deleted. +Supported values are “Retain” and “Delete”. +“Retain” means that the backup content and its physical snapshot on backup repository are kept. +“Delete” means that the backup content and its physical snapshot on backup repository are deleted.

    (Optional) -

    retentionPeriod determines a duration up to which the backup should be kept.
    Controller will remove all backups that are older than the RetentionPeriod.
    For example, RetentionPeriod of 30d will keep only the backups of last 30 days.
    Sample duration format:
    - years: 2y
    - months: 6mo
    - days: 30d
    - hours: 12h
    - minutes: 30m
    You can also combine the above durations. For example: 30d12h30m.
    If not set, the backup will be kept forever.


    +

    retentionPeriod determines a duration up to which the backup should be kept. +Controller will remove all backups that are older than the RetentionPeriod. +For example, RetentionPeriod of 30d will keep only the backups of last 30 days. +Sample duration format:

    +
      +
    • years: 2y
    • +
    • months: 6mo
    • +
    • days: 30d
    • +
    • hours: 12h
    • +
    • minutes: 30m
    • +
    +

    You can also combine the above durations. For example: 30d12h30m. +If not set, the backup will be kept forever.

    (Optional) -

    if backupType is incremental, parentBackupName is required.


    +

    if backupType is incremental, parentBackupName is required.

    @@ -3133,7 +3301,10 @@ Kubernetes resource.Quantity @@ -3147,7 +3318,10 @@ Kubernetes resource.Quantity @@ -3161,7 +3335,11 @@ Kubernetes resource.Quantity @@ -3175,7 +3353,8 @@ Kubernetes resource.Quantity @@ -3186,7 +3365,7 @@ Kubernetes resource.Quantity (Appears on:FormatterConfig)

    -

    CfgFileFormat defines formatter of configuration files.


    +

    CfgFileFormat defines formatter of configuration files.

    (Optional) -

    The maximum count of vcpu cores, [Min, Max] defines a range for valid vcpu cores, and the value in this range
    must be multiple times of Step. It’s useful to define a large number of valid values without defining them one by
    one. Please see the documentation for Step for some examples.
    If Slots is specified, Max, Min, and Step are ignored


    +

    The maximum count of vcpu cores, [Min, Max] defines a range for valid vcpu cores, and the value in this range +must be multiple times of Step. It’s useful to define a large number of valid values without defining them one by +one. Please see the documentation for Step for some examples. +If Slots is specified, Max, Min, and Step are ignored

    (Optional) -

    The minimum count of vcpu cores, [Min, Max] defines a range for valid vcpu cores, and the value in this range
    must be multiple times of Step. It’s useful to define a large number of valid values without defining them one by
    one. Please see the documentation for Step for some examples.
    If Slots is specified, Max, Min, and Step are ignored


    +

    The minimum count of vcpu cores, [Min, Max] defines a range for valid vcpu cores, and the value in this range +must be multiple times of Step. It’s useful to define a large number of valid values without defining them one by +one. Please see the documentation for Step for some examples. +If Slots is specified, Max, Min, and Step are ignored

    (Optional) -

    The minimum granularity of vcpu cores, [Min, Max] defines a range for valid vcpu cores and the value in this range must be
    multiple times of Step.
    For example:
    1. Min is 2, Max is 8, Step is 2, and the valid vcpu core is {2, 4, 6, 8}.
    2. Min is 0.5, Max is 2, Step is 0.5, and the valid vcpu core is {0.5, 1, 1.5, 2}.


    +

    The minimum granularity of vcpu cores, [Min, Max] defines a range for valid vcpu cores and the value in this range must be +multiple times of Step. +For example: +1. Min is 2, Max is 8, Step is 2, and the valid vcpu core is {2, 4, 6, 8}. +2. Min is 0.5, Max is 2, Step is 0.5, and the valid vcpu core is {0.5, 1, 1.5, 2}.

    (Optional) -

    The valid vcpu cores, it’s useful if you want to define valid vcpu cores explicitly.
    If Slots is specified, Max, Min, and Step are ignored


    +

    The valid vcpu cores, it’s useful if you want to define valid vcpu cores explicitly. +If Slots is specified, Max, Min, and Step are ignored

    @@ -3220,7 +3399,7 @@ Kubernetes resource.Quantity

    CfgReloadType (string alias)

    -

    CfgReloadType defines reload method.


    +

    CfgReloadType defines reload method.

    @@ -3267,7 +3446,7 @@ string @@ -3278,7 +3457,7 @@ string @@ -3307,7 +3486,7 @@ bool @@ -3319,7 +3498,18 @@ github.com/apecloud/kubeblocks/apis/dataprotection/v1alpha1.RetentionPeriod @@ -3331,7 +3521,7 @@ string @@ -3343,7 +3533,7 @@ string @@ -3355,7 +3545,8 @@ int64 @@ -3367,7 +3558,7 @@ string @@ -3379,7 +3570,7 @@ bool @@ -3390,7 +3581,9 @@ bool (Appears on:ClusterDefinitionSpec)

    -

    ClusterComponentDefinition provides a workload component specification template,
    with attributes that strongly work with stateful workloads and day-2 operations
    behaviors.


    +

    ClusterComponentDefinition provides a workload component specification template, +with attributes that strongly work with stateful workloads and day-2 operations +behaviors.

    (Optional) -

    Name refers to the name of the ComponentClassDefinition.


    +

    Name refers to the name of the ComponentClassDefinition.

    -

    Class refers to the name of the class that is defined in the ComponentClassDefinition.


    +

    Class refers to the name of the class that is defined in the ComponentClassDefinition.

    (Optional) -

    enabled defines whether to enable automated backup.


    +

    enabled defines whether to enable automated backup.

    (Optional) -

    retentionPeriod determines a duration up to which the backup should be kept.
    controller will remove all backups that are older than the RetentionPeriod.
    For example, RetentionPeriod of 30d will keep only the backups of last 30 days.
    Sample duration format:
    - years: 2y
    - months: 6mo
    - days: 30d
    - hours: 12h
    - minutes: 30m
    You can also combine the above durations. For example: 30d12h30m


    +

    retentionPeriod determines a duration up to which the backup should be kept. +controller will remove all backups that are older than the RetentionPeriod. +For example, RetentionPeriod of 30d will keep only the backups of last 30 days. +Sample duration format:

    +
      +
    • years: 2y
    • +
    • months: 6mo
    • +
    • days: 30d
    • +
    • hours: 12h
    • +
    • minutes: 30m
    • +
    +

    You can also combine the above durations. For example: 30d12h30m

    (Optional) -

    backup method name to use, that is defined in backupPolicy.


    +

    backup method name to use, that is defined in backupPolicy.

    (Optional) -

    the cron expression for schedule, the timezone is in UTC. see https://en.wikipedia.org/wiki/Cron.


    +

    the cron expression for schedule, the timezone is in UTC. see https://en.wikipedia.org/wiki/Cron.

    (Optional) -

    startingDeadlineMinutes defines the deadline in minutes for starting the backup job
    if it misses scheduled time for any reason.


    +

    startingDeadlineMinutes defines the deadline in minutes for starting the backup job +if it misses scheduled time for any reason.

    (Optional) -

    repoName is the name of the backupRepo, if not set, will use the default backupRepo.


    +

    repoName is the name of the backupRepo, if not set, will use the default backupRepo.

    (Optional) -

    pitrEnabled defines whether to enable point-in-time recovery.


    +

    pitrEnabled defines whether to enable point-in-time recovery.

    @@ -3408,7 +3601,10 @@ string @@ -3420,7 +3616,7 @@ string @@ -3433,7 +3629,11 @@ WorkloadType @@ -3445,7 +3645,10 @@ string @@ -3459,7 +3662,8 @@ string @@ -3473,7 +3677,8 @@ string @@ -3487,7 +3692,7 @@ ClusterDefinitionProbes @@ -3501,7 +3706,7 @@ MonitorConfig @@ -3515,7 +3720,7 @@ MonitorConfig @@ -3529,7 +3734,7 @@ Kubernetes core/v1.PodSpec @@ -3543,7 +3748,8 @@ ServiceSpec @@ -3557,7 +3763,7 @@ StatelessSetSpec @@ -3571,7 +3777,7 @@ StatefulSetSpec @@ -3585,7 +3791,7 @@ ConsensusSetSpec @@ -3599,7 +3805,7 @@ ReplicationSetSpec @@ -3613,7 +3819,9 @@ RSMSpec @@ -3627,7 +3835,7 @@ HorizontalScalePolicy @@ -3641,7 +3849,7 @@ SystemAccountSpec @@ -3655,7 +3863,17 @@ SystemAccountSpec @@ -3669,7 +3887,7 @@ SystemAccountSpec @@ -3683,7 +3901,8 @@ SwitchoverSpec @@ -3697,7 +3916,7 @@ PostStartAction @@ -3724,7 +3943,8 @@ VolumeProtectionSpec @@ -3738,7 +3958,7 @@ VolumeProtectionSpec @@ -3749,7 +3969,7 @@ VolumeProtectionSpec (Appears on:ClusterComponentStatus, ComponentStatus, OpsRequestComponentStatus)

    -

    ClusterComponentPhase defines the Cluster CR .status.components.phase


    +

    ClusterComponentPhase defines the Cluster CR .status.components.phase

    -

    A component definition name, this name could be used as default name of Cluster.spec.componentSpecs.name,
    and so this name is need to conform with same validation rules as Cluster.spec.componentSpecs.name, that
    is currently comply with IANA Service Naming rule. This name will apply to “apps.kubeblocks.io/component-name”
    object label value.


    +

    A component definition name, this name could be used as default name of Cluster.spec.componentSpecs.name, +and so this name is need to conform with same validation rules as Cluster.spec.componentSpecs.name, that +is currently comply with IANA Service Naming rule. This name will apply to “apps.kubeblocks.io/component-name” +object label value.

    (Optional) -

    The description of component definition.


    +

    The description of component definition.

    -

    workloadType defines type of the workload.
    Stateless is a stateless workload type used to describe stateless applications.
    Stateful is a stateful workload type used to describe common stateful applications.
    Consensus is a stateful workload type used to describe applications based on consensus protocols, common consensus protocols such as raft and paxos.
    Replication is a stateful workload type used to describe applications based on the primary-secondary data replication protocol.


    +

    workloadType defines type of the workload. +Stateless is a stateless workload type used to describe stateless applications. +Stateful is a stateful workload type used to describe common stateful applications. +Consensus is a stateful workload type used to describe applications based on consensus protocols, common consensus protocols such as raft and paxos. +Replication is a stateful workload type used to describe applications based on the primary-secondary data replication protocol.

    (Optional) -

    characterType defines well-known database component name, such as mongos(mongodb), proxy(redis), mariadb(mysql)
    KubeBlocks will generate proper monitor configs for well-known characterType when builtIn is true.



    CharacterType will also be used in role probe to decide which probe engine to use.
    current available candidates are: mysql, postgres, mongodb, redis, etcd, kafka.


    +

    characterType defines well-known database component name, such as mongos(mongodb), proxy(redis), mariadb(mysql) +KubeBlocks will generate proper monitor configs for well-known characterType when builtIn is true.

    +

    CharacterType will also be used in role probe to decide which probe engine to use. +current available candidates are: mysql, postgres, mongodb, redis, etcd, kafka.

    (Optional) -

    The configSpec field provided by provider, and
    finally this configTemplateRefs will be rendered into the user’s own configuration file according to the user’s cluster.


    +

    The configSpec field provided by provider, and +finally this configTemplateRefs will be rendered into the user’s own configuration file according to the user’s cluster.

    (Optional) -

    The scriptSpec field provided by provider, and
    finally this configTemplateRefs will be rendered into the user’s own configuration file according to the user’s cluster.


    +

    The scriptSpec field provided by provider, and +finally this configTemplateRefs will be rendered into the user’s own configuration file according to the user’s cluster.

    (Optional) -

    probes setting for healthy checks.


    +

    probes setting for healthy checks.

    (Optional) -

    monitor is monitoring config which provided by provider.


    +

    monitor is monitoring config which provided by provider.

    (Optional) -

    logConfigs is detail log file config which provided by provider.


    +

    logConfigs is detail log file config which provided by provider.

    (Optional) -

    podSpec define pod spec template of the cluster component.


    +

    podSpec define pod spec template of the cluster component.

    (Optional) -

    service defines the behavior of a service spec.
    provide read-write service when WorkloadType is Consensus.


    +

    service defines the behavior of a service spec. +provide read-write service when WorkloadType is Consensus.

    (Optional) -

    statelessSpec defines stateless related spec if workloadType is Stateless.


    +

    statelessSpec defines stateless related spec if workloadType is Stateless.

    (Optional) -

    statefulSpec defines stateful related spec if workloadType is Stateful.


    +

    statefulSpec defines stateful related spec if workloadType is Stateful.

    (Optional) -

    consensusSpec defines consensus related spec if workloadType is Consensus, required if workloadType is Consensus.


    +

    consensusSpec defines consensus related spec if workloadType is Consensus, required if workloadType is Consensus.

    (Optional) -

    replicationSpec defines replication related spec if workloadType is Replication.


    +

    replicationSpec defines replication related spec if workloadType is Replication.

    (Optional) -

    RSMSpec defines workload related spec of this component.
    start from KB 0.7.0, RSM(ReplicatedStateMachineSpec) will be the underlying CR which powers all kinds of workload in KB.
    RSM is an enhanced stateful workload extension dedicated for heavy-state workloads like databases.


    +

    RSMSpec defines workload related spec of this component. +start from KB 0.7.0, RSM(ReplicatedStateMachineSpec) will be the underlying CR which powers all kinds of workload in KB. +RSM is an enhanced stateful workload extension dedicated for heavy-state workloads like databases.

    (Optional) -

    horizontalScalePolicy controls the behavior of horizontal scale.


    +

    horizontalScalePolicy controls the behavior of horizontal scale.

    (Optional) -

    Statement to create system account.


    +

    Statement to create system account.

    (Optional) -

    volumeTypes is used to describe the purpose of the volumes
    mapping the name of the VolumeMounts in the PodSpec.Container field,
    such as data volume, log volume, etc.
    When backing up the volume, the volume can be correctly backed up
    according to the volumeType.



    For example:
    name: data, type: data means that the volume named data is used to store data.
    name: binlog, type: log means that the volume named binlog is used to store log.



    NOTE:
    When volumeTypes is not defined, the backup function will not be supported,
    even if a persistent volume has been specified.


    +

    volumeTypes is used to describe the purpose of the volumes +mapping the name of the VolumeMounts in the PodSpec.Container field, +such as data volume, log volume, etc. +When backing up the volume, the volume can be correctly backed up +according to the volumeType.

    +

    For example: +name: data, type: data means that the volume named data is used to store data. +name: binlog, type: log means that the volume named binlog is used to store log.

    +

    NOTE: +When volumeTypes is not defined, the backup function will not be supported, +even if a persistent volume has been specified.

    (Optional) -

    customLabelSpecs is used for custom label tags which you want to add to the component resources.


    +

    customLabelSpecs is used for custom label tags which you want to add to the component resources.

    (Optional) -

    switchoverSpec defines command to do switchover.
    in particular, when workloadType=Replication, the command defined in switchoverSpec will only be executed under the condition of cluster.componentSpecs[x].SwitchPolicy.type=Noop.


    +

    switchoverSpec defines command to do switchover. +in particular, when workloadType=Replication, the command defined in switchoverSpec will only be executed under the condition of cluster.componentSpecs[x].SwitchPolicy.type=Noop.

    (Optional) -

    postStartSpec defines the command to be executed when the component is ready, and the command will only be executed once after the component becomes ready.


    +

    postStartSpec defines the command to be executed when the component is ready, and the command will only be executed once after the component becomes ready.

    (Optional) -

    componentDefRef is used to inject values from other components into the current component.
    values will be saved and updated in a configmap and mounted to the current component.


    +

    componentDefRef is used to inject values from other components into the current component. +values will be saved and updated in a configmap and mounted to the current component.

    (Optional) -

    serviceRefDeclarations is used to declare the service reference of the current component.


    +

    serviceRefDeclarations is used to declare the service reference of the current component.

    @@ -3799,7 +4019,7 @@ string @@ -3813,7 +4033,20 @@ Kubernetes core/v1.ServiceType @@ -3825,7 +4058,8 @@ map[string]string @@ -3836,7 +4070,7 @@ map[string]string (Appears on:ClusterSpec, ShardingSpec)

    -

    ClusterComponentSpec defines the cluster component spec.
    //(TODO) +kubebuilder:validation:XValidation:rule=“!has(oldSelf.componentDefRef) || has(self.componentDefRef)”, message=“componentDefRef is required once set”
    //(TODO) +kubebuilder:validation:XValidation:rule=“!has(oldSelf.componentDef) || has(self.componentDef)”, message=“componentDef is required once set”


    +

    ClusterComponentSpec defines the cluster component spec.

    -

    Service name


    +

    Service name

    (Optional) -

    serviceType determines how the Service is exposed. Valid
    options are ClusterIP, NodePort, and LoadBalancer.
    “ClusterIP” allocates a cluster-internal IP address for load-balancing
    to endpoints. Endpoints are determined by the selector or if that is not
    specified, they are determined by manual construction of an Endpoints object or
    EndpointSlice objects. If clusterIP is “None”, no virtual IP is
    allocated and the endpoints are published as a set of endpoints rather
    than a virtual IP.
    “NodePort” builds on ClusterIP and allocates a port on every node which
    routes to the same endpoints as the clusterIP.
    “LoadBalancer” builds on NodePort and creates an external load-balancer
    (if supported in the current cloud) which routes to the same endpoints
    as the clusterIP.
    More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types.


    +

    serviceType determines how the Service is exposed. Valid +options are ClusterIP, NodePort, and LoadBalancer. +“ClusterIP” allocates a cluster-internal IP address for load-balancing +to endpoints. Endpoints are determined by the selector or if that is not +specified, they are determined by manual construction of an Endpoints object or +EndpointSlice objects. If clusterIP is “None”, no virtual IP is +allocated and the endpoints are published as a set of endpoints rather +than a virtual IP. +“NodePort” builds on ClusterIP and allocates a port on every node which +routes to the same endpoints as the clusterIP. +“LoadBalancer” builds on NodePort and creates an external load-balancer +(if supported in the current cloud) which routes to the same endpoints +as the clusterIP. +More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types.

    (Optional) -

    If ServiceType is LoadBalancer, cloud provider related parameters can be put here
    More info: https://kubernetes.io/docs/concepts/services-networking/service/#loadbalancer.


    +

    If ServiceType is LoadBalancer, cloud provider related parameters can be put here +More info: https://kubernetes.io/docs/concepts/services-networking/service/#loadbalancer.

    @@ -3855,7 +4089,8 @@ string @@ -3867,7 +4102,7 @@ string @@ -3879,7 +4114,8 @@ string @@ -3893,7 +4129,7 @@ ClassDefRef @@ -3907,7 +4143,11 @@ ClassDefRef @@ -3919,7 +4159,10 @@ bool @@ -3931,7 +4174,9 @@ bool @@ -3942,7 +4187,7 @@ int32 @@ -3956,7 +4201,7 @@ Affinity @@ -3970,7 +4215,7 @@ Affinity @@ -3984,7 +4229,7 @@ Kubernetes core/v1.ResourceRequirements @@ -3998,7 +4243,7 @@ Kubernetes core/v1.ResourceRequirements @@ -4012,7 +4257,7 @@ Kubernetes core/v1.ResourceRequirements @@ -4026,7 +4271,7 @@ ClusterSwitchPolicy @@ -4038,7 +4283,7 @@ bool @@ -4052,7 +4297,8 @@ Issuer @@ -4064,7 +4310,7 @@ string @@ -4078,7 +4324,8 @@ UpdateStrategy @@ -4092,31 +4339,40 @@ UserResourceRefs @@ -4128,7 +4384,8 @@ github.com/apecloud/kubeblocks/apis/workloads/v1alpha1.RsmTransformPolicy @@ -4139,7 +4396,7 @@ github.com/apecloud/kubeblocks/apis/workloads/v1alpha1.RsmTransformPolicy (Appears on:ClusterStatus)

    -

    ClusterComponentStatus records components status.


    +

    ClusterComponentStatus records components status.

    (Optional) -

    name defines cluster’s component name, this name is also part of Service DNS name, so this name will comply with IANA Service Naming rule.
    When ClusterComponentSpec is referenced as a template, name is optional. Otherwise, it is required.
    //(TODO) +kubebuilder:validation:XValidation:rule=“self == oldSelf”,message=“name is immutable”


    +

    name defines cluster’s component name, this name is also part of Service DNS name, so this name will comply with IANA Service Naming rule. +When ClusterComponentSpec is referenced as a template, name is optional. Otherwise, it is required.

    (Optional) -

    componentDefRef references componentDef defined in ClusterDefinition spec. Need to comply with IANA Service Naming rule.
    //(TODO) +kubebuilder:validation:XValidation:rule=“self == oldSelf”,message=“componentDefRef is immutable”


    +

    componentDefRef references componentDef defined in ClusterDefinition spec. Need to comply with IANA Service Naming rule.

    (Optional) -

    componentDef references the name of the ComponentDefinition.
    If both componentDefRef and componentDef are provided, the componentDef will take precedence over componentDefRef.
    //(TODO) +kubebuilder:validation:XValidation:rule=“self == oldSelf”,message=“componentDef is immutable”


    +

    componentDef references the name of the ComponentDefinition. +If both componentDefRef and componentDef are provided, the componentDef will take precedence over componentDefRef.

    (Optional) -

    classDefRef references the class defined in ComponentClassDefinition.


    +

    classDefRef references the class defined in ComponentClassDefinition.

    (Optional) -

    serviceRefs define service references for the current component. Based on the referenced services, they can be categorized into two types:
    Service provided by external sources: These services are provided by external sources and are not managed by KubeBlocks. They can be Kubernetes-based or non-Kubernetes services. For external services, you need to provide an additional ServiceDescriptor object to establish the service binding.
    Service provided by other KubeBlocks clusters: These services are provided by other KubeBlocks clusters. You can bind to these services by specifying the name of the hosting cluster.
    Each type of service reference requires specific configurations and bindings to establish the connection and interaction with the respective services.
    It should be noted that the ServiceRef has cluster-level semantic consistency, meaning that within the same Cluster, service references with the same ServiceRef.Name are considered to be the same service. It is only allowed to bind to the same Cluster or ServiceDescriptor.


    +

    serviceRefs define service references for the current component. Based on the referenced services, they can be categorized into two types: +Service provided by external sources: These services are provided by external sources and are not managed by KubeBlocks. They can be Kubernetes-based or non-Kubernetes services. For external services, you need to provide an additional ServiceDescriptor object to establish the service binding. +Service provided by other KubeBlocks clusters: These services are provided by other KubeBlocks clusters. You can bind to these services by specifying the name of the hosting cluster. +Each type of service reference requires specific configurations and bindings to establish the connection and interaction with the respective services. +It should be noted that the ServiceRef has cluster-level semantic consistency, meaning that within the same Cluster, service references with the same ServiceRef.Name are considered to be the same service. It is only allowed to bind to the same Cluster or ServiceDescriptor.

    (Optional) -

    monitor is a switch to enable monitoring and is set as false by default.
    KubeBlocks provides an extension mechanism to support component level monitoring,
    which will scrape metrics auto or manually from servers in component and export
    metrics to Time Series Database.


    +

    monitor is a switch to enable monitoring and is set as false by default. +KubeBlocks provides an extension mechanism to support component level monitoring, +which will scrape metrics auto or manually from servers in component and export +metrics to Time Series Database.

    (Optional) -

    enabledLogs indicates which log file takes effect in the database cluster.
    element is the log type which is defined in cluster definition logConfig.name,
    and will set relative variables about this log type in database kernel.


    +

    enabledLogs indicates which log file takes effect in the database cluster. +element is the log type which is defined in cluster definition logConfig.name, +and will set relative variables about this log type in database kernel.

    -

    Component replicas.


    +

    Component replicas.

    (Optional) -

    affinity describes affinities specified by users.


    +

    affinity describes affinities specified by users.

    (Optional) -

    Component tolerations will override ClusterSpec.Tolerations if specified.


    +

    Component tolerations will override ClusterSpec.Tolerations if specified.

    (Optional) -

    Resources requests and limits of workload.


    +

    Resources requests and limits of workload.

    (Optional) -

    volumeClaimTemplates information for statefulset.spec.volumeClaimTemplates.


    +

    volumeClaimTemplates information for statefulset.spec.volumeClaimTemplates.

    (Optional) -

    Services expose endpoints that can be accessed by clients.


    +

    Services expose endpoints that can be accessed by clients.

    (Optional) -

    switchPolicy defines the strategy for switchover and failover when workloadType is Replication.


    +

    switchPolicy defines the strategy for switchover and failover when workloadType is Replication.

    (Optional) -

    Enables or disables TLS certs.


    +

    Enables or disables TLS certs.

    (Optional) -

    issuer defines provider context for TLS certs.
    required when TLS enabled


    +

    issuer defines provider context for TLS certs. +required when TLS enabled

    (Optional) -

    serviceAccountName is the name of the ServiceAccount that running component depends on.


    +

    serviceAccountName is the name of the ServiceAccount that running component depends on.

    (Optional) -

    updateStrategy defines the update strategy for the component.
    Not supported.


    +

    updateStrategy defines the update strategy for the component. +Not supported.

    (Optional) -

    userResourceRefs defines the user-defined volumes.


    +

    userResourceRefs defines the user-defined volumes.

    rsmTransformPolicy
    -github.com/apecloud/kubeblocks/apis/workloads/v1alpha1.RsmTransformPolicy + +RsmTransformPolicy +
    (Optional) -

    RsmTransformPolicy defines the policy generate sts using rsm.
    ToSts: rsm transforms to statefulSet
    ToPod: rsm transforms to pods


    +

    RsmTransformPolicy defines the policy generate sts using rsm. +ToSts: rsm transforms to statefulSet +ToPod: rsm transforms to pods

    nodes
    + []k8s.io/apimachinery/pkg/types.NodeName +
    (Optional) -

    Nodes defines the list of nodes that pods can schedule
    If the RsmTransformPolicy is specified as ToPod,the list of nodes will be used. If the list of nodes is empty,
    no specific node will be assigned. However, if the list of node is filled, all pods will be evenly scheduled
    across the nodes in the list.


    +

    Nodes defines the list of nodes that pods can schedule +If the RsmTransformPolicy is specified as ToPod,the list of nodes will be used. If the list of nodes is empty, +no specific node will be assigned. However, if the list of node is filled, all pods will be evenly scheduled +across the nodes in the list.

    (Optional) -

    Instances defines the list of instance to be deleted priorly
    If the RsmTransformPolicy is specified as ToPod,the list of instances will be used.


    +

    Instances defines the list of instance to be deleted priorly +If the RsmTransformPolicy is specified as ToPod,the list of instances will be used.

    @@ -4159,7 +4416,15 @@ ClusterComponentPhase @@ -4173,7 +4438,8 @@ ComponentMessageMap @@ -4185,7 +4451,7 @@ bool @@ -4199,19 +4465,22 @@ Kubernetes meta/v1.Time @@ -4222,7 +4491,7 @@ Kubernetes meta/v1.Time (Appears on:ClusterVersionSpec)

    -

    ClusterComponentVersion is an application version component spec.


    +

    ClusterComponentVersion is an application version component spec.

    -

    phase describes the phase of the component and the detail information of the phases are as following:
    Creating: Creating is a special Updating with previous phase empty(means “”) or Creating.
    Running: component replicas > 0 and all pod specs are latest with a Running state.
    Updating: component replicas > 0 and has no failed pods. the component is being updated.
    Abnormal: component replicas > 0 but having some failed pods. the component basically works but in a fragile state.
    Failed: component replicas > 0 but having some failed pods. the component doesn’t work anymore.
    Stopping: component replicas = 0 and has terminating pods.
    Stopped: component replicas = 0 and all pods have been deleted.
    Deleting: the component is being deleted.


    +

    phase describes the phase of the component and the detail information of the phases are as following: +Creating: Creating is a special Updating with previous phase empty(means “”) or Creating. +Running: component replicas > 0 and all pod specs are latest with a Running state. +Updating: component replicas > 0 and has no failed pods. the component is being updated. +Abnormal: component replicas > 0 but having some failed pods. the component basically works but in a fragile state. +Failed: component replicas > 0 but having some failed pods. the component doesn’t work anymore. +Stopping: component replicas = 0 and has terminating pods. +Stopped: component replicas = 0 and all pods have been deleted. +Deleting: the component is being deleted.

    (Optional) -

    message records the component details message in current phase.
    Keys are podName or deployName or statefulSetName. The format is ObjectKind/Name.


    +

    message records the component details message in current phase. +Keys are podName or deployName or statefulSetName. The format is ObjectKind/Name.

    (Optional) -

    podsReady checks if all pods of the component are ready.


    +

    podsReady checks if all pods of the component are ready.

    (Optional) -

    podsReadyTime what time point of all component pods are ready,
    this time is the ready time of the last component pod.


    +

    podsReadyTime what time point of all component pods are ready, +this time is the ready time of the last component pod.

    membersStatus
    -[]github.com/apecloud/kubeblocks/apis/workloads/v1alpha1.MemberStatus + +[]MemberStatus +
    (Optional) -

    members’ status.


    +

    members’ status.

    @@ -4240,7 +4509,7 @@ string @@ -4254,7 +4523,9 @@ string @@ -4268,7 +4539,9 @@ SystemAccountShortSpec @@ -4281,7 +4554,8 @@ VersionsContext @@ -4295,7 +4569,8 @@ SwitchoverShortSpec @@ -4323,7 +4598,7 @@ string @@ -4337,7 +4612,7 @@ PersistentVolumeClaimSpec @@ -4434,7 +4715,7 @@ int32 @@ -4445,7 +4726,7 @@ int32 @@ -4459,7 +4740,7 @@ ClusterDefinitionProbeCMDs @@ -4488,7 +4769,7 @@ ClusterDefinitionProbeCMDs @@ -4500,7 +4781,7 @@ ClusterDefinitionProbeCMDs @@ -4531,7 +4812,7 @@ ClusterDefinitionProbe @@ -4545,7 +4826,7 @@ ClusterDefinitionProbe @@ -4559,7 +4840,7 @@ ClusterDefinitionProbe @@ -4571,7 +4852,12 @@ int32 @@ -4582,7 +4868,7 @@ int32 (Appears on:ClusterDefinition)

    -

    ClusterDefinitionSpec defines the desired state of ClusterDefinition


    +

    ClusterDefinitionSpec defines the desired state of ClusterDefinition

    -

    componentDefRef reference one of the cluster component definition names in ClusterDefinition API (spec.componentDefs.name).


    +

    componentDefRef reference one of the cluster component definition names in ClusterDefinition API (spec.componentDefs.name).

    (Optional) -

    configSpecs defines a configuration extension mechanism to handle configuration differences between versions,
    the configTemplateRefs field, together with configTemplateRefs in the ClusterDefinition,
    determines the final configuration file.


    +

    configSpecs defines a configuration extension mechanism to handle configuration differences between versions, +the configTemplateRefs field, together with configTemplateRefs in the ClusterDefinition, +determines the final configuration file.

    (Optional) -

    systemAccountSpec define image for the component to connect database or engines.
    It overrides image and env attributes defined in ClusterDefinition.spec.componentDefs.systemAccountSpec.cmdExecutorConfig.
    To clean default envs settings, set SystemAccountSpec.CmdExecutorConfig.Env to empty list.


    +

    systemAccountSpec define image for the component to connect database or engines. +It overrides image and env attributes defined in ClusterDefinition.spec.componentDefs.systemAccountSpec.cmdExecutorConfig. +To clean default envs settings, set SystemAccountSpec.CmdExecutorConfig.Env to empty list.

    -

    versionContext defines containers images’ context for component versions,
    this value replaces ClusterDefinition.spec.componentDefs.podSpec.[initContainers | containers]


    +

    versionContext defines containers images’ context for component versions, +this value replaces ClusterDefinition.spec.componentDefs.podSpec.[initContainers | containers]

    (Optional) -

    switchoverSpec defines images for the component to do switchover.
    It overrides image and env attributes defined in ClusterDefinition.spec.componentDefs.SwitchoverSpec.CommandExecutorEnvItem.


    +

    switchoverSpec defines images for the component to do switchover. +It overrides image and env attributes defined in ClusterDefinition.spec.componentDefs.SwitchoverSpec.CommandExecutorEnvItem.

    -

    Reference ClusterDefinition.spec.componentDefs.containers.volumeMounts.name.


    +

    Reference ClusterDefinition.spec.componentDefs.containers.volumeMounts.name.

    (Optional) -

    spec defines the desired characteristics of a volume requested by a pod author.


    +

    spec defines the desired characteristics of a volume requested by a pod author.



    @@ -4352,7 +4627,8 @@ PersistentVolumeClaimSpec @@ -4366,7 +4642,11 @@ Kubernetes core/v1.ResourceRequirements @@ -4378,7 +4658,8 @@ string @@ -4392,7 +4673,7 @@ Kubernetes core/v1.PersistentVolumeMode
    (Optional) -

    accessModes contains the desired access modes the volume should have.
    More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1.


    +

    accessModes contains the desired access modes the volume should have. +More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1.

    (Optional) -

    resources represents the minimum resources the volume should have.
    If RecoverVolumeExpansionFailure feature is enabled users are allowed to specify resource requirements
    that are lower than previous value but must still be higher than capacity recorded in the
    status field of the claim.
    More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources.


    +

    resources represents the minimum resources the volume should have. +If RecoverVolumeExpansionFailure feature is enabled users are allowed to specify resource requirements +that are lower than previous value but must still be higher than capacity recorded in the +status field of the claim. +More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources.

    (Optional) -

    storageClassName is the name of the StorageClass required by the claim.
    More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1.


    +

    storageClassName is the name of the StorageClass required by the claim. +More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1.

    (Optional) -

    volumeMode defines what type of volume is required by the claim.


    +

    volumeMode defines what type of volume is required by the claim.

    @@ -4423,7 +4704,7 @@ int32
    -

    How often (in seconds) to perform the probe.


    +

    How often (in seconds) to perform the probe.

    -

    Number of seconds after which the probe times out. Defaults to 1 second.


    +

    Number of seconds after which the probe times out. Defaults to 1 second.

    -

    Minimum consecutive failures for the probe to be considered failed after having succeeded.


    +

    Minimum consecutive failures for the probe to be considered failed after having succeeded.

    (Optional) -

    commands used to execute for probe.


    +

    commands used to execute for probe.

    (Optional) -

    Write check executed on probe sidecar, used to check workload’s allow write access.


    +

    Write check executed on probe sidecar, used to check workload’s allow write access.

    (Optional) -

    Read check executed on probe sidecar, used to check workload’s readonly access.


    +

    Read check executed on probe sidecar, used to check workload’s readonly access.

    (Optional) -

    Probe for DB running check.


    +

    Probe for DB running check.

    (Optional) -

    Probe for DB status check.


    +

    Probe for DB status check.

    (Optional) -

    Probe for DB role changed check.


    +

    Probe for DB role changed check.

    (Optional) -

    roleProbeTimeoutAfterPodsReady(in seconds), when all pods of the component are ready,
    it will detect whether the application is available in the pod.
    if pods exceed the InitializationTimeoutSeconds time without a role label,
    this component will enter the Failed/Abnormal phase.
    Note that this configuration will only take effect if the component supports RoleProbe
    and will not affect the life cycle of the pod. default values are 60 seconds.


    +

    roleProbeTimeoutAfterPodsReady(in seconds), when all pods of the component are ready, +it will detect whether the application is available in the pod. +if pods exceed the InitializationTimeoutSeconds time without a role label, +this component will enter the Failed/Abnormal phase. +Note that this configuration will only take effect if the component supports RoleProbe +and will not affect the life cycle of the pod. default values are 60 seconds.

    @@ -4601,7 +4887,7 @@ string @@ -4614,7 +4900,7 @@ string @@ -4626,7 +4912,25 @@ map[string]string @@ -4637,7 +4941,7 @@ map[string]string (Appears on:ClusterDefinition)

    -

    ClusterDefinitionStatus defines the observed state of ClusterDefinition


    +

    ClusterDefinitionStatus defines the observed state of ClusterDefinition

    (Optional) -

    Cluster definition type defines well known application cluster type, e.g. mysql/redis/mongodb


    +

    Cluster definition type defines well known application cluster type, e.g. mysql/redis/mongodb

    -

    componentDefs provides cluster components definitions.


    +

    componentDefs provides cluster components definitions.

    (Optional) -

    Connection credential template used for creating a connection credential
    secret for cluster.apps.kubeblocks.io object.



    Built-in objects are:
    - $(RANDOM_PASSWD) - random 8 characters.
    - $(STRONG_RANDOM_PASSWD) - random 16 characters, with mixed cases, digits and symbols.
    - $(UUID) - generate a random UUID v4 string.
    - $(UUID_B64) - generate a random UUID v4 BASE64 encoded string.
    - $(UUID_STR_B64) - generate a random UUID v4 string then BASE64 encoded.
    - $(UUID_HEX) - generate a random UUID v4 HEX representation.
    - $(HEADLESS_SVC_FQDN) - headless service FQDN placeholder, value pattern - $(CLUSTER_NAME)-$(1ST_COMP_NAME)-headless.$(NAMESPACE).svc,
    where 1ST_COMP_NAME is the 1st component that provide ClusterDefinition.spec.componentDefs[].service attribute;
    - $(SVC_FQDN) - service FQDN placeholder, value pattern - $(CLUSTER_NAME)-$(1ST_COMP_NAME).$(NAMESPACE).svc,
    where 1ST_COMP_NAME is the 1st component that provide ClusterDefinition.spec.componentDefs[].service attribute;
    - $(SVC_PORT_{PORT-NAME}) - a ServicePort’s port value with specified port name, i.e, a servicePort JSON struct:
    {"name": "mysql", "targetPort": "mysqlContainerPort", "port": 3306}, and “$(SVC_PORT_mysql)” in the
    connection credential value is 3306.


    +

    Connection credential template used for creating a connection credential +secret for cluster.apps.kubeblocks.io object.

    +

    Built-in objects are:

    +
      +
    • $(RANDOM_PASSWD) random 8 characters. +dfjksgks
    • +
    • $(STRONG_RANDOM_PASSWD) random 16 characters, with mixed cases, digits and symbols.
    • +
    • $(UUID) generate a random UUID v4 string.
    • +
    • $(UUID_B64) generate a random UUID v4 BASE64 encoded string.
    • +
    • $(UUID_STR_B64) generate a random UUID v4 string then BASE64 encoded.
    • +
    • $(UUID_HEX) generate a random UUID v4 HEX representation.
    • +
    • $(HEADLESS_SVC_FQDN) headless service FQDN placeholder, value pattern is $(CLUSTER_NAME)-$(1ST_COMP_NAME)-headless.$(NAMESPACE).svc, +where 1ST_COMP_NAME is the 1st component that provide ClusterDefinition.spec.componentDefs[].service attribute;
    • +
    • $(SVC_FQDN) service FQDN placeholder, value pattern is $(CLUSTER_NAME)-$(1ST_COMP_NAME).$(NAMESPACE).svc, +where 1ST_COMP_NAME is the 1st component that provide ClusterDefinition.spec.componentDefs[].service attribute;
    • +
    • $(SVC_PORT_{PORT-NAME}) is ServicePort’s port value with specified port name, i.e, a servicePort JSON struct: +{"name": "mysql", "targetPort": "mysqlContainerPort", "port": 3306}, and $(SVC_PORT_mysql) in the +connection credential value is 3306.
    • +
    @@ -4657,7 +4961,8 @@ Phase @@ -4669,7 +4974,7 @@ string @@ -4681,7 +4986,9 @@ int64 @@ -4712,7 +5019,7 @@ Kubernetes api utils intstr.IntOrString @@ -4741,7 +5048,7 @@ bool @@ -4753,7 +5060,7 @@ bool @@ -4764,7 +5071,7 @@ bool (Appears on:CredentialVarSelector, ServiceRefVarSelector, ServiceVarSelector)

    -

    ClusterObjectReference contains information to let you locate the referenced object inside the same cluster.


    +

    ClusterObjectReference contains information to let you locate the referenced object inside the same cluster.

    -

    ClusterDefinition phase, valid values are empty, Available, ‘Unavailable`.
    Available is ClusterDefinition become available, and can be referenced for co-related objects.


    +

    ClusterDefinition phase, valid values are empty, Available, ‘Unavailable`. +Available is ClusterDefinition become available, and can be referenced for co-related objects.

    (Optional) -

    Extra message in current phase


    +

    Extra message in current phase

    (Optional) -

    observedGeneration is the most recent generation observed for this
    ClusterDefinition. It corresponds to the ClusterDefinition’s generation, which is
    updated on mutation by the API Server.


    +

    observedGeneration is the most recent generation observed for this +ClusterDefinition. It corresponds to the ClusterDefinition’s generation, which is +updated on mutation by the API Server.

    (Optional) -

    monitoringInterval specifies interval of monitoring, no monitor if set to 0


    +

    monitoringInterval specifies interval of monitoring, no monitor if set to 0

    (Optional) -

    hostNetworkAccessible specifies whether host network is accessible. It defaults to false


    +

    hostNetworkAccessible specifies whether host network is accessible. It defaults to false

    (Optional) -

    publiclyAccessible specifies whether it is publicly accessible. It defaults to false


    +

    publiclyAccessible specifies whether it is publicly accessible. It defaults to false

    @@ -4783,7 +5090,7 @@ string @@ -4795,7 +5102,7 @@ string @@ -4807,7 +5114,7 @@ bool @@ -4818,7 +5125,7 @@ bool (Appears on:ClusterStatus, OpsRequestBehaviour)

    -

    ClusterPhase defines the Cluster CR .status.phase


    +

    ClusterPhase defines the Cluster CR .status.phase

    (Optional) -

    CompDef specifies the definition used by the component that the referent object resident in.


    +

    CompDef specifies the definition used by the component that the referent object resident in.

    (Optional) -

    Name of the referent object.


    +

    Name of the referent object.

    (Optional) -

    Specify whether the object must be defined.


    +

    Specify whether the object must be defined.

    @@ -4868,7 +5175,7 @@ string @@ -4881,7 +5188,7 @@ string @@ -4912,7 +5219,7 @@ Kubernetes resource.Quantity @@ -4926,7 +5233,7 @@ Kubernetes resource.Quantity @@ -4937,7 +5244,7 @@ Kubernetes resource.Quantity (Appears on:ClusterSpec)

    -

    ClusterService defines the service of a cluster.


    +

    ClusterService defines the service of a cluster.

    -

    clusterDefRef is the name of the cluster definition.


    +

    clusterDefRef is the name of the cluster definition.

    -

    selector is used to bind the resource constraint to components.


    +

    selector is used to bind the resource constraint to components.

    (Optional) -

    cpu resource needed, more info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/


    +

    cpu resource needed, more info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/

    (Optional) -

    memory resource needed, more info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/


    +

    memory resource needed, more info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/

    @@ -4971,7 +5278,9 @@ string @@ -4983,7 +5292,8 @@ string @@ -4994,7 +5304,7 @@ string (Appears on:Cluster)

    -

    ClusterSpec defines the desired state of Cluster.


    +

    ClusterSpec defines the desired state of Cluster.

    (Optional) -

    ShardingSelector extends the ServiceSpec.Selector by allowing you to specify a sharding name
    defined in Cluster.Spec.ShardingSpecs[x].Name as selectors for the service.
    ShardingSelector and ComponentSelector cannot be set at the same time.


    +

    ShardingSelector extends the ServiceSpec.Selector by allowing you to specify a sharding name +defined in Cluster.Spec.ShardingSpecs[x].Name as selectors for the service. +ShardingSelector and ComponentSelector cannot be set at the same time.

    (Optional) -

    ComponentSelector extends the ServiceSpec.Selector by allowing you to specify a component as selectors for the service.
    ComponentSelector and ShardingSelector cannot be set at the same time.


    +

    ComponentSelector extends the ServiceSpec.Selector by allowing you to specify a component as selectors for the service. +ComponentSelector and ShardingSelector cannot be set at the same time.

    @@ -5013,7 +5323,8 @@ string @@ -5025,7 +5336,7 @@ string @@ -5038,7 +5349,11 @@ TerminationPolicyType @@ -5052,7 +5367,8 @@ TerminationPolicyType @@ -5066,7 +5382,8 @@ TerminationPolicyType @@ -5080,7 +5397,7 @@ TerminationPolicyType @@ -5094,7 +5411,7 @@ Affinity @@ -5108,7 +5425,7 @@ Affinity @@ -5122,7 +5439,9 @@ TenancyType @@ -5136,7 +5455,7 @@ AvailabilityPolicyType @@ -5148,7 +5467,7 @@ int32 @@ -5162,7 +5481,7 @@ ClusterResources @@ -5176,7 +5495,7 @@ ClusterStorage @@ -5190,7 +5509,7 @@ ClusterMonitor @@ -5204,7 +5523,7 @@ ClusterNetwork @@ -5218,7 +5537,7 @@ ClusterBackup @@ -5229,7 +5548,7 @@ ClusterBackup (Appears on:Cluster)

    -

    ClusterStatus defines the observed state of Cluster.


    +

    ClusterStatus defines the observed state of Cluster.

    (Optional) -

    Cluster referencing ClusterDefinition name. This is an immutable attribute.
    If ClusterDefRef is not specified, ComponentDef must be specified for each Component in ComponentSpecs.


    +

    Cluster referencing ClusterDefinition name. This is an immutable attribute. +If ClusterDefRef is not specified, ComponentDef must be specified for each Component in ComponentSpecs.

    (Optional) -

    Cluster referencing ClusterVersion name.


    +

    Cluster referencing ClusterVersion name.

    -

    Cluster termination policy. Valid values are DoNotTerminate, Halt, Delete, WipeOut.
    DoNotTerminate will block delete operation.
    Halt will delete workload resources such as statefulset, deployment workloads but keep PVCs.
    Delete is based on Halt and deletes PVCs.
    WipeOut is based on Delete and wipe out all volume snapshots and snapshot data from backup storage location.


    +

    Cluster termination policy. Valid values are DoNotTerminate, Halt, Delete, WipeOut. +DoNotTerminate will block delete operation. +Halt will delete workload resources such as statefulset, deployment workloads but keep PVCs. +Delete is based on Halt and deletes PVCs. +WipeOut is based on Delete and wipe out all volume snapshots and snapshot data from backup storage location.

    (Optional) -

    List of ShardingSpec which is used to define components with a sharding topology structure that make up a cluster.
    ShardingSpecs and ComponentSpecs cannot both be empty at the same time.


    +

    List of ShardingSpec which is used to define components with a sharding topology structure that make up a cluster. +ShardingSpecs and ComponentSpecs cannot both be empty at the same time.

    (Optional) -

    List of componentSpec which is used to define the components that make up a cluster.
    ComponentSpecs and ShardingSpecs cannot both be empty at the same time.


    +

    List of componentSpec which is used to define the components that make up a cluster. +ComponentSpecs and ShardingSpecs cannot both be empty at the same time.

    (Optional) -

    services defines the services to access a cluster.


    +

    services defines the services to access a cluster.

    (Optional) -

    affinity is a group of affinity scheduling rules.


    +

    affinity is a group of affinity scheduling rules.

    (Optional) -

    tolerations are attached to tolerate any taint that matches the triple key,value,effect using the matching operator operator.


    +

    tolerations are attached to tolerate any taint that matches the triple key,value,effect using the matching operator operator.

    (Optional) -

    tenancy describes how pods are distributed across node.
    SharedNode means multiple pods may share the same node.
    DedicatedNode means each pod runs on their own dedicated node.


    +

    tenancy describes how pods are distributed across node. +SharedNode means multiple pods may share the same node. +DedicatedNode means each pod runs on their own dedicated node.

    (Optional) -

    availabilityPolicy describes the availability policy, including zone, node, and none.


    +

    availabilityPolicy describes the availability policy, including zone, node, and none.

    (Optional) -

    replicas specifies the replicas of the first componentSpec, if the replicas of the first componentSpec is specified, this value will be ignored.


    +

    replicas specifies the replicas of the first componentSpec, if the replicas of the first componentSpec is specified, this value will be ignored.

    (Optional) -

    resources specifies the resources of the first componentSpec, if the resources of the first componentSpec is specified, this value will be ignored.


    +

    resources specifies the resources of the first componentSpec, if the resources of the first componentSpec is specified, this value will be ignored.

    (Optional) -

    storage specifies the storage of the first componentSpec, if the storage of the first componentSpec is specified, this value will be ignored.


    +

    storage specifies the storage of the first componentSpec, if the storage of the first componentSpec is specified, this value will be ignored.

    (Optional) -

    monitor specifies the configuration of monitor


    +

    monitor specifies the configuration of monitor

    (Optional) -

    network specifies the configuration of network


    +

    network specifies the configuration of network

    (Optional) -

    cluster backup configuration.


    +

    cluster backup configuration.

    @@ -5248,7 +5567,9 @@ int64 @@ -5262,7 +5583,16 @@ ClusterPhase @@ -5274,7 +5604,7 @@ string @@ -5282,13 +5612,13 @@ string components
    -map[string]..ClusterComponentStatus +map[string]github.com/apecloud/kubeblocks/apis/apps/v1alpha1.ClusterComponentStatus @@ -5300,7 +5630,7 @@ int64 @@ -5314,7 +5644,7 @@ int64 @@ -5345,7 +5675,7 @@ Kubernetes resource.Quantity @@ -5376,7 +5706,10 @@ SwitchPolicyType @@ -5387,7 +5720,7 @@ SwitchPolicyType (Appears on:ClusterVersion)

    -

    ClusterVersionSpec defines the desired state of ClusterVersion


    +

    ClusterVersionSpec defines the desired state of ClusterVersion

    (Optional) -

    observedGeneration is the most recent generation observed for this
    Cluster. It corresponds to the Cluster’s generation, which is
    updated on mutation by the API Server.


    +

    observedGeneration is the most recent generation observed for this +Cluster. It corresponds to the Cluster’s generation, which is +updated on mutation by the API Server.

    (Optional) -

    phase describes the phase of the Cluster, the detail information of the phases are as following:
    Creating: all components are in Creating phase.
    Running: all components are in Running phase, means the cluster is working well.
    Updating: all components are in Creating, Running or Updating phase,
    and at least one component is in Creating or Updating phase, means the cluster is doing an update.
    Stopping: at least one component is in Stopping phase, means the cluster is in a stop progress.
    Stopped: all components are in ‘Stoppedphase, means the cluster has stopped and didn't provide any function anymore.
    Failed: all components are in
    Failedphase, means the cluster is unavailable.
    Abnormal: some components are in
    FailedorAbnormal` phase, means the cluster in a fragile state. troubleshoot need to be done.
    Deleting: the cluster is being deleted.


    +

    phase describes the phase of the Cluster, the detail information of the phases are as following: +Creating: all components are in Creating phase. +Running: all components are in Running phase, means the cluster is working well. +Updating: all components are in Creating, Running or Updating phase, +and at least one component is in Creating or Updating phase, means the cluster is doing an update. +Stopping: at least one component is in Stopping phase, means the cluster is in a stop progress. +Stopped: all components are in ‘Stoppedphase, means the cluster has stopped and didn't provide any function anymore. +Failed: all components are inFailedphase, means the cluster is unavailable. +Abnormal: some components are inFailedorAbnormal` phase, means the cluster in a fragile state. troubleshoot need to be done. +Deleting: the cluster is being deleted.

    (Optional) -

    message describes cluster details message in current phase.


    +

    message describes cluster details message in current phase.

    (Optional) -

    components record the current status information of all components of the cluster.


    +

    components record the current status information of all components of the cluster.

    (Optional) -

    clusterDefGeneration represents the generation number of ClusterDefinition referenced.


    +

    clusterDefGeneration represents the generation number of ClusterDefinition referenced.

    (Optional) -

    Describe current state of cluster API Resource, like warning.


    +

    Describe current state of cluster API Resource, like warning.

    (Optional) -

    storage size needed, more info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/


    +

    storage size needed, more info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/

    (Optional) -

    clusterSwitchPolicy defines type of the switchPolicy when workloadType is Replication.
    MaximumAvailability: [WIP] when the primary is active, do switch if the synchronization delay = 0 in the user-defined lagProbe data delay detection logic, otherwise do not switch. The primary is down, switch immediately. It will be available in future versions.
    MaximumDataProtection: [WIP] when the primary is active, do switch if synchronization delay = 0 in the user-defined lagProbe data lag detection logic, otherwise do not switch. If the primary is down, if it can be judged that the primary and secondary data are consistent, then do the switch, otherwise do not switch. It will be available in future versions.
    Noop: KubeBlocks will not perform high-availability switching on components. Users need to implement HA by themselves or integrate open source HA solution.


    +

    clusterSwitchPolicy defines type of the switchPolicy when workloadType is Replication. +MaximumAvailability: [WIP] when the primary is active, do switch if the synchronization delay = 0 in the user-defined lagProbe data delay detection logic, otherwise do not switch. The primary is down, switch immediately. It will be available in future versions. +MaximumDataProtection: [WIP] when the primary is active, do switch if synchronization delay = 0 in the user-defined lagProbe data lag detection logic, otherwise do not switch. If the primary is down, if it can be judged that the primary and secondary data are consistent, then do the switch, otherwise do not switch. It will be available in future versions. +Noop: KubeBlocks will not perform high-availability switching on components. Users need to implement HA by themselves or integrate open source HA solution.

    @@ -5405,7 +5738,7 @@ string @@ -5418,7 +5751,7 @@ string @@ -5429,7 +5762,7 @@ string (Appears on:ClusterVersion)

    -

    ClusterVersionStatus defines the observed state of ClusterVersion


    +

    ClusterVersionStatus defines the observed state of ClusterVersion

    -

    ref ClusterDefinition.


    +

    ref ClusterDefinition.

    -

    List of components’ containers versioning context, i.e., container image ID, container commands, args., and environments.


    +

    List of components’ containers versioning context, i.e., container image ID, container commands, args., and environments.

    @@ -5450,7 +5783,7 @@ Phase @@ -5462,7 +5795,7 @@ string @@ -5474,7 +5807,7 @@ int64 @@ -5486,7 +5819,7 @@ int64 @@ -5497,7 +5830,7 @@ int64 (Appears on:PostStartAction, SwitchoverAction, SystemAccountSpec)

    -

    CmdExecutorConfig specifies how to perform creation and deletion statements.


    +

    CmdExecutorConfig specifies how to perform creation and deletion statements.

    (Optional) -

    phase - in list of [Available,Unavailable]


    +

    phase - in list of [Available,Unavailable]

    (Optional) -

    A human readable message indicating details about why the ClusterVersion is in this phase.


    +

    A human readable message indicating details about why the ClusterVersion is in this phase.

    (Optional) -

    generation number


    +

    generation number

    (Optional) -

    clusterDefGeneration represents the generation number of ClusterDefinition referenced.


    +

    clusterDefGeneration represents the generation number of ClusterDefinition referenced.

    @@ -5562,7 +5895,7 @@ string @@ -5576,7 +5909,7 @@ string @@ -5604,7 +5937,7 @@ string @@ -5616,7 +5949,7 @@ string @@ -5645,7 +5978,7 @@ string @@ -5657,7 +5990,7 @@ string @@ -5671,7 +6004,7 @@ Kubernetes resource.Quantity @@ -5685,7 +6018,7 @@ Kubernetes resource.Quantity @@ -5696,7 +6029,7 @@ Kubernetes resource.Quantity (Appears on:ComponentClassDefinition)

    -

    ComponentClassDefinitionSpec defines the desired state of ComponentClassDefinition


    +

    ComponentClassDefinitionSpec defines the desired state of ComponentClassDefinition

    -

    image for Connector when executing the command.


    +

    image for Connector when executing the command.

    (Optional) -

    envs is a list of environment variables.


    +

    envs is a list of environment variables.

    -

    command to perform statements.


    +

    command to perform statements.

    (Optional) -

    args is used to perform statements.


    +

    args is used to perform statements.

    (Optional) -

    name is the class name


    +

    name is the class name

    (Optional) -

    args are variable’s value


    +

    args are variable’s value

    (Optional) -

    the CPU of the class


    +

    the CPU of the class

    (Optional) -

    the memory of the class


    +

    the memory of the class

    @@ -5717,7 +6050,7 @@ Kubernetes resource.Quantity @@ -5728,7 +6061,7 @@ Kubernetes resource.Quantity (Appears on:ComponentClassDefinition)

    -

    ComponentClassDefinitionStatus defines the observed state of ComponentClassDefinition


    +

    ComponentClassDefinitionStatus defines the observed state of ComponentClassDefinition

    (Optional) -

    group defines a list of class series that conform to the same constraint.


    +

    group defines a list of class series that conform to the same constraint.

    @@ -5747,7 +6080,9 @@ int64 @@ -5760,7 +6095,7 @@ int64 @@ -5789,7 +6124,13 @@ string @@ -5801,7 +6142,8 @@ string @@ -5815,7 +6157,7 @@ string @@ -5844,7 +6186,10 @@ string @@ -5858,7 +6203,9 @@ string @@ -5902,7 +6249,8 @@ ComponentTemplateSpec @@ -5916,7 +6264,7 @@ LegacyRenderedTemplateSpec @@ -5928,7 +6276,7 @@ string @@ -5940,7 +6288,7 @@ string @@ -5951,7 +6299,7 @@ string (Appears on:ClusterComponentDefinition)

    -

    ComponentDefRef is used to select the component and its fields to be referenced.


    +

    ComponentDefRef is used to select the component and its fields to be referenced.

    (Optional) -

    observedGeneration is the most recent generation observed for this
    ComponentClassDefinition. It corresponds to the ComponentClassDefinition’s generation, which is
    updated on mutation by the API Server.


    +

    observedGeneration is the most recent generation observed for this +ComponentClassDefinition. It corresponds to the ComponentClassDefinition’s generation, which is +updated on mutation by the API Server.

    -

    classes is the list of classes that have been observed for this ComponentClassDefinition


    +

    classes is the list of classes that have been observed for this ComponentClassDefinition

    (Optional) -

    template is a class definition template that uses the Go template syntax and allows for variable declaration.
    When defining a class in Series, specifying the variable’s value is sufficient, as the complete class
    definition will be generated through rendering the template.



    For example:
    template: |
    cpu: “{{ or .cpu 1 }}”
    memory: “{{ or .memory 4 }}Gi”


    +

    template is a class definition template that uses the Go template syntax and allows for variable declaration. +When defining a class in Series, specifying the variable’s value is sufficient, as the complete class +definition will be generated through rendering the template.

    +

    For example: +template: | +cpu: “{{ or .cpu 1 }}” +memory: “{{ or .memory 4 }}Gi”

    (Optional) -

    vars defines the variables declared in the template and will be used to generating the complete class definition by
    render the template.


    +

    vars defines the variables declared in the template and will be used to generating the complete class definition by +render the template.

    (Optional) -

    series is a series of class definitions.


    +

    series is a series of class definitions.

    (Optional) -

    namingTemplate is a template that uses the Go template syntax and allows for referencing variables defined
    in ComponentClassGroup.Template. This enables dynamic generation of class names.
    For example:
    name: “general-{{ .cpu }}c{{ .memory }}g”


    +

    namingTemplate is a template that uses the Go template syntax and allows for referencing variables defined +in ComponentClassGroup.Template. This enables dynamic generation of class names. +For example: +name: “general-{{ .cpu }}c{{ .memory }}g”

    (Optional) -

    classes are definitions of classes that come in two forms. In the first form, only ComponentClass.Args
    need to be defined, and the complete class definition is generated by rendering the ComponentClassGroup.Template
    and Name. In the second form, the Name, CPU and Memory must be defined.


    +

    classes are definitions of classes that come in two forms. In the first form, only ComponentClass.Args +need to be defined, and the complete class definition is generated by rendering the ComponentClassGroup.Template +and Name. In the second form, the Name, CPU and Memory must be defined.

    (Optional) -

    Specify a list of keys.
    If empty, ConfigConstraint takes effect for all keys in configmap.


    +

    Specify a list of keys. +If empty, ConfigConstraint takes effect for all keys in configmap.

    (Optional) -

    lazyRenderedConfigSpec is optional: specify the secondary rendered config spec.


    +

    lazyRenderedConfigSpec is optional: specify the secondary rendered config spec.

    (Optional) -

    Specify the name of the referenced the configuration constraints object.


    +

    Specify the name of the referenced the configuration constraints object.

    (Optional) -

    asEnvFrom is optional: the list of containers will be injected into EnvFrom.


    +

    asEnvFrom is optional: the list of containers will be injected into EnvFrom.

    @@ -5969,7 +6317,7 @@ string @@ -5983,7 +6331,8 @@ FailurePolicyType @@ -5997,7 +6346,7 @@ FailurePolicyType @@ -6025,7 +6374,7 @@ string @@ -6037,7 +6386,8 @@ string @@ -6049,7 +6399,9 @@ string @@ -6063,7 +6415,8 @@ VarsRef @@ -6074,7 +6427,7 @@ VarsRef (Appears on:ComponentDefinition)

    -

    ComponentDefinitionSpec provides a workload component specification with attributes that strongly work with stateful workloads and day-2 operation behaviors.


    +

    ComponentDefinitionSpec provides a workload component specification with attributes that strongly work with stateful workloads and day-2 operation behaviors.

    -

    componentDefName is the name of the componentDef to select.


    +

    componentDefName is the name of the componentDef to select.

    (Optional) -

    failurePolicy is the failure policy of the component.
    If failed to find the component, the failure policy will be used.


    +

    failurePolicy is the failure policy of the component. +If failed to find the component, the failure policy will be used.

    (Optional) -

    componentRefEnv specifies a list of values to be injected as env variables to each component.


    +

    componentRefEnv specifies a list of values to be injected as env variables to each component.

    -

    refer to componentDefinition name.


    +

    refer to componentDefinition name.

    (Optional) -

    the account name of the component.
    will inject the account username and password to KB_ACCOUNT_USERNAME and KB_ACCOUNT_PASSWORD in env of the job.


    +

    the account name of the component. +will inject the account username and password to KB_ACCOUNT_USERNAME and KB_ACCOUNT_PASSWORD in env of the job.

    (Optional) -

    reference the services[*].name.
    will map the service name and ports to KB_COMP_SVC_NAME and KB_COMP_SVC_PORT_$(portName) in env of the job.
    portName will replace the characters ‘-’ to ‘_’ and convert to uppercase.


    +

    reference the services[*].name. +will map the service name and ports to KB_COMP_SVC_NAME and KB_COMP_SVC_PORT_$(portName) in env of the job. +portName will replace the characters ‘-’ to ‘_’ and convert to uppercase.

    (Optional) -

    varsRef defines the envs that need to be referenced from the target component pod, and will inject to job’s containers.
    if it is set, will ignore the global “varsRef”.


    +

    varsRef defines the envs that need to be referenced from the target component pod, and will inject to job’s containers. +if it is set, will ignore the global “varsRef”.

    @@ -6093,7 +6446,7 @@ string @@ -6105,7 +6458,7 @@ string @@ -6117,7 +6470,8 @@ string @@ -6129,7 +6483,8 @@ string @@ -6142,7 +6497,21 @@ Kubernetes core/v1.PodSpec @@ -6156,7 +6525,10 @@ Kubernetes core/v1.PodSpec @@ -6170,7 +6542,9 @@ Kubernetes core/v1.PodSpec @@ -6184,7 +6558,9 @@ Kubernetes core/v1.PodSpec @@ -6198,7 +6574,9 @@ Kubernetes core/v1.PodSpec @@ -6212,7 +6590,8 @@ Kubernetes core/v1.PodSpec @@ -6226,7 +6605,8 @@ MonitorConfig @@ -6240,7 +6620,9 @@ MonitorConfig @@ -6254,7 +6636,9 @@ MonitorConfig @@ -6266,7 +6650,9 @@ map[string]string @@ -6280,7 +6666,8 @@ ReplicasLimit @@ -6294,7 +6681,8 @@ ReplicasLimit @@ -6308,7 +6696,8 @@ UpdateStrategy @@ -6322,7 +6711,8 @@ UpdateStrategy @@ -6336,7 +6726,8 @@ RoleArbitrator @@ -6350,7 +6741,9 @@ ComponentLifecycleActions @@ -6364,7 +6757,8 @@ ComponentLifecycleActions @@ -6376,7 +6770,9 @@ int32 @@ -6387,7 +6783,7 @@ int32 (Appears on:ComponentDefinition)

    -

    ComponentDefinitionStatus defines the observed state of ComponentDefinition.


    +

    ComponentDefinitionStatus defines the observed state of ComponentDefinition.

    (Optional) -

    Provider is the name of the component provider.


    +

    Provider is the name of the component provider.

    (Optional) -

    Description is a brief description of the component.


    +

    Description is a brief description of the component.

    (Optional) -

    ServiceKind defines what kind of well-known service that the component provides (e.g., MySQL, Redis, ETCD, case insensitive).
    Cannot be updated.


    +

    ServiceKind defines what kind of well-known service that the component provides (e.g., MySQL, Redis, ETCD, case insensitive). +Cannot be updated.

    (Optional) -

    ServiceVersion defines the version of the well-known service that the component provides.
    Cannot be updated.


    +

    ServiceVersion defines the version of the well-known service that the component provides. +Cannot be updated.

    -

    Runtime defines primarily runtime information for the component, including:
    - Init containers
    - Containers
    - Image
    - Commands
    - Args
    - Envs
    - Mounts
    - Ports
    - Security context
    - Probes
    - Lifecycle
    - Volumes
    CPU and memory resource limits, as well as scheduling settings (affinity, toleration, priority), should not be configured within this structure.
    Cannot be updated.


    +

    Runtime defines primarily runtime information for the component, including: +- Init containers +- Containers +- Image +- Commands +- Args +- Envs +- Mounts +- Ports +- Security context +- Probes +- Lifecycle +- Volumes +CPU and memory resource limits, as well as scheduling settings (affinity, toleration, priority), should not be configured within this structure. +Cannot be updated.

    (Optional) -

    Vars represents user-defined variables.
    These variables can be utilized as environment variables for Pods and Actions, or to render the templates of config and script.
    When used as environment variables, these variables are placed in front of the environment variables declared in the Pod.
    Cannot be updated.


    +

    Vars represents user-defined variables. +These variables can be utilized as environment variables for Pods and Actions, or to render the templates of config and script. +When used as environment variables, these variables are placed in front of the environment variables declared in the Pod. +Cannot be updated.

    (Optional) -

    Volumes defines the persistent volumes needed by the component.
    The users are responsible for providing these volumes when creating a component instance.
    Cannot be updated.


    +

    Volumes defines the persistent volumes needed by the component. +The users are responsible for providing these volumes when creating a component instance. +Cannot be updated.

    (Optional) -

    Services defines endpoints that can be used to access the component service to manage the component.
    In addition, a reserved headless service will be created by default, with the name pattern {clusterName}-{componentName}-headless.
    Cannot be updated.


    +

    Services defines endpoints that can be used to access the component service to manage the component. +In addition, a reserved headless service will be created by default, with the name pattern {clusterName}-{componentName}-headless. +Cannot be updated.

    (Optional) -

    The configs field provided by provider, and
    finally this configTemplateRefs will be rendered into the user’s own configuration file according to the user’s cluster.
    Cannot be updated.
    TODO: support referencing configs from other components or clusters.


    +

    The configs field provided by provider, and +finally this configTemplateRefs will be rendered into the user’s own configuration file according to the user’s cluster. +Cannot be updated.

    (Optional) -

    LogConfigs is detail log file config which provided by provider.
    Cannot be updated.


    +

    LogConfigs is detail log file config which provided by provider. +Cannot be updated.

    (Optional) -

    Monitor is monitoring config which provided by provider.
    Cannot be updated.


    +

    Monitor is monitoring config which provided by provider. +Cannot be updated.

    (Optional) -

    The scripts field provided by provider, and
    finally this configTemplateRefs will be rendered into the user’s own configuration file according to the user’s cluster.
    Cannot be updated.


    +

    The scripts field provided by provider, and +finally this configTemplateRefs will be rendered into the user’s own configuration file according to the user’s cluster. +Cannot be updated.

    (Optional) -

    PolicyRules defines the namespaced policy rules required by the component.
    If any rule application fails (e.g., due to lack of permissions), the provisioning of the component instance will also fail.
    Cannot be updated.


    +

    PolicyRules defines the namespaced policy rules required by the component. +If any rule application fails (e.g., due to lack of permissions), the provisioning of the component instance will also fail. +Cannot be updated.

    (Optional) -

    Labels defines static labels that will be patched to all k8s resources created for the component.
    If a label key conflicts with any other system labels or user-specified labels, it will be silently ignored.
    Cannot be updated.


    +

    Labels defines static labels that will be patched to all k8s resources created for the component. +If a label key conflicts with any other system labels or user-specified labels, it will be silently ignored. +Cannot be updated.

    (Optional) -

    ReplicasLimit defines the limit of valid replicas supported.
    Cannot be updated.


    +

    ReplicasLimit defines the limit of valid replicas supported. +Cannot be updated.

    (Optional) -

    SystemAccounts defines the pre-defined system accounts required to manage the component.
    TODO(component): accounts KB required
    Cannot be updated.


    +

    SystemAccounts defines the pre-defined system accounts required to manage the component. +Cannot be updated.

    (Optional) -

    UpdateStrategy defines the strategy for updating the component instance.
    Cannot be updated.


    +

    UpdateStrategy defines the strategy for updating the component instance. +Cannot be updated.

    (Optional) -

    Roles defines all the roles that the component can assume.
    Cannot be updated.


    +

    Roles defines all the roles that the component can assume. +Cannot be updated.

    (Optional) -

    RoleArbitrator defines the strategy for electing the component’s active role.
    Cannot be updated.


    +

    RoleArbitrator defines the strategy for electing the component’s active role. +Cannot be updated.

    (Optional) -

    LifecycleActions defines the operational actions that needed to interoperate with the component
    service and processes for lifecycle management.
    Cannot be updated.


    +

    LifecycleActions defines the operational actions that needed to interoperate with the component +service and processes for lifecycle management. +Cannot be updated.

    (Optional) -

    ServiceRefDeclarations is used to declare the service reference of the current component.
    Cannot be updated.


    +

    ServiceRefDeclarations is used to declare the service reference of the current component. +Cannot be updated.

    (Optional) -

    Minimum number of seconds for which a newly created pod should be ready
    without any of its container crashing for it to be considered available.
    Defaults to 0 (pod will be considered available as soon as it is ready)


    +

    Minimum number of seconds for which a newly created pod should be ready +without any of its container crashing for it to be considered available. +Defaults to 0 (pod will be considered available as soon as it is ready)

    @@ -6406,7 +6802,7 @@ int64 @@ -6420,7 +6816,8 @@ Phase @@ -6432,7 +6829,7 @@ string @@ -6443,7 +6840,7 @@ string (Appears on:ComponentDefinitionSpec)

    -

    ComponentLifecycleActions defines a set of operational actions for interacting with component services and processes.


    +

    ComponentLifecycleActions defines a set of operational actions for interacting with component services and processes.

    (Optional) -

    ObservedGeneration is the most recent generation observed for this ComponentDefinition.


    +

    ObservedGeneration is the most recent generation observed for this ComponentDefinition.

    (Optional) -

    Phase valid values are `,Available, 'Unavailable.
    Available is ComponentDefinition become available, and can be used for co-related objects.


    +

    Phase valid values are `,Available, 'Unavailable. +Available is ComponentDefinition become available, and can be used for co-related objects.

    (Optional) -

    Extra message for current phase.


    +

    Extra message for current phase.

    @@ -6464,7 +6861,18 @@ LifecycleActionHandler @@ -6478,7 +6886,10 @@ LifecycleActionHandler @@ -6492,7 +6903,8 @@ RoleProbe @@ -6506,7 +6918,28 @@ ComponentSwitchover @@ -6520,7 +6953,10 @@ LifecycleActionHandler @@ -6534,7 +6970,11 @@ LifecycleActionHandler @@ -6548,7 +6988,9 @@ LifecycleActionHandler @@ -6562,7 +7004,8 @@ LifecycleActionHandler @@ -6576,7 +7019,15 @@ LifecycleActionHandler @@ -6590,7 +7041,14 @@ LifecycleActionHandler @@ -6604,7 +7062,8 @@ LifecycleActionHandler @@ -6618,7 +7077,8 @@ LifecycleActionHandler @@ -6640,7 +7100,7 @@ LifecycleActionHandler (Appears on:Expose, HorizontalScaling, OpsRequestSpec, Reconfigure, ScriptSpec, Switchover, VerticalScaling, VolumeExpansion)

    -

    ComponentOps defines the common variables of component scope operations.


    +

    ComponentOps defines the common variables of component scope operations.

    (Optional) -

    PostProvision defines the actions to be executed and the corresponding policy when a component is created.
    You can define the preCondition for executing PostProvision using Action.PreCondition. The default PostProvision action preCondition is ComponentReady.
    The PostProvision Action will be executed only once.
    Dedicated env vars for the action:
    - KB_CLUSTER_COMPONENT_LIST: The list of all components in the cluster, joined by ‘,’ (e.g., “comp1,comp2”).
    - KB_CLUSTER_COMPONENT_POD_NAME_LIST: The list of all pods name in this component, joined by ‘,’ (e.g., “pod1,pod2”).
    - KB_CLUSTER_COMPONENT_POD_IP_LIST: The list of pod IPs where each pod resides in this component, corresponding one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. joined by ‘,’ (e.g., “podIp1,podIp2”).
    - KB_CLUSTER_COMPONENT_POD_HOST_NAME_LIST: The list of hostName where each pod resides in this component, corresponding one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. joined by ‘,’ (e.g., “hostName1,hostName2”).
    - KB_CLUSTER_COMPONENT_POD_HOST_IP_LIST: The list of host IPs where each pod resides in this component, corresponding one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. joined by ‘,’ (e.g., “hostIp1,hostIp2”).
    Cannot be updated.


    +

    PostProvision defines the actions to be executed and the corresponding policy when a component is created. +You can define the preCondition for executing PostProvision using Action.PreCondition. The default PostProvision action preCondition is ComponentReady. +The PostProvision Action will be executed only once. +Dedicated env vars for the action:

    +
      +
    • KB_CLUSTER_COMPONENT_LIST: The list of all components in the cluster, joined by ‘,’ (e.g., “comp1,comp2”).
    • +
    • KB_CLUSTER_COMPONENT_POD_NAME_LIST: The list of all pods name in this component, joined by ‘,’ (e.g., “pod1,pod2”).
    • +
    • KB_CLUSTER_COMPONENT_POD_IP_LIST: The list of pod IPs where each pod resides in this component, corresponding one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. joined by ‘,’ (e.g., “podIp1,podIp2”).
    • +
    • KB_CLUSTER_COMPONENT_POD_HOST_NAME_LIST: The list of hostName where each pod resides in this component, corresponding one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. joined by ‘,’ (e.g., “hostName1,hostName2”).
    • +
    • KB_CLUSTER_COMPONENT_POD_HOST_IP_LIST: The list of host IPs where each pod resides in this component, corresponding one-to-one with each pod in the KB_CLUSTER_COMPONENT_POD_NAME_LIST. joined by ‘,’ (e.g., “hostIp1,hostIp2”).
    • +
    +

    Cannot be updated.

    (Optional) -

    PreTerminate defines the actions to be executed when a component is terminated due to an API request.
    The PreTerminate Action will be executed only once. Upon receiving a scale-down command for the Component, it is executed immediately.
    Only after the preTerminate action is successfully executed, the destruction of the Component and its underlying resources proceeds.
    Cannot be updated.


    +

    PreTerminate defines the actions to be executed when a component is terminated due to an API request. +The PreTerminate Action will be executed only once. Upon receiving a scale-down command for the Component, it is executed immediately. +Only after the preTerminate action is successfully executed, the destruction of the Component and its underlying resources proceeds. +Cannot be updated.

    (Optional) -

    RoleProbe defines how to probe the role of replicas.
    Cannot be updated.


    +

    RoleProbe defines how to probe the role of replicas. +Cannot be updated.

    (Optional) -

    Switchover defines how to proactively switch the current leader to a new replica to minimize the impact on availability.
    This action is typically invoked when the leader is about to become unavailable due to events, such as:
    - switchover
    - stop
    - restart
    - scale-in
    Dedicated env vars for the action:
    - KB_SWITCHOVER_CANDIDATE_NAME: The name of the new candidate replica’s Pod. It may be empty.
    - KB_SWITCHOVER_CANDIDATE_FQDN: The FQDN of the new candidate replica. It may be empty.
    - KB_LEADER_POD_IP: The IP address of the original leader’s Pod before switchover.
    - KB_LEADER_POD_NAME: The name of the original leader’s Pod before switchover.
    - KB_LEADER_POD_FQDN: The FQDN of the original leader’s Pod before switchover.
    The env vars with following prefix are deprecated and will be removed in the future:
    - KB_REPLICATION_PRIMARYPOD: The prefix of the environment variables of the original primary’s Pod before switchover.
    - KB_CONSENSUS_LEADERPOD: The prefix of the environment variables of the original leader’s Pod before switchover.
    Cannot be updated.


    +

    Switchover defines how to proactively switch the current leader to a new replica to minimize the impact on availability. +This action is typically invoked when the leader is about to become unavailable due to events, such as:

    +
      +
    • switchover
    • +
    • stop
    • +
    • restart
    • +
    • scale-in
    • +
    +

    Dedicated env vars for the action:

    +
      +
    • KB_SWITCHOVER_CANDIDATE_NAME: The name of the new candidate replica’s Pod. It may be empty.
    • +
    • KB_SWITCHOVER_CANDIDATE_FQDN: The FQDN of the new candidate replica. It may be empty.
    • +
    • KB_LEADER_POD_IP: The IP address of the original leader’s Pod before switchover.
    • +
    • KB_LEADER_POD_NAME: The name of the original leader’s Pod before switchover.
    • +
    • KB_LEADER_POD_FQDN: The FQDN of the original leader’s Pod before switchover.
    • +
    +

    The env vars with following prefix are deprecated and will be removed in the future:

    +
      +
    • KB_REPLICATION_PRIMARYPOD: The prefix of the environment variables of the original primary’s Pod before switchover.
    • +
    • KB_CONSENSUS_LEADERPOD: The prefix of the environment variables of the original leader’s Pod before switchover.
    • +
    +

    Cannot be updated.

    (Optional) -

    MemberJoin defines how to add a new replica to the replication group.
    This action is typically invoked when a new replica needs to be added, such as during scale-out.
    It may involve updating configuration, notifying other members, and ensuring data consistency.
    Cannot be updated.


    +

    MemberJoin defines how to add a new replica to the replication group. +This action is typically invoked when a new replica needs to be added, such as during scale-out. +It may involve updating configuration, notifying other members, and ensuring data consistency. +Cannot be updated.

    (Optional) -

    MemberLeave defines how to remove a replica from the replication group.
    This action is typically invoked when a replica needs to be removed, such as during scale-in.
    It may involve configuration updates and notifying other members about the departure,
    but it is advisable to avoid performing data migration within this action.
    Cannot be updated.


    +

    MemberLeave defines how to remove a replica from the replication group. +This action is typically invoked when a replica needs to be removed, such as during scale-in. +It may involve configuration updates and notifying other members about the departure, +but it is advisable to avoid performing data migration within this action. +Cannot be updated.

    (Optional) -

    Readonly defines how to set a replica service as read-only.
    This action is used to protect a replica in case of volume space exhaustion or excessive traffic.
    Cannot be updated.


    +

    Readonly defines how to set a replica service as read-only. +This action is used to protect a replica in case of volume space exhaustion or excessive traffic. +Cannot be updated.

    (Optional) -

    Readwrite defines how to set a replica service as read-write.
    Cannot be updated.


    +

    Readwrite defines how to set a replica service as read-write. +Cannot be updated.

    (Optional) -

    DataPopulate defines how to populate the data to create new replicas.
    This action is typically used when a new replica needs to be constructed, such as:
    - scale-out
    - rebuild
    - clone
    It should write the valid data to stdout without including any extraneous information.
    Cannot be updated.


    +

    DataPopulate defines how to populate the data to create new replicas. +This action is typically used when a new replica needs to be constructed, such as:

    +
      +
    • scale-out
    • +
    • rebuild
    • +
    • clone
    • +
    +

    It should write the valid data to stdout without including any extraneous information. +Cannot be updated.

    (Optional) -

    DataAssemble defines how to assemble data synchronized from external before starting the service for a new replica.
    This action is typically used when creating a new replica, such as:
    - scale-out
    - rebuild
    - clone
    The data will be streamed in via stdin. If any error occurs during the assembly process,
    the action must be able to guarantee idempotence to allow for retries from the beginning.
    Cannot be updated.


    +

    DataAssemble defines how to assemble data synchronized from external before starting the service for a new replica. +This action is typically used when creating a new replica, such as: +- scale-out +- rebuild +- clone +The data will be streamed in via stdin. If any error occurs during the assembly process, +the action must be able to guarantee idempotence to allow for retries from the beginning. +Cannot be updated.

    (Optional) -

    Reconfigure defines how to notify the replica service that there is a configuration update.
    Cannot be updated.


    +

    Reconfigure defines how to notify the replica service that there is a configuration update. +Cannot be updated.

    (Optional) -

    AccountProvision defines how to provision accounts.
    Cannot be updated.


    +

    AccountProvision defines how to provision accounts. +Cannot be updated.

    @@ -6658,7 +7118,7 @@ string @@ -6669,7 +7129,7 @@ string (Appears on:ComponentDefRef)

    -

    ComponentRefEnv specifies name and value of an env.


    +

    ComponentRefEnv specifies name and value of an env.

    -

    componentName cluster component name.


    +

    componentName cluster component name.

    @@ -6687,7 +7147,7 @@ string @@ -6699,7 +7159,7 @@ string @@ -6713,7 +7173,7 @@ ComponentValueFrom @@ -6741,7 +7201,8 @@ string @@ -6752,7 +7213,7 @@ string @@ -6763,7 +7224,7 @@ string (Appears on:ComponentResourceConstraint)

    -

    ComponentResourceConstraintSpec defines the desired state of ComponentResourceConstraint


    +

    ComponentResourceConstraintSpec defines the desired state of ComponentResourceConstraint

    -

    name is the name of the env to be injected, and it must be a C identifier.


    +

    name is the name of the env to be injected, and it must be a C identifier.

    (Optional) -

    value is the value of the env to be injected.


    +

    value is the value of the env to be injected.

    (Optional) -

    valueFrom specifies the source of the env to be injected.


    +

    valueFrom specifies the source of the env to be injected.

    -

    In versions prior to KB 0.8.0, ComponentDefRef is the name of the component definition in the ClusterDefinition.
    In KB 0.8.0 and later versions, ComponentDefRef is the name of ComponentDefinition.


    +

    In versions prior to KB 0.8.0, ComponentDefRef is the name of the component definition in the ClusterDefinition. +In KB 0.8.0 and later versions, ComponentDefRef is the name of ComponentDefinition.

    -

    rules are the constraint rules that will be applied to the component.


    +

    rules are the constraint rules that will be applied to the component.

    @@ -6783,7 +7244,7 @@ string @@ -6797,7 +7258,7 @@ string @@ -6811,7 +7272,7 @@ string @@ -6819,7 +7280,7 @@ string

    ComponentResourceKey (string alias)

    -

    ComponentResourceKey defines the resource key of component, such as pod/pvc.


    +

    ComponentResourceKey defines the resource key of component, such as pod/pvc.

    -

    Component resource constraint rules.


    +

    Component resource constraint rules.

    (Optional) -

    selector is used to bind the resource constraint to cluster definitions based on ClusterDefinition API.


    +

    selector is used to bind the resource constraint to cluster definitions based on ClusterDefinition API.

    (Optional) -

    componentSelector is used to bind the resource constraint to components based on ComponentDefinition API.


    +

    componentSelector is used to bind the resource constraint to components based on ComponentDefinition API.

    @@ -6871,7 +7332,22 @@ bool @@ -6882,7 +7358,7 @@ bool (Appears on:Component)

    -

    ComponentSpec defines the desired state of Component


    +

    ComponentSpec defines the desired state of Component

    (Optional) -

    GeneratePodOrdinalService indicates whether to create a corresponding Service for each Pod of the selected Component.
    If sets to true, a set of Service will be automatically generated for each Pod. And Service.RoleSelector will be ignored.
    They can be referred to by adding the PodOrdinal to the defined ServiceName with named pattern $(Service.ServiceName)-$(PodOrdinal).
    And the Service.Name will also be generated with named pattern $(Service.Name)-$(PodOrdinal).
    The PodOrdinal is zero-based, and the number of generated Services is equal to the number of replicas of the Component.
    For example, a Service might be defined as follows:
    - name: my-service
    serviceName: my-service
    generatePodOrdinalService: true
    spec:
    type: NodePort
    ports:
    - name: http
    port: 80
    targetPort: 8080
    Assuming that the Component has 3 replicas, then three services would be generated: my-service-0, my-service-1, and my-service-2, each pointing to its respective Pod.


    +

    GeneratePodOrdinalService indicates whether to create a corresponding Service for each Pod of the selected Component. +If sets to true, a set of Service will be automatically generated for each Pod. And Service.RoleSelector will be ignored. +They can be referred to by adding the PodOrdinal to the defined ServiceName with named pattern $(Service.ServiceName)-$(PodOrdinal). +And the Service.Name will also be generated with named pattern $(Service.Name)-$(PodOrdinal). +The PodOrdinal is zero-based, and the number of generated Services is equal to the number of replicas of the Component. +For example, a Service might be defined as follows: +- name: my-service +serviceName: my-service +generatePodOrdinalService: true +spec: +type: NodePort +ports: +- name: http +port: 80 +targetPort: 8080 +Assuming that the Component has 3 replicas, then three services would be generated: my-service-0, my-service-1, and my-service-2, each pointing to its respective Pod.

    @@ -6900,7 +7376,7 @@ string @@ -6914,7 +7390,7 @@ ClassDefRef @@ -6928,7 +7404,11 @@ ClassDefRef @@ -6942,7 +7422,7 @@ Kubernetes core/v1.ResourceRequirements @@ -6956,7 +7436,7 @@ Kubernetes core/v1.ResourceRequirements @@ -6967,7 +7447,7 @@ int32 @@ -6992,7 +7472,10 @@ bool @@ -7004,7 +7487,8 @@ bool @@ -7016,7 +7500,7 @@ string @@ -7030,7 +7514,8 @@ Affinity @@ -7044,7 +7529,8 @@ Affinity @@ -7064,24 +7550,33 @@ TLSConfig @@ -7093,7 +7588,7 @@ github.com/apecloud/kubeblocks/apis/workloads/v1alpha1.RsmTransformPolicy @@ -7104,7 +7599,7 @@ github.com/apecloud/kubeblocks/apis/workloads/v1alpha1.RsmTransformPolicy (Appears on:Component)

    -

    ComponentStatus defines the observed state of Component


    +

    ComponentStatus defines the observed state of Component

    -

    compDef is the name of the referenced componentDefinition.


    +

    compDef is the name of the referenced componentDefinition.

    (Optional) -

    classDefRef references the class defined in ComponentClassDefinition.


    +

    classDefRef references the class defined in ComponentClassDefinition.

    (Optional) -

    serviceRefs define service references for the current component. Based on the referenced services, they can be categorized into two types:
    Service provided by external sources: These services are provided by external sources and are not managed by KubeBlocks. They can be Kubernetes-based or non-Kubernetes services. For external services, you need to provide an additional ServiceDescriptor object to establish the service binding.
    Service provided by other KubeBlocks clusters: These services are provided by other KubeBlocks clusters. You can bind to these services by specifying the name of the hosting cluster.
    Each type of service reference requires specific configurations and bindings to establish the connection and interaction with the respective services.
    It should be noted that the ServiceRef has cluster-level semantic consistency, meaning that within the same Cluster, service references with the same ServiceRef.Name are considered to be the same service. It is only allowed to bind to the same Cluster or ServiceDescriptor.


    +

    serviceRefs define service references for the current component. Based on the referenced services, they can be categorized into two types: +Service provided by external sources: These services are provided by external sources and are not managed by KubeBlocks. They can be Kubernetes-based or non-Kubernetes services. For external services, you need to provide an additional ServiceDescriptor object to establish the service binding. +Service provided by other KubeBlocks clusters: These services are provided by other KubeBlocks clusters. You can bind to these services by specifying the name of the hosting cluster. +Each type of service reference requires specific configurations and bindings to establish the connection and interaction with the respective services. +It should be noted that the ServiceRef has cluster-level semantic consistency, meaning that within the same Cluster, service references with the same ServiceRef.Name are considered to be the same service. It is only allowed to bind to the same Cluster or ServiceDescriptor.

    (Optional) -

    Resources requests and limits of workload.


    +

    Resources requests and limits of workload.

    (Optional) -

    VolumeClaimTemplates information for statefulset.spec.volumeClaimTemplates.


    +

    VolumeClaimTemplates information for statefulset.spec.volumeClaimTemplates.

    -

    Replicas specifies the desired number of replicas for the component’s workload.


    +

    Replicas specifies the desired number of replicas for the component’s workload.

    (Optional) -

    monitor is a switch to enable monitoring and is set as false by default.
    KubeBlocks provides an extension mechanism to support component level monitoring,
    which will scrape metrics auto or manually from servers in component and export
    metrics to Time Series Database.


    +

    monitor is a switch to enable monitoring and is set as false by default. +KubeBlocks provides an extension mechanism to support component level monitoring, +which will scrape metrics auto or manually from servers in component and export +metrics to Time Series Database.

    (Optional) -

    enabledLogs indicates which log file takes effect in the database cluster,
    element is the log type which is defined in ComponentDefinition logConfig.name.


    +

    enabledLogs indicates which log file takes effect in the database cluster, +element is the log type which is defined in ComponentDefinition logConfig.name.

    (Optional) -

    serviceAccountName is the name of the ServiceAccount that running component depends on.


    +

    serviceAccountName is the name of the ServiceAccount that running component depends on.

    (Optional) -

    Affinity specifies the scheduling constraints for the component’s workload.
    If specified, it will override the cluster-wide affinity.


    +

    Affinity specifies the scheduling constraints for the component’s workload. +If specified, it will override the cluster-wide affinity.

    (Optional) -

    Tolerations specify the tolerations for the component’s workload.
    If specified, they will override the cluster-wide toleration settings.


    +

    Tolerations specify the tolerations for the component’s workload. +If specified, they will override the cluster-wide toleration settings.

    rsmTransformPolicy
    -github.com/apecloud/kubeblocks/apis/workloads/v1alpha1.RsmTransformPolicy + +RsmTransformPolicy +
    (Optional) -

    RsmTransformPolicy defines the policy generate sts using rsm.
    ToSts: rsm transform to statefulSet
    ToPod: rsm transform to pods


    +

    RsmTransformPolicy defines the policy generate sts using rsm. +ToSts: rsm transform to statefulSet +ToPod: rsm transform to pods

    nodes
    + []k8s.io/apimachinery/pkg/types.NodeName +
    (Optional) -

    Nodes defines the list of nodes that pods can schedule
    If the RsmTransformPolicy is specified as OneToMul,the list of nodes will be used. If the list of nodes is empty,
    no specific node will be assigned. However, if the list of node is filled, all pods will be evenly scheduled
    across the nodes in the list.


    +

    Nodes defines the list of nodes that pods can schedule +If the RsmTransformPolicy is specified as OneToMul,the list of nodes will be used. If the list of nodes is empty, +no specific node will be assigned. However, if the list of node is filled, all pods will be evenly scheduled +across the nodes in the list.

    (Optional) -

    Instances defines the list of instance to be deleted priorly


    +

    Instances defines the list of instance to be deleted priorly

    @@ -7123,7 +7618,9 @@ int64 @@ -7137,7 +7634,7 @@ int64 @@ -7150,7 +7647,15 @@ ClusterComponentPhase @@ -7164,7 +7669,8 @@ ComponentMessageMap @@ -7195,7 +7701,8 @@ Action @@ -7209,7 +7716,8 @@ Action @@ -7223,7 +7731,8 @@ Action @@ -7251,7 +7760,7 @@ string @@ -7262,7 +7771,7 @@ string @@ -7274,7 +7783,8 @@ string @@ -7285,7 +7795,9 @@ string @@ -7297,7 +7809,13 @@ int32 @@ -7327,7 +7845,7 @@ ComponentValueFromType @@ -7339,7 +7857,10 @@ string @@ -7351,7 +7872,11 @@ string @@ -7363,7 +7888,7 @@ string @@ -7374,7 +7899,7 @@ string (Appears on:ComponentValueFrom)

    -

    ComponentValueFromType specifies the type of component value from.


    +

    ComponentValueFromType specifies the type of component value from.

    (Optional) -

    observedGeneration is the most recent generation observed for this Component.
    It corresponds to the Cluster’s generation, which is
    updated on mutation by the API Server.


    +

    observedGeneration is the most recent generation observed for this Component. +It corresponds to the Cluster’s generation, which is +updated on mutation by the API Server.

    (Optional) -

    Describe current state of component API Resource, like warning.


    +

    Describe current state of component API Resource, like warning.

    -

    phase describes the phase of the component and the detail information of the phases are as following:
    Creating: Creating is a special Updating with previous phase empty(means “”) or Creating.
    Running: component replicas > 0 and all pod specs are latest with a Running state.
    Updating: component replicas > 0 and has no failed pods. the component is being updated.
    Abnormal: component replicas > 0 but having some failed pods. the component basically works but in a fragile state.
    Failed: component replicas > 0 but having some failed pods. the component doesn’t work anymore.
    Stopping: component replicas = 0 and has terminating pods.
    Stopped: component replicas = 0 and all pods have been deleted.
    Deleting: the component is being deleted.


    +

    phase describes the phase of the component and the detail information of the phases are as following: +Creating: Creating is a special Updating with previous phase empty(means “”) or Creating. +Running: component replicas > 0 and all pod specs are latest with a Running state. +Updating: component replicas > 0 and has no failed pods. the component is being updated. +Abnormal: component replicas > 0 but having some failed pods. the component basically works but in a fragile state. +Failed: component replicas > 0 but having some failed pods. the component doesn’t work anymore. +Stopping: component replicas = 0 and has terminating pods. +Stopped: component replicas = 0 and all pods have been deleted. +Deleting: the component is being deleted.

    (Optional) -

    message records the component details message in current phase.
    Keys are podName or deployName or statefulSetName. The format is ObjectKind/Name.


    +

    message records the component details message in current phase. +Keys are podName or deployName or statefulSetName. The format is ObjectKind/Name.

    (Optional) -

    withCandidate corresponds to the switchover of the specified candidate primary or leader instance.
    Currently, only Action.Exec is supported, Action.HTTP is not supported.


    +

    withCandidate corresponds to the switchover of the specified candidate primary or leader instance. +Currently, only Action.Exec is supported, Action.HTTP is not supported.

    (Optional) -

    withoutCandidate corresponds to a switchover that does not specify a candidate primary or leader instance.
    Currently, only Action.Exec is supported, Action.HTTP is not supported.


    +

    withoutCandidate corresponds to a switchover that does not specify a candidate primary or leader instance. +Currently, only Action.Exec is supported, Action.HTTP is not supported.

    (Optional) -

    scriptSpecSelectors defines the selector of the scriptSpecs that need to be referenced.
    Once ScriptSpecSelectors is defined, the scripts defined in scripts can be referenced in the Action.


    +

    scriptSpecSelectors defines the selector of the scriptSpecs that need to be referenced. +Once ScriptSpecSelectors is defined, the scripts defined in scripts can be referenced in the Action.

    -

    Specify the name of configuration template.


    +

    Specify the name of configuration template.

    -

    Specify the name of the referenced the configuration template ConfigMap object.


    +

    Specify the name of the referenced the configuration template ConfigMap object.

    (Optional) -

    Specify the namespace of the referenced the configuration template ConfigMap object.
    An empty namespace is equivalent to the “default” namespace.


    +

    Specify the namespace of the referenced the configuration template ConfigMap object. +An empty namespace is equivalent to the “default” namespace.

    -

    volumeName is the volume name of PodTemplate, which the configuration file produced through the configuration
    template will be mounted to the corresponding volume. Must be a DNS_LABEL name.
    The volume name must be defined in podSpec.containers[*].volumeMounts.


    +

    volumeName is the volume name of PodTemplate, which the configuration file produced through the configuration +template will be mounted to the corresponding volume. Must be a DNS_LABEL name. +The volume name must be defined in podSpec.containers[*].volumeMounts.

    (Optional) -

    defaultMode is optional: mode bits used to set permissions on created files by default.
    Must be an octal value between 0000 and 0777 or a decimal value between 0 and 511.
    YAML accepts both octal and decimal values, JSON requires decimal values for mode bits.
    Defaults to 0644.
    Directories within the path are not affected by this setting.
    This might be in conflict with other options that affect the file
    mode, like fsGroup, and the result can be other mode bits set.


    +

    defaultMode is optional: mode bits used to set permissions on created files by default. +Must be an octal value between 0000 and 0777 or a decimal value between 0 and 511. +YAML accepts both octal and decimal values, JSON requires decimal values for mode bits. +Defaults to 0644. +Directories within the path are not affected by this setting. +This might be in conflict with other options that affect the file +mode, like fsGroup, and the result can be other mode bits set.

    -

    type is the type of the source to select. There are three types: FieldRef, ServiceRef, HeadlessServiceRef.


    +

    type is the type of the source to select. There are three types: FieldRef, ServiceRef, HeadlessServiceRef.

    (Optional) -

    fieldRef is the jsonpath of the source to select when type is FieldRef.
    there are two objects registered in the jsonpath: componentDef and components.
    componentDef is the component definition object specified in componentRef.componentDefName.
    components is the component list objects referring to the component definition object.


    +

    fieldRef is the jsonpath of the source to select when type is FieldRef. +there are two objects registered in the jsonpath: componentDef and components. +componentDef is the component definition object specified in componentRef.componentDefName. +components is the component list objects referring to the component definition object.

    (Optional) -

    format is the format of each headless service address.
    there are three builtin variables can be used as placeholder: $POD_ORDINAL, $POD_FQDN, $POD_NAME
    $POD_ORDINAL is the ordinal of the pod.
    $POD_FQDN is the fully qualified domain name of the pod.
    $POD_NAME is the name of the pod


    +

    format is the format of each headless service address. +there are three builtin variables can be used as placeholder: $POD_ORDINAL, $POD_FQDN, $POD_NAME +$POD_ORDINAL is the ordinal of the pod. +$POD_FQDN is the fully qualified domain name of the pod. +$POD_NAME is the name of the pod

    (Optional) -

    joinWith is the string to join the values of headless service addresses.


    +

    joinWith is the string to join the values of headless service addresses.

    @@ -7414,7 +7939,10 @@ string @@ -7426,7 +7954,8 @@ bool @@ -7438,7 +7967,12 @@ int @@ -7449,7 +7983,7 @@ int (Appears on:ConfigConstraintStatus)

    -

    ConfigConstraintPhase defines the ConfigConstraint CR .status.phase


    +

    ConfigConstraintPhase defines the ConfigConstraint CR .status.phase

    -

    The Name of the volume.
    Must be a DNS_LABEL and unique within the pod.
    More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
    Cannot be updated.


    +

    The Name of the volume. +Must be a DNS_LABEL and unique within the pod. +More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names +Cannot be updated.

    (Optional) -

    NeedSnapshot indicates whether the volume need to snapshot when making a backup for the component.
    Cannot be updated.


    +

    NeedSnapshot indicates whether the volume need to snapshot when making a backup for the component. +Cannot be updated.

    (Optional) -

    HighWatermark defines the high watermark threshold for the volume space usage.
    If there is any specified volumes who’s space usage is over the threshold, the pre-defined “LOCK” action
    will be triggered to degrade the service to protect volume from space exhaustion, such as to set the instance
    as read-only. And after that, if all volumes’ space usage drops under the threshold later, the pre-defined
    “UNLOCK” action will be performed to recover the service normally.
    Cannot be updated.


    +

    HighWatermark defines the high watermark threshold for the volume space usage. +If there is any specified volumes who’s space usage is over the threshold, the pre-defined “LOCK” action +will be triggered to degrade the service to protect volume from space exhaustion, such as to set the instance +as read-only. And after that, if all volumes’ space usage drops under the threshold later, the pre-defined +“UNLOCK” action will be performed to recover the service normally. +Cannot be updated.

    @@ -7472,7 +8006,7 @@ int (Appears on:ConfigConstraint)

    -

    ConfigConstraintSpec defines the desired state of ConfigConstraint


    +

    ConfigConstraintSpec defines the desired state of ConfigConstraint

    @@ -7493,7 +8027,9 @@ ReloadOptions @@ -7507,7 +8043,7 @@ ToolsImageSpec @@ -7521,7 +8057,7 @@ ToolsImageSpec @@ -7535,7 +8071,7 @@ ToolsImageSpec @@ -7547,7 +8083,7 @@ string @@ -7561,7 +8097,7 @@ CustomParametersValidation @@ -7573,7 +8109,7 @@ CustomParametersValidation @@ -7585,7 +8121,7 @@ CustomParametersValidation @@ -7597,7 +8133,7 @@ CustomParametersValidation @@ -7610,7 +8146,8 @@ Kubernetes meta/v1.LabelSelector @@ -7623,7 +8160,10 @@ FormatterConfig @@ -7634,7 +8174,7 @@ FormatterConfig (Appears on:ConfigConstraint)

    -

    ConfigConstraintStatus defines the observed state of ConfigConstraint.


    +

    ConfigConstraintStatus defines the observed state of ConfigConstraint.

    (Optional) -

    reloadOptions indicates whether the process supports reload.
    if set, the controller will determine the behavior of the engine instance based on the configuration templates,
    restart or reload depending on whether any parameters in the StaticParameters have been modified.


    +

    reloadOptions indicates whether the process supports reload. +if set, the controller will determine the behavior of the engine instance based on the configuration templates, +restart or reload depending on whether any parameters in the StaticParameters have been modified.

    (Optional) -

    toolConfig used to config init container.


    +

    toolConfig used to config init container.

    (Optional) -

    downwardAPIOptions is used to watch pod fields.


    +

    downwardAPIOptions is used to watch pod fields.

    (Optional) -

    scriptConfigs, list of ScriptConfig, witch these scripts can be used by volume trigger,downward trigger, or tool image


    +

    scriptConfigs, list of ScriptConfig, witch these scripts can be used by volume trigger,downward trigger, or tool image

    (Optional) -

    cfgSchemaTopLevelName is cue type name, which generates openapi schema.


    +

    cfgSchemaTopLevelName is cue type name, which generates openapi schema.

    (Optional) -

    configurationSchema imposes restrictions on database parameter’s rule.


    +

    configurationSchema imposes restrictions on database parameter’s rule.

    (Optional) -

    staticParameters, list of StaticParameter, modifications of them trigger a process restart.


    +

    staticParameters, list of StaticParameter, modifications of them trigger a process restart.

    (Optional) -

    dynamicParameters, list of DynamicParameter, modifications of them trigger a config dynamic reload without process restart.


    +

    dynamicParameters, list of DynamicParameter, modifications of them trigger a config dynamic reload without process restart.

    (Optional) -

    immutableParameters describes parameters that prohibit user from modification.


    +

    immutableParameters describes parameters that prohibit user from modification.

    -

    selector is used to match the label on the pod,
    for example, a pod of the primary is match on the patroni cluster.


    +

    selector is used to match the label on the pod, +for example, a pod of the primary is match on the patroni cluster.

    -

    formatterConfig describes the format of the configuration file, the controller
    1. parses configuration file
    2. analyzes the modified parameters
    3. applies corresponding policies.


    +

    formatterConfig describes the format of the configuration file, the controller +1. parses configuration file +2. analyzes the modified parameters +3. applies corresponding policies.

    @@ -7655,7 +8195,7 @@ ConfigConstraintPhase @@ -7667,7 +8207,7 @@ string @@ -7679,7 +8219,9 @@ int64 @@ -7724,7 +8266,7 @@ Kubernetes core/v1.ConfigMapVolumeSource @@ -7753,7 +8295,7 @@ string @@ -7765,7 +8307,7 @@ map[string]*string @@ -7793,7 +8335,7 @@ string @@ -7805,7 +8347,8 @@ string @@ -7819,7 +8362,7 @@ MergedPolicy @@ -7847,7 +8390,7 @@ string @@ -7861,7 +8404,7 @@ UpgradePolicy @@ -7874,7 +8417,7 @@ UpgradePolicy @@ -7902,7 +8445,7 @@ string @@ -7914,7 +8457,8 @@ string @@ -7928,7 +8472,7 @@ Payload @@ -7942,7 +8486,7 @@ ComponentConfigSpec @@ -7956,7 +8500,7 @@ ConfigTemplateExtension @@ -7964,13 +8508,13 @@ ConfigTemplateExtension configFileParams
    -map[string]..ConfigParams +map[string]github.com/apecloud/kubeblocks/apis/apps/v1alpha1.ConfigParams @@ -7998,7 +8542,7 @@ string @@ -8012,7 +8556,7 @@ ConfigurationPhase @@ -8024,7 +8568,7 @@ string @@ -8036,7 +8580,7 @@ string @@ -8048,7 +8592,7 @@ string @@ -8062,7 +8606,7 @@ ReconcileDetail @@ -8090,7 +8634,7 @@ string @@ -8104,7 +8648,7 @@ UpgradePolicy @@ -8116,7 +8660,7 @@ string @@ -8128,7 +8672,7 @@ string @@ -8140,7 +8684,7 @@ int32 @@ -8152,7 +8696,7 @@ int32 @@ -8164,7 +8708,7 @@ string @@ -8176,7 +8720,7 @@ map[string]string @@ -8190,7 +8734,7 @@ UpdatedParameters @@ -8201,7 +8745,7 @@ UpdatedParameters (Appears on:ConfigurationItemDetailStatus)

    -

    ConfigurationPhase defines the Configuration FSM phase


    +

    ConfigurationPhase defines the Configuration FSM phase

    (Optional) -

    phase is status of configuration template, when set to CCAvailablePhase, it can be referenced by ClusterDefinition or ClusterVersion.


    +

    phase is status of configuration template, when set to CCAvailablePhase, it can be referenced by ClusterDefinition or ClusterVersion.

    (Optional) -

    message field describes the reasons of abnormal status.


    +

    message field describes the reasons of abnormal status.

    (Optional) -

    observedGeneration is the latest generation observed for this
    ClusterDefinition. It refers to the ConfigConstraint’s generation, which is
    updated by the API Server.


    +

    observedGeneration is the latest generation observed for this +ClusterDefinition. It refers to the ConfigConstraint’s generation, which is +updated by the API Server.

    -

    configMap defines the configmap volume source.


    +

    configMap defines the configmap volume source.

    (Optional) -

    fileContent indicates the configuration file content.


    +

    fileContent indicates the configuration file content.

    (Optional) -

    updated parameters for a single configuration file.


    +

    updated parameters for a single configuration file.

    -

    Specify the name of the referenced the configuration template ConfigMap object.


    +

    Specify the name of the referenced the configuration template ConfigMap object.

    (Optional) -

    Specify the namespace of the referenced the configuration template ConfigMap object.
    An empty namespace is equivalent to the “default” namespace.


    +

    Specify the namespace of the referenced the configuration template ConfigMap object. +An empty namespace is equivalent to the “default” namespace.

    (Optional) -

    policy defines how to merge external imported templates into component templates.


    +

    policy defines how to merge external imported templates into component templates.

    -

    name is a config template name.


    +

    name is a config template name.

    (Optional) -

    policy defines the upgrade policy.


    +

    policy defines the upgrade policy.

    -

    keys is used to set the parameters to be updated.


    +

    keys is used to set the parameters to be updated.

    -

    Specify the name of configuration template.


    +

    Specify the name of configuration template.

    (Optional) -

    Deprecated: Please use payload instead.
    version is the version of configuration template.


    +

    Deprecated: Please use payload instead. +version is the version of configuration template.

    (Optional) -

    Payload holds the configuration-related rerender.


    +

    Payload holds the configuration-related rerender.

    (Optional) -

    configSpec is used to set the configuration template.


    +

    configSpec is used to set the configuration template.

    (Optional) -

    Specify the configuration template.


    +

    Specify the configuration template.

    (Optional) -

    configFileParams is used to set the parameters to be updated.


    +

    configFileParams is used to set the parameters to be updated.

    -

    name is a config template name.


    +

    name is a config template name.

    (Optional) -

    phase is status of configurationItem.


    +

    phase is status of configurationItem.

    (Optional) -

    lastDoneRevision is the last done revision of configurationItem.


    +

    lastDoneRevision is the last done revision of configurationItem.

    (Optional) -

    updateRevision is the update revision of configurationItem.


    +

    updateRevision is the update revision of configurationItem.

    (Optional) -

    message field describes the reasons of abnormal status.


    +

    message field describes the reasons of abnormal status.

    (Optional) -

    reconcileDetail describes the details of the configuration change execution.


    +

    reconcileDetail describes the details of the configuration change execution.

    -

    name is a config template name.


    +

    name is a config template name.

    (Optional) -

    updatePolicy describes the policy of reconfiguring.


    +

    updatePolicy describes the policy of reconfiguring.

    (Optional) -

    status describes the current state of the reconfiguring state machine.


    +

    status describes the current state of the reconfiguring state machine.

    (Optional) -

    message describes the details about this operation.


    +

    message describes the details about this operation.

    (Optional) -

    succeedCount describes the number of successful reconfiguring.


    +

    succeedCount describes the number of successful reconfiguring.

    (Optional) -

    expectedCount describes the number of expected reconfiguring.


    +

    expectedCount describes the number of expected reconfiguring.

    (Optional) -

    lastStatus describes the last status for the reconfiguring controller.


    +

    lastStatus describes the last status for the reconfiguring controller.

    (Optional) -

    LastAppliedConfiguration describes the last configuration.


    +

    LastAppliedConfiguration describes the last configuration.

    (Optional) -

    updatedParameters describes the updated parameters.


    +

    updatedParameters describes the updated parameters.

    @@ -8240,7 +8784,7 @@ UpdatedParameters (Appears on:Configuration)

    -

    ConfigurationSpec defines the desired state of Configuration


    +

    ConfigurationSpec defines the desired state of Configuration

    @@ -8258,7 +8802,7 @@ string @@ -8269,7 +8813,7 @@ string @@ -8283,7 +8827,7 @@ string @@ -8294,7 +8838,7 @@ string (Appears on:Configuration)

    -

    ConfigurationStatus defines the observed state of Configuration


    +

    ConfigurationStatus defines the observed state of Configuration

    -

    clusterRef references Cluster name.


    +

    clusterRef references Cluster name.

    -

    componentName is cluster component name.


    +

    componentName is cluster component name.

    (Optional) -

    customConfigurationItems describes user-defined config template.


    +

    customConfigurationItems describes user-defined config template.

    @@ -8313,7 +8857,7 @@ string @@ -8325,7 +8869,9 @@ int64 @@ -8339,7 +8885,7 @@ int64 @@ -8352,7 +8898,7 @@ int64 @@ -8383,7 +8929,7 @@ CredentialVar @@ -8397,7 +8943,7 @@ CredentialVar @@ -8426,7 +8972,8 @@ string @@ -8438,7 +8985,8 @@ string @@ -8449,7 +8997,7 @@ string @@ -8460,7 +9008,7 @@ string @@ -8488,7 +9036,7 @@ string @@ -8501,7 +9049,7 @@ AccessMode @@ -8513,7 +9061,10 @@ int32 @@ -8558,7 +9109,7 @@ ConsensusMember @@ -8572,7 +9123,7 @@ ConsensusMember @@ -8586,7 +9137,7 @@ ConsensusMember @@ -8615,7 +9166,15 @@ string @@ -8629,7 +9188,7 @@ Kubernetes core/v1.EnvVarSource @@ -8640,7 +9199,7 @@ Kubernetes core/v1.EnvVarSource (Appears on:VarSource)

    -

    CredentialVarSelector selects a var from a Credential (SystemAccount).


    +

    CredentialVarSelector selects a var from a Credential (SystemAccount).

    (Optional) -

    message field describes the reasons of abnormal status.


    +

    message field describes the reasons of abnormal status.

    (Optional) -

    observedGeneration is the latest generation observed for this
    ClusterDefinition. It refers to the ConfigConstraint’s generation, which is
    updated by the API Server.


    +

    observedGeneration is the latest generation observed for this +ClusterDefinition. It refers to the ConfigConstraint’s generation, which is +updated by the API Server.

    (Optional) -

    conditions describes opsRequest detail status.


    +

    conditions describes opsRequest detail status.

    -

    configurationStatus describes the status of the component reconfiguring.


    +

    configurationStatus describes the status of the component reconfiguring.

    (Optional) -

    service connection based-on username and password credential.


    +

    service connection based-on username and password credential.

    (Optional) -

    service connection based-on username and password credential.


    +

    service connection based-on username and password credential.

    (Optional) -

    the key of password in the ConnectionCredential secret.
    if not set, the default key is “password”.


    +

    the key of password in the ConnectionCredential secret. +if not set, the default key is “password”.

    (Optional) -

    the key of username in the ConnectionCredential secret.
    if not set, the default key is “username”.


    +

    the key of username in the ConnectionCredential secret. +if not set, the default key is “username”.

    -

    hostKey specifies the map key of the host in the connection credential secret.


    +

    hostKey specifies the map key of the host in the connection credential secret.

    -

    portKey specifies the map key of the port in the connection credential secret.


    +

    portKey specifies the map key of the port in the connection credential secret.

    -

    name, role name.


    +

    name, role name.

    -

    accessMode, what service this member capable.


    +

    accessMode, what service this member capable.

    (Optional) -

    replicas, number of Pods of this role.
    default 1 for Leader
    default 0 for Learner
    default Cluster.spec.componentSpec[*].Replicas - Leader.Replicas - Learner.Replicas for Followers


    +

    replicas, number of Pods of this role. +default 1 for Leader +default 0 for Learner +default Cluster.spec.componentSpec[*].Replicas - Leader.Replicas - Learner.Replicas for Followers

    -

    leader, one single leader.


    +

    leader, one single leader.

    (Optional) -

    followers, has voting right but not Leader.


    +

    followers, has voting right but not Leader.

    (Optional) -

    learner, no voting right.


    +

    learner, no voting right.

    (Optional) -

    Variable references $(VAR_NAME) are expanded
    using the previously defined environment variables in the container and
    any service environment variables. If a variable cannot be resolved,
    the reference in the input string will be unchanged. Double $$ are reduced
    to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e.
    “$$(VAR_NAME)” will produce the string literal “$(VAR_NAME)”.
    Escaped references will never be expanded, regardless of whether the variable
    exists or not.
    Defaults to “”.


    +

    Variable references $(VAR_NAME) are expanded +using the previously defined environment variables in the container and +any service environment variables. If a variable cannot be resolved, +the reference in the input string will be unchanged. Double $$ are reduced +to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. +“$$(VAR_NAME)” will produce the string literal “$(VAR_NAME)”. +Escaped references will never be expanded, regardless of whether the variable +exists or not. +Defaults to “”.

    (Optional) -

    Source for the environment variable’s value. Cannot be used if value is not empty.


    +

    Source for the environment variable’s value. Cannot be used if value is not empty.

    @@ -8663,7 +9222,7 @@ ClusterObjectReference

    (Members of ClusterObjectReference are embedded into this type.)

    -

    The Credential (SystemAccount) to select from.


    +

    The Credential (SystemAccount) to select from.

    @@ -8689,7 +9248,8 @@ CredentialVars (Appears on:CredentialVarSelector, ServiceRefVars)

    -

    CredentialVars defines the vars can be referenced from a Credential (SystemAccount).
    !!!!! CredentialVars will only be used as environment variables for Pods & Actions, and will not be used to render the templates.


    +

    CredentialVars defines the vars can be referenced from a Credential (SystemAccount). +!!!!! CredentialVars will only be used as environment variables for Pods & Actions, and will not be used to render the templates.

    @@ -8750,7 +9310,7 @@ string @@ -8761,7 +9321,7 @@ string @@ -8774,7 +9334,7 @@ string @@ -8802,7 +9362,7 @@ string @@ -8813,7 +9373,7 @@ string @@ -8825,7 +9385,9 @@ string @@ -8855,7 +9417,7 @@ Kubernetes api extensions v1.JSONSchemaProps @@ -8867,7 +9429,7 @@ string @@ -8895,7 +9457,7 @@ string @@ -8906,7 +9468,7 @@ string @@ -8919,7 +9481,7 @@ string @@ -8931,7 +9493,7 @@ string @@ -8959,7 +9521,7 @@ string @@ -8972,7 +9534,7 @@ ValueFrom @@ -8983,7 +9545,7 @@ ValueFrom (Appears on:ComponentDefinitionSpec)

    -

    EnvVar represents a variable present in the env of Pod/Action or the template of config/script.


    +

    EnvVar represents a variable present in the env of Pod/Action or the template of config/script.

    -

    key name of label


    +

    key name of label

    -

    value of label


    +

    value of label

    -

    resources defines the resources to be labeled.


    +

    resources defines the resources to be labeled.

    -

    cluster component name.


    +

    cluster component name.

    -

    reference a opsDefinition


    +

    reference a opsDefinition

    (Optional) -

    the input for this operation declared in the opsDefinition.spec.parametersSchema.
    will create corresponding jobs for each array element.
    if the param type is array, the format must be “v1,v2,v3”.


    +

    the input for this operation declared in the opsDefinition.spec.parametersSchema. +will create corresponding jobs for each array element. +if the param type is array, the format must be “v1,v2,v3”.

    -

    schema provides a way for providers to validate the changed parameters through json.


    +

    schema provides a way for providers to validate the changed parameters through json.

    (Optional) -

    cue that to let provider verify user configuration through cue language.


    +

    cue that to let provider verify user configuration through cue language.

    -

    Specify the name of the field.


    +

    Specify the name of the field.

    -

    mountPoint is the mount point of the scripts file.


    +

    mountPoint is the mount point of the scripts file.

    -

    Items is a list of downward API volume file


    +

    Items is a list of downward API volume file

    (Optional) -

    command used to execute for downwrad api.


    +

    command used to execute for downwrad api.

    -

    env key which needs to mapping.


    +

    env key which needs to mapping.

    -

    valueFrom defines source of the env value.


    +

    valueFrom defines source of the env value.

    @@ -9001,7 +9563,7 @@ string @@ -9013,7 +9575,12 @@ string @@ -9027,7 +9594,7 @@ VarSource @@ -9056,7 +9623,8 @@ string @@ -9067,7 +9635,7 @@ string @@ -9096,7 +9664,11 @@ string @@ -9108,7 +9680,7 @@ string @@ -9138,7 +9710,7 @@ Kubernetes api utils intstr.IntOrString @@ -9150,7 +9722,7 @@ string @@ -9195,7 +9767,8 @@ ExposeSwitch @@ -9208,7 +9781,7 @@ ExposeSwitch @@ -9219,7 +9792,7 @@ ExposeSwitch (Appears on:Expose)

    -

    ExposeSwitch defines the switch of expose operation.


    +

    ExposeSwitch defines the switch of expose operation.

    -

    Name of the variable. Must be a C_IDENTIFIER.


    +

    Name of the variable. Must be a C_IDENTIFIER.

    (Optional) -

    Variable references $(VAR_NAME) are expanded using the previously defined variables in the current context.
    If a variable cannot be resolved, the reference in the input string will be unchanged.
    Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e.
    “$$(VAR_NAME)” will produce the string literal “$(VAR_NAME)”.
    Escaped references will never be expanded, regardless of whether the variable exists or not.
    Defaults to “”.


    +

    Variable references $(VAR_NAME) are expanded using the previously defined variables in the current context. +If a variable cannot be resolved, the reference in the input string will be unchanged. +Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. +“$$(VAR_NAME)” will produce the string literal “$(VAR_NAME)”. +Escaped references will never be expanded, regardless of whether the variable exists or not. +Defaults to “”.

    (Optional) -

    Source for the variable’s value. Cannot be used if value is not empty.


    +

    Source for the variable’s value. Cannot be used if value is not empty.

    (Optional) -

    container name which defines in componentDefinition or is injected by kubeBlocks controller.
    if not specified, will use the first container by default.


    +

    container name which defines in componentDefinition or is injected by kubeBlocks controller. +if not specified, will use the first container by default.

    -

    env name, it will .


    +

    env name, it will .

    (Optional) -

    Command is the command line to execute inside the container, the working directory for the
    command is root (‘/’) in the container’s filesystem. The command is simply exec’d, it is
    not run inside a shell, so traditional shell instructions (‘|’, etc) won’t work. To use
    a shell, you need to explicitly call out to that shell.
    Exit status of 0 is treated as live/healthy and non-zero is unhealthy.


    +

    Command is the command line to execute inside the container, the working directory for the +command is root (‘/’) in the container’s filesystem. The command is simply exec’d, it is +not run inside a shell, so traditional shell instructions (‘|’, etc) won’t work. To use +a shell, you need to explicitly call out to that shell. +Exit status of 0 is treated as live/healthy and non-zero is unhealthy.

    (Optional) -

    args is used to perform statements.


    +

    args is used to perform statements.

    -

    scrapePort is exporter port for Time Series Database to scrape metrics.


    +

    scrapePort is exporter port for Time Series Database to scrape metrics.

    (Optional) -

    scrapePath is exporter url path for Time Series Database to scrape metrics.


    +

    scrapePath is exporter url path for Time Series Database to scrape metrics.

    -

    switch defines the switch of expose operation.
    if switch is set to Enable, the service will be exposed. if switch is set to Disable, the service will be removed.


    +

    switch defines the switch of expose operation. +if switch is set to Enable, the service will be exposed. if switch is set to Disable, the service will be removed.

    -

    Setting the list of services to be exposed or removed.


    +

    Setting the list of services to be exposed or removed.

    @@ -9240,7 +9813,7 @@ ExposeSwitch (Appears on:ComponentDefRef)

    -

    FailurePolicyType specifies the type of failure policy


    +

    FailurePolicyType specifies the type of failure policy

    @@ -9250,9 +9823,11 @@ ExposeSwitch - + - +

    "Fail"

    ReportError means that an error will be reported.


    ReportError means that an error will be reported.

    +

    "Ignore"

    Ignore means that an error will be ignored but logged.


    Ignore means that an error will be ignored but logged.

    +

    FormatterConfig @@ -9284,7 +9859,8 @@ FormatterOptions (Members of FormatterOptions are embedded into this type.)

    (Optional) -

    The FormatterOptions represents the special options of configuration file.
    This is optional for now. If not specified.


    +

    The FormatterOptions represents the special options of configuration file. +This is optional for now. If not specified.

    @@ -9297,7 +9873,17 @@ CfgFileFormat -

    The configuration file format. Valid values are ini, xml, yaml, json,
    hcl, dotenv, properties and toml.



    ini: a configuration file that consists of a text-based content with a structure and syntax comprising key–value pairs for properties, reference wiki: https://en.wikipedia.org/wiki/INI_file
    xml: reference wiki: https://en.wikipedia.org/wiki/XML
    yaml: a configuration file support for complex data types and structures.
    json: reference wiki: https://en.wikipedia.org/wiki/JSON
    hcl: : The HashiCorp Configuration Language (HCL) is a configuration language authored by HashiCorp, reference url: https://www.linode.com/docs/guides/introduction-to-hcl/
    dotenv: this was a plain text file with simple key–value pairs, reference wiki: https://en.wikipedia.org/wiki/Configuration_file#MS-DOS
    properties: a file extension mainly used in Java, reference wiki: https://en.wikipedia.org/wiki/.properties
    toml: reference wiki: https://en.wikipedia.org/wiki/TOML
    props-plus: a file extension mainly used in Java, support CamelCase(e.g: brokerMaxConnectionsPerIp)


    +

    The configuration file format. Valid values are ini, xml, yaml, json, +hcl, dotenv, properties and toml.

    +

    ini: a configuration file that consists of a text-based content with a structure and syntax comprising key–value pairs for properties, reference wiki: https://en.wikipedia.org/wiki/INI_file +xml: reference wiki: https://en.wikipedia.org/wiki/XML +yaml: a configuration file support for complex data types and structures. +json: reference wiki: https://en.wikipedia.org/wiki/JSON +hcl: : The HashiCorp Configuration Language (HCL) is a configuration language authored by HashiCorp, reference url: https://www.linode.com/docs/guides/introduction-to-hcl/ +dotenv: this was a plain text file with simple key–value pairs, reference wiki: https://en.wikipedia.org/wiki/Configuration_file#MS-DOS +properties: a file extension mainly used in Java, reference wiki: https://en.wikipedia.org/wiki/.properties +toml: reference wiki: https://en.wikipedia.org/wiki/TOML +props-plus: a file extension mainly used in Java, support CamelCase(e.g: brokerMaxConnectionsPerIp)

    @@ -9308,7 +9894,8 @@ CfgFileFormat (Appears on:FormatterConfig)

    -

    FormatterOptions represents the special options of configuration file.
    Only one of its members may be specified.


    +

    FormatterOptions represents the special options of configuration file. +Only one of its members may be specified.

    @@ -9329,7 +9916,7 @@ IniConfig @@ -9357,7 +9944,8 @@ string @@ -9369,7 +9957,7 @@ map[string]string @@ -9380,7 +9968,7 @@ map[string]string (Appears on:HorizontalScalePolicy)

    -

    HScaleDataClonePolicyType defines data clone policy when horizontal scaling.


    +

    HScaleDataClonePolicyType defines data clone policy when horizontal scaling.

    (Optional) -

    iniConfig represents the ini options.


    +

    iniConfig represents the ini options.

    -

    gvk is Group/Version/Kind, for example “v1/Pod”, “apps/v1/StatefulSet”, etc.
    when the gvk resource filtered by the selector already exists, if there is no corresponding custom label, it will be added, and if label already exists, it will be updated.


    +

    gvk is Group/Version/Kind, for example “v1/Pod”, “apps/v1/StatefulSet”, etc. +when the gvk resource filtered by the selector already exists, if there is no corresponding custom label, it will be added, and if label already exists, it will be updated.

    (Optional) -

    selector is a label query over a set of resources.


    +

    selector is a label query over a set of resources.

    @@ -9403,7 +9991,7 @@ map[string]string (Appears on:Action)

    -

    HTTPAction describes an action based on HTTP requests.


    +

    HTTPAction describes an action based on HTTP requests.

    @@ -9422,7 +10010,7 @@ string @@ -9435,7 +10023,9 @@ Kubernetes api utils intstr.IntOrString @@ -9447,7 +10037,8 @@ string @@ -9461,7 +10052,8 @@ Kubernetes core/v1.URIScheme @@ -9473,7 +10065,8 @@ string @@ -9487,7 +10080,7 @@ string @@ -9518,7 +10111,13 @@ HScaleDataClonePolicyType @@ -9530,7 +10129,7 @@ string @@ -9542,7 +10141,9 @@ string @@ -9553,7 +10154,7 @@ string (Appears on:OpsRequestSpec)

    -

    HorizontalScaling defines the variables of horizontal scaling operation


    +

    HorizontalScaling defines the variables of horizontal scaling operation

    (Optional) -

    Path to access on the HTTP server.


    +

    Path to access on the HTTP server.

    -

    Name or number of the port to access on the container.
    Number must be in the range 1 to 65535.
    Name must be an IANA_SVC_NAME.


    +

    Name or number of the port to access on the container. +Number must be in the range 1 to 65535. +Name must be an IANA_SVC_NAME.

    (Optional) -

    Host name to connect to, defaults to the pod IP. You probably want to set
    “Host” in httpHeaders instead.


    +

    Host name to connect to, defaults to the pod IP. You probably want to set +“Host” in httpHeaders instead.

    (Optional) -

    Scheme to use for connecting to the host.
    Defaults to HTTP.


    +

    Scheme to use for connecting to the host. +Defaults to HTTP.

    (Optional) -

    Method represents the HTTP request method, which can be one of the standard HTTP methods like “GET,” “POST,” “PUT,” etc.
    Defaults to Get.


    +

    Method represents the HTTP request method, which can be one of the standard HTTP methods like “GET,” “POST,” “PUT,” etc. +Defaults to Get.

    (Optional) -

    Custom headers to set in the request. HTTP allows repeated headers.


    +

    Custom headers to set in the request. HTTP allows repeated headers.

    (Optional) -

    type controls what kind of data synchronization do when component scale out.
    Policy is in enum of {None, CloneVolume}. The default policy is None.
    None: Default policy, create empty volume and no data clone.
    CloneVolume: Do data clone to newly scaled pods. Prefer to use volume snapshot first,
    and will try backup tool if volume snapshot is not enabled, finally
    report error if both above cannot work.
    Snapshot: Deprecated, alias for CloneVolume.


    +

    type controls what kind of data synchronization do when component scale out. +Policy is in enum of {None, CloneVolume}. The default policy is None. +None: Default policy, create empty volume and no data clone. +CloneVolume: Do data clone to newly scaled pods. Prefer to use volume snapshot first, +and will try backup tool if volume snapshot is not enabled, finally +report error if both above cannot work. +Snapshot: Deprecated, alias for CloneVolume.

    (Optional) -

    BackupPolicyTemplateName reference the backup policy template.


    +

    BackupPolicyTemplateName reference the backup policy template.

    (Optional) -

    volumeMountsName defines which volumeMount of the container to do backup,
    only work if Type is not None
    if not specified, the 1st volumeMount will be chosen


    +

    volumeMountsName defines which volumeMount of the container to do backup, +only work if Type is not None +if not specified, the 1st volumeMount will be chosen

    @@ -9586,19 +10187,24 @@ int32 @@ -9610,7 +10216,13 @@ int32 @@ -9639,7 +10251,7 @@ string @@ -9650,7 +10262,7 @@ string (Appears on:ClusterComponentSpec, TLSConfig)

    -

    Issuer defines Tls certs issuer


    +

    Issuer defines Tls certs issuer

    -

    replicas for the workloads.


    +

    replicas for the workloads.

    nodes
    + []k8s.io/apimachinery/pkg/types.NodeName +
    (Optional) -

    Nodes defines the list of nodes that pods can schedule when scale up
    If the RsmTransformPolicy is specified as ToPod and expected replicas is more than current replicas,the list of
    Nodes will be used. If the list of Nodes is empty, no specific node will be assigned. However, if the list of Nodes
    is filled, all pods will be evenly scheduled across the Nodes in the list when scale up.


    +

    Nodes defines the list of nodes that pods can schedule when scale up +If the RsmTransformPolicy is specified as ToPod and expected replicas is more than current replicas,the list of +Nodes will be used. If the list of Nodes is empty, no specific node will be assigned. However, if the list of Nodes +is filled, all pods will be evenly scheduled across the Nodes in the list when scale up.

    (Optional) -

    Instances defines the name of instance that rsm scale down priorly.
    If the RsmTransformPolicy is specified as ToPod and expected replicas is less than current replicas, the list of
    Instances will be used.
    current replicas - expected replicas > len(Instances): Scale down from the list of Instances priorly, the others
    will select from NodeAssignment.
    current replicas - expected replicas < len(Instances): Scale down from the list of Instances.
    current replicas - expected replicas < len(Instances): Scale down from a part of Instances.


    +

    Instances defines the name of instance that rsm scale down priorly. +If the RsmTransformPolicy is specified as ToPod and expected replicas is less than current replicas, the list of +Instances will be used. +current replicas - expected replicas > len(Instances): Scale down from the list of Instances priorly, the others +will select from NodeAssignment. +current replicas - expected replicas < len(Instances): Scale down from the list of Instances. +current replicas - expected replicas < len(Instances): Scale down from a part of Instances.

    (Optional) -

    sectionName describes ini section.


    +

    sectionName describes ini section.

    @@ -9670,7 +10282,12 @@ IssuerName @@ -9684,7 +10301,8 @@ TLSSecretRef @@ -9695,7 +10313,7 @@ TLSSecretRef (Appears on:Issuer)

    -

    IssuerName defines Tls certs issuer name


    +

    IssuerName defines Tls certs issuer name

    -

    Name of issuer.
    Options supported:
    - KubeBlocks - Certificates signed by KubeBlocks Operator.
    - UserProvided - User provided own CA-signed certificates.


    +

    Name of issuer. +Options supported:

    +
      +
    • KubeBlocks - Certificates signed by KubeBlocks Operator.
    • +
    • UserProvided - User provided own CA-signed certificates.
    • +
    (Optional) -

    secretRef. TLS certs Secret reference
    required when from is UserProvided


    +

    secretRef. TLS certs Secret reference +required when from is UserProvided

    @@ -9705,15 +10323,17 @@ TLSSecretRef - + - +

    "KubeBlocks"

    IssuerKubeBlocks Certificates signed by KubeBlocks Operator.


    IssuerKubeBlocks Certificates signed by KubeBlocks Operator.

    +

    "UserProvided"

    IssuerUserProvided User provided own CA-signed certificates.


    IssuerUserProvided User provided own CA-signed certificates.

    +

    KBAccountType (byte alias)

    -

    KBAccountType is used for bitwise operation.


    +

    KBAccountType is used for bitwise operation.

    @@ -9750,7 +10370,7 @@ int32 @@ -9767,7 +10387,7 @@ Kubernetes core/v1.ResourceRequirements (Members of ResourceRequirements are embedded into this type.)

    (Optional) -

    the last resources of the component.


    +

    the last resources of the component.

    @@ -9781,7 +10401,7 @@ ClassDefRef @@ -9795,7 +10415,7 @@ ClassDefRef @@ -9809,19 +10429,20 @@ ClassDefRef @@ -9850,7 +10471,7 @@ string @@ -9858,13 +10479,13 @@ string components
    -map[string]..LastComponentConfiguration +map[string]github.com/apecloud/kubeblocks/apis/apps/v1alpha1.LastComponentConfiguration @@ -9907,7 +10528,7 @@ ConfigTemplateExtension (Appears on:PasswordConfig)

    -

    LetterCase defines cases to use in password generation.


    +

    LetterCase defines cases to use in password generation.

    (Optional) -

    replicas are the last replicas of the component.


    +

    replicas are the last replicas of the component.

    (Optional) -

    classDefRef reference class defined in ComponentClassDefinition.


    +

    classDefRef reference class defined in ComponentClassDefinition.

    (Optional) -

    volumeClaimTemplates records the last volumeClaimTemplates of the component.


    +

    volumeClaimTemplates records the last volumeClaimTemplates of the component.

    (Optional) -

    services records the last services of the component.


    +

    services records the last services of the component.

    targetResources
    -map[..ComponentResourceKey][]string +map[github.com/apecloud/kubeblocks/apis/apps/v1alpha1.ComponentResourceKey][]string
    (Optional) -

    targetResources records the affecting target resources information for the component.
    resource key is in list of [pods].


    +

    targetResources records the affecting target resources information for the component. +resource key is in list of [pods].

    (Optional) -

    clusterVersionRef references ClusterVersion name.


    +

    clusterVersionRef references ClusterVersion name.

    (Optional) -

    components records last configuration of the component.


    +

    components records last configuration of the component.

    @@ -9950,7 +10571,9 @@ BuiltinActionHandlerType @@ -9964,7 +10587,7 @@ Action @@ -9992,7 +10615,7 @@ string @@ -10003,7 +10626,8 @@ string @@ -10034,7 +10658,9 @@ Kubernetes resource.Quantity @@ -10048,7 +10674,10 @@ Kubernetes resource.Quantity @@ -10062,7 +10691,10 @@ Kubernetes resource.Quantity @@ -10073,7 +10705,7 @@ Kubernetes resource.Quantity (Appears on:ConfigTemplateExtension)

    -

    MergedPolicy defines how to merge external imported templates into component templates.


    +

    MergedPolicy defines how to merge external imported templates into component templates.

    (Optional) -

    builtinHandler specifies the builtin action handler name to do the action.
    the BuiltinHandler within the same ComponentLifecycleActions should be consistent. Details can be queried through official documentation in the future.
    use CustomHandler to define your own actions if none of them satisfies the requirement.


    +

    builtinHandler specifies the builtin action handler name to do the action. +the BuiltinHandler within the same ComponentLifecycleActions should be consistent. Details can be queried through official documentation in the future. +use CustomHandler to define your own actions if none of them satisfies the requirement.

    (Optional) -

    customHandler defines the custom way to do action.


    +

    customHandler defines the custom way to do action.

    -

    name log type name, such as slow for MySQL slow log file.


    +

    name log type name, such as slow for MySQL slow log file.

    -

    filePathPattern log file path pattern which indicate how to find this file
    corresponding to variable (log path) in database kernel. please don’t set this casually.


    +

    filePathPattern log file path pattern which indicate how to find this file +corresponding to variable (log path) in database kernel. please don’t set this casually.

    (Optional) -

    The size of memory per vcpu core.
    For example: 1Gi, 200Mi.
    If SizePerCPU is specified, MinPerCPU and MaxPerCPU are ignore.


    +

    The size of memory per vcpu core. +For example: 1Gi, 200Mi. +If SizePerCPU is specified, MinPerCPU and MaxPerCPU are ignore.

    (Optional) -

    The maximum size of memory per vcpu core, [MinPerCPU, MaxPerCPU] defines a range for valid memory size per vcpu core.
    It is useful on GCP as the ratio between the CPU and memory may be a range.
    If SizePerCPU is specified, MinPerCPU and MaxPerCPU are ignored.
    Reference: https://cloud.google.com/compute/docs/general-purpose-machines#custom_machine_types


    +

    The maximum size of memory per vcpu core, [MinPerCPU, MaxPerCPU] defines a range for valid memory size per vcpu core. +It is useful on GCP as the ratio between the CPU and memory may be a range. +If SizePerCPU is specified, MinPerCPU and MaxPerCPU are ignored. +Reference: https://cloud.google.com/compute/docs/general-purpose-machines#custom_machine_types

    (Optional) -

    The minimum size of memory per vcpu core, [MinPerCPU, MaxPerCPU] defines a range for valid memory size per vcpu core.
    It is useful on GCP as the ratio between the CPU and memory may be a range.
    If SizePerCPU is specified, MinPerCPU and MaxPerCPU are ignored.
    Reference: https://cloud.google.com/compute/docs/general-purpose-machines#custom_machine_types


    +

    The minimum size of memory per vcpu core, [MinPerCPU, MaxPerCPU] defines a range for valid memory size per vcpu core. +It is useful on GCP as the ratio between the CPU and memory may be a range. +If SizePerCPU is specified, MinPerCPU and MaxPerCPU are ignored. +Reference: https://cloud.google.com/compute/docs/general-purpose-machines#custom_machine_types

    @@ -10116,7 +10748,9 @@ bool @@ -10130,7 +10764,8 @@ ExporterConfig @@ -10182,7 +10817,7 @@ VarOption (Appears on:OpsDefinition)

    -

    OpsDefinitionSpec defines the desired state of OpsDefinition


    +

    OpsDefinitionSpec defines the desired state of OpsDefinition

    (Optional) -

    builtIn is a switch to enable KubeBlocks builtIn monitoring.
    If BuiltIn is set to true, monitor metrics will be scraped automatically.
    If BuiltIn is set to false, the provider should set ExporterConfig and Sidecar container own.


    +

    builtIn is a switch to enable KubeBlocks builtIn monitoring. +If BuiltIn is set to true, monitor metrics will be scraped automatically. +If BuiltIn is set to false, the provider should set ExporterConfig and Sidecar container own.

    (Optional) -

    exporterConfig provided by provider, which specify necessary information to Time Series Database.
    exporterConfig is valid when builtIn is false.


    +

    exporterConfig provided by provider, which specify necessary information to Time Series Database. +exporterConfig is valid when builtIn is false.

    @@ -10202,7 +10837,9 @@ VarOption @@ -10216,7 +10853,7 @@ VarsRef @@ -10230,7 +10867,7 @@ ParametersSchema @@ -10243,7 +10880,7 @@ Kubernetes batch/v1.JobSpec @@ -10257,7 +10894,7 @@ Kubernetes batch/v1.JobSpec @@ -10268,7 +10905,7 @@ Kubernetes batch/v1.JobSpec (Appears on:OpsDefinition)

    -

    OpsDefinitionStatus defines the observed state of OpsDefinition


    +

    OpsDefinitionStatus defines the observed state of OpsDefinition

    -

    componentDefinitionRefs indicates which types of componentDefinitions are supported by the operation,
    and can refer some vars of the componentDefinition.
    if it is set, the component that does not meet the conditions will be intercepted.


    +

    componentDefinitionRefs indicates which types of componentDefinitions are supported by the operation, +and can refer some vars of the componentDefinition. +if it is set, the component that does not meet the conditions will be intercepted.

    (Optional) -

    varsRef defines the envs that need to be referenced from the target component pod, and will inject to job’s containers.


    +

    varsRef defines the envs that need to be referenced from the target component pod, and will inject to job’s containers.

    (Optional) -

    parametersSchema describes the schema used for validation, pruning, and defaulting.


    +

    parametersSchema describes the schema used for validation, pruning, and defaulting.

    -

    jobSpec describes the job spec for the operation.


    +

    jobSpec describes the job spec for the operation.

    (Optional) -

    preCondition if it meets the requirements to run the job for the operation.


    +

    preCondition if it meets the requirements to run the job for the operation.

    @@ -10287,7 +10924,7 @@ int64 @@ -10301,7 +10938,8 @@ Phase @@ -10313,7 +10951,7 @@ string @@ -10341,7 +10979,7 @@ string @@ -10354,7 +10992,7 @@ OpsVarSource @@ -10365,7 +11003,7 @@ OpsVarSource (Appears on:OpsRequestStatus)

    -

    OpsPhase defines opsRequest phase.


    +

    OpsPhase defines opsRequest phase.

    (Optional) -

    ObservedGeneration is the most recent generation observed for this OpsDefinition.


    +

    ObservedGeneration is the most recent generation observed for this OpsDefinition.

    (Optional) -

    Phase valid values are `,Available, 'Unavailable.
    Available is OpsDefinition become available, and can be used for co-related objects.


    +

    Phase valid values are `,Available, 'Unavailable. +Available is OpsDefinition become available, and can be used for co-related objects.

    (Optional) -

    Extra message for current phase.


    +

    Extra message for current phase.

    -

    Name of the variable. Must be a C_IDENTIFIER.


    +

    Name of the variable. Must be a C_IDENTIFIER.

    -

    Source for the variable’s value. Cannot be used if value is not empty.


    +

    Source for the variable’s value. Cannot be used if value is not empty.

    @@ -10410,7 +11048,7 @@ string @@ -10423,7 +11061,7 @@ OpsType @@ -10434,7 +11072,7 @@ bool @@ -10503,7 +11141,7 @@ ClusterComponentPhase @@ -10517,7 +11155,7 @@ Kubernetes meta/v1.Time @@ -10531,7 +11169,7 @@ Kubernetes meta/v1.Time @@ -10545,7 +11183,7 @@ WorkloadType @@ -10557,7 +11195,7 @@ string @@ -10569,7 +11207,7 @@ string @@ -10580,7 +11218,7 @@ string (Appears on:OpsRequest)

    -

    OpsRequestSpec defines the desired state of OpsRequest


    +

    OpsRequestSpec defines the desired state of OpsRequest

    -

    name OpsRequest name


    +

    name OpsRequest name

    -

    opsRequest type


    +

    opsRequest type

    -

    indicates whether the current opsRequest is in the queue


    +

    indicates whether the current opsRequest is in the queue

    (Optional) -

    phase describes the component phase, reference Cluster.status.component.phase.


    +

    phase describes the component phase, reference Cluster.status.component.phase.

    (Optional) -

    lastFailedTime is the last time the component phase transitioned to Failed or Abnormal.


    +

    lastFailedTime is the last time the component phase transitioned to Failed or Abnormal.

    (Optional) -

    progressDetails describes the progress details of the component for this operation.


    +

    progressDetails describes the progress details of the component for this operation.

    (Optional) -

    workloadType references workload type of component in ClusterDefinition.


    +

    workloadType references workload type of component in ClusterDefinition.

    (Optional) -

    reason describes the reason for the component phase.


    +

    reason describes the reason for the component phase.

    (Optional) -

    message is a human-readable message indicating details about this operation.


    +

    message is a human-readable message indicating details about this operation.

    @@ -10598,7 +11236,7 @@ string @@ -10610,7 +11248,8 @@ bool @@ -10623,7 +11262,7 @@ OpsType @@ -10635,7 +11274,7 @@ int32 @@ -10649,7 +11288,7 @@ Upgrade @@ -10663,7 +11302,7 @@ Upgrade @@ -10677,7 +11316,7 @@ Upgrade @@ -10691,7 +11330,7 @@ Upgrade @@ -10705,7 +11344,7 @@ Upgrade @@ -10719,7 +11358,7 @@ Upgrade @@ -10733,7 +11372,7 @@ Reconfigure @@ -10747,7 +11386,7 @@ Reconfigure @@ -10761,7 +11400,7 @@ Reconfigure @@ -10775,7 +11414,7 @@ RestoreFromSpec @@ -10787,7 +11426,8 @@ int32 @@ -10801,7 +11441,7 @@ ScriptSpec @@ -10815,7 +11455,7 @@ BackupSpec @@ -10829,7 +11469,8 @@ RestoreSpec @@ -10852,7 +11493,7 @@ CustomOpsSpec (Appears on:OpsRequest)

    -

    OpsRequestStatus defines the observed state of OpsRequest


    +

    OpsRequestStatus defines the observed state of OpsRequest

    -

    clusterRef references cluster object.


    +

    clusterRef references cluster object.

    (Optional) -

    cancel defines the action to cancel the Pending/Creating/Running opsRequest, supported types: [VerticalScaling, HorizontalScaling].
    once cancel is set to true, this opsRequest will be canceled and modifying this property again will not take effect.


    +

    cancel defines the action to cancel the Pending/Creating/Running opsRequest, supported types: [VerticalScaling, HorizontalScaling]. +once cancel is set to true, this opsRequest will be canceled and modifying this property again will not take effect.

    -

    type defines the operation type.


    +

    type defines the operation type.

    (Optional) -

    ttlSecondsAfterSucceed OpsRequest will be deleted after TTLSecondsAfterSucceed second when OpsRequest.status.phase is Succeed.


    +

    ttlSecondsAfterSucceed OpsRequest will be deleted after TTLSecondsAfterSucceed second when OpsRequest.status.phase is Succeed.

    (Optional) -

    upgrade specifies the cluster version by specifying clusterVersionRef.


    +

    upgrade specifies the cluster version by specifying clusterVersionRef.

    (Optional) -

    horizontalScaling defines what component need to horizontal scale the specified replicas.


    +

    horizontalScaling defines what component need to horizontal scale the specified replicas.

    (Optional) -

    volumeExpansion defines what component and volumeClaimTemplate need to expand the specified storage.


    +

    volumeExpansion defines what component and volumeClaimTemplate need to expand the specified storage.

    (Optional) -

    restart the specified components.


    +

    restart the specified components.

    (Optional) -

    switchover the specified components.


    +

    switchover the specified components.

    (Optional) -

    verticalScaling defines what component need to vertical scale the specified compute resources.


    +

    verticalScaling defines what component need to vertical scale the specified compute resources.

    (Optional) -

    reconfigure defines the variables that need to input when updating configuration.


    +

    reconfigure defines the variables that need to input when updating configuration.

    (Optional) -

    reconfigure defines the variables that need to input when updating configuration.


    +

    reconfigure defines the variables that need to input when updating configuration.

    (Optional) -

    expose defines services the component needs to expose.


    +

    expose defines services the component needs to expose.

    (Optional) -

    cluster RestoreFrom backup or point in time


    +

    cluster RestoreFrom backup or point in time

    (Optional) -

    ttlSecondsBeforeAbort OpsRequest will wait at most TTLSecondsBeforeAbort seconds for start-conditions to be met.
    If not specified, the default value is 0, which means that the start-conditions must be met immediately.


    +

    ttlSecondsBeforeAbort OpsRequest will wait at most TTLSecondsBeforeAbort seconds for start-conditions to be met. +If not specified, the default value is 0, which means that the start-conditions must be met immediately.

    (Optional) -

    scriptSpec defines the script to be executed.


    +

    scriptSpec defines the script to be executed.

    (Optional) -

    backupSpec defines how to backup the cluster.


    +

    backupSpec defines how to backup the cluster.

    (Optional) -

    restoreSpec defines how to restore the cluster.
    note that this restore operation will roll back cluster services.


    +

    restoreSpec defines how to restore the cluster. +note that this restore operation will roll back cluster services.

    @@ -10871,7 +11512,7 @@ int64 @@ -10884,7 +11525,7 @@ OpsPhase @@ -10908,7 +11549,7 @@ LastConfiguration @@ -10916,13 +11557,13 @@ LastConfiguration components
    -map[string]..OpsRequestComponentStatus +map[string]github.com/apecloud/kubeblocks/apis/apps/v1alpha1.OpsRequestComponentStatus @@ -10936,7 +11577,7 @@ Kubernetes meta/v1.Time @@ -10950,7 +11591,7 @@ Kubernetes meta/v1.Time @@ -10964,7 +11605,7 @@ Kubernetes meta/v1.Time @@ -10978,7 +11619,7 @@ ReconfiguringStatus @@ -10986,13 +11627,13 @@ ReconfiguringStatus reconfiguringStatusAsComponent
    -map[string]*..ReconfiguringStatus +map[string]*github.com/apecloud/kubeblocks/apis/apps/v1alpha1.ReconfiguringStatus @@ -11006,7 +11647,7 @@ map[string]*..ReconfiguringStatus @@ -11036,7 +11677,7 @@ Kubernetes resource.Quantity @@ -11047,7 +11688,7 @@ string @@ -11075,7 +11716,10 @@ string @@ -11087,7 +11731,8 @@ map[string]string @@ -11101,7 +11746,10 @@ map[string]string @@ -11113,7 +11761,7 @@ string @@ -11125,7 +11773,12 @@ map[string]string @@ -11139,7 +11792,22 @@ Kubernetes core/v1.ServiceType @@ -11150,7 +11818,7 @@ Kubernetes core/v1.ServiceType (Appears on:OpsRecorder, OpsRequestSpec)

    -

    OpsType defines operation types.


    +

    OpsType defines operation types.

    (Optional) -

    ClusterGeneration records the cluster generation after handling the opsRequest action.


    +

    ClusterGeneration records the cluster generation after handling the opsRequest action.

    -

    phase describes OpsRequest phase.


    +

    phase describes OpsRequest phase.

    (Optional) -

    lastConfiguration records the last configuration before this operation take effected.


    +

    lastConfiguration records the last configuration before this operation take effected.

    (Optional) -

    components defines the recorded the status information of changed components for operation request.


    +

    components defines the recorded the status information of changed components for operation request.

    (Optional) -

    startTimestamp The time when the OpsRequest started processing.


    +

    startTimestamp The time when the OpsRequest started processing.

    (Optional) -

    completionTimestamp defines the OpsRequest completion time.


    +

    completionTimestamp defines the OpsRequest completion time.

    (Optional) -

    CancelTimestamp defines cancel time.


    +

    CancelTimestamp defines cancel time.

    (Optional) -

    reconfiguringStatus defines the status information of reconfiguring.


    +

    reconfiguringStatus defines the status information of reconfiguring.

    (Optional) -

    reconfiguringStatus defines the status information of reconfiguring.


    +

    reconfiguringStatus defines the status information of reconfiguring.

    (Optional) -

    conditions describes opsRequest detail status.


    +

    conditions describes opsRequest detail status.

    -

    Request storage size.


    +

    Request storage size.

    -

    name references volumeClaimTemplate name from cluster components.


    +

    name references volumeClaimTemplate name from cluster components.

    -

    Name defines the name of the service.
    otherwise, it indicates the name of the service.
    Others can refer to this service by its name. (e.g., connection credential)
    Cannot be updated.


    +

    Name defines the name of the service. +otherwise, it indicates the name of the service. +Others can refer to this service by its name. (e.g., connection credential) +Cannot be updated.

    (Optional) -

    If ServiceType is LoadBalancer, cloud provider related parameters can be put here
    More info: https://kubernetes.io/docs/concepts/services-networking/service/#loadbalancer.


    +

    If ServiceType is LoadBalancer, cloud provider related parameters can be put here +More info: https://kubernetes.io/docs/concepts/services-networking/service/#loadbalancer.

    (Optional) -

    The list of ports that are exposed by this service.
    If Ports are not provided, the default Services Ports defined in the ClusterDefinition or ComponentDefinition that are neither of NodePort nor LoadBalancer service type will be used.
    If there is no corresponding Service defined in the ClusterDefinition or ComponentDefinition, the expose operation will fail.
    More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies


    +

    The list of ports that are exposed by this service. +If Ports are not provided, the default Services Ports defined in the ClusterDefinition or ComponentDefinition that are neither of NodePort nor LoadBalancer service type will be used. +If there is no corresponding Service defined in the ClusterDefinition or ComponentDefinition, the expose operation will fail. +More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies

    (Optional) -

    RoleSelector extends the ServiceSpec.Selector by allowing you to specify defined role as selector for the service.


    +

    RoleSelector extends the ServiceSpec.Selector by allowing you to specify defined role as selector for the service.

    (Optional) -

    Route service traffic to pods with label keys and values matching this
    selector. If empty or not present, the service is assumed to have an
    external process managing its endpoints, which Kubernetes will not
    modify. Only applies to types ClusterIP, NodePort, and LoadBalancer.
    Ignored if type is ExternalName.
    More info: https://kubernetes.io/docs/concepts/services-networking/service/


    +

    Route service traffic to pods with label keys and values matching this +selector. If empty or not present, the service is assumed to have an +external process managing its endpoints, which Kubernetes will not +modify. Only applies to types ClusterIP, NodePort, and LoadBalancer. +Ignored if type is ExternalName. +More info: https://kubernetes.io/docs/concepts/services-networking/service/

    (Optional) -

    type determines how the Service is exposed. Defaults to ClusterIP. Valid
    options are ExternalName, ClusterIP, NodePort, and LoadBalancer.
    “ClusterIP” allocates a cluster-internal IP address for load-balancing
    to endpoints. Endpoints are determined by the selector or if that is not
    specified, by manual construction of an Endpoints object or
    EndpointSlice objects. If clusterIP is “None”, no virtual IP is
    allocated and the endpoints are published as a set of endpoints rather
    than a virtual IP.
    “NodePort” builds on ClusterIP and allocates a port on every node which
    routes to the same endpoints as the clusterIP.
    “LoadBalancer” builds on NodePort and creates an external load-balancer
    (if supported in the current cloud) which routes to the same endpoints
    as the clusterIP.
    “ExternalName” aliases this service to the specified externalName.
    Several other fields do not apply to ExternalName services.
    More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types


    +

    type determines how the Service is exposed. Defaults to ClusterIP. Valid +options are ExternalName, ClusterIP, NodePort, and LoadBalancer. +“ClusterIP” allocates a cluster-internal IP address for load-balancing +to endpoints. Endpoints are determined by the selector or if that is not +specified, by manual construction of an Endpoints object or +EndpointSlice objects. If clusterIP is “None”, no virtual IP is +allocated and the endpoints are published as a set of endpoints rather +than a virtual IP. +“NodePort” builds on ClusterIP and allocates a port on every node which +routes to the same endpoints as the clusterIP. +“LoadBalancer” builds on NodePort and creates an external load-balancer +(if supported in the current cloud) which routes to the same endpoints +as the clusterIP. +“ExternalName” aliases this service to the specified externalName. +Several other fields do not apply to ExternalName services. +More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types

    @@ -11160,13 +11828,15 @@ Kubernetes core/v1.ServiceType - + - + @@ -11176,9 +11846,11 @@ Kubernetes core/v1.ServiceType - + - + @@ -11214,7 +11886,8 @@ EnvVarRef @@ -11242,7 +11915,7 @@ string @@ -11256,7 +11929,8 @@ string @@ -11268,7 +11942,8 @@ string @@ -11296,7 +11971,7 @@ string @@ -11308,7 +11983,8 @@ string @@ -11339,7 +12015,14 @@ Kubernetes api extensions v1.JSONSchemaProps @@ -11350,7 +12033,7 @@ Kubernetes api extensions v1.JSONSchemaProps (Appears on:SystemAccount, SystemAccountSpec)

    -

    PasswordConfig helps provide to customize complexity of password generation pattern.


    +

    PasswordConfig helps provide to customize complexity of password generation pattern.

    "Backup"

    DataScriptType the data script operation will execute the data script against the cluster.


    DataScriptType the data script operation will execute the data script against the cluster.

    +

    "Custom"

    "DataScript"

    "Expose"

    StartType the start operation will start the pods which is deleted in stop operation.


    StartType the start operation will start the pods which is deleted in stop operation.

    +

    "HorizontalScaling"

    "Reconfiguring"

    "Restore"

    "Start"

    StopType the stop operation will delete all pods in a cluster concurrently.


    StopType the stop operation will delete all pods in a cluster concurrently.

    +

    "Stop"

    RestartType the restart operation is a special case of the rolling update operation.


    RestartType the restart operation is a special case of the rolling update operation.

    +

    "Switchover"

    "Upgrade"

    -

    envVarRef defines which container and env that the variable references from.
    source: “env” or “envFrom” of the container.


    +

    envVarRef defines which container and env that the variable references from. +source: “env” or “envFrom” of the container.

    -

    key indicates the key name of ConfigMap.


    +

    key indicates the key name of ConfigMap.

    (Optional) -

    Setting the list of parameters for a single configuration file.
    update specified the parameters.


    +

    Setting the list of parameters for a single configuration file. +update specified the parameters.

    (Optional) -

    fileContent indicates the configuration file content.
    update whole file.


    +

    fileContent indicates the configuration file content. +update whole file.

    -

    key is name of the parameter to be updated.


    +

    key is name of the parameter to be updated.

    (Optional) -

    parameter values to be updated.
    if set nil, the parameter defined by the key field will be deleted from the configuration file.


    +

    parameter values to be updated. +if set nil, the parameter defined by the key field will be deleted from the configuration file.

    (Optional) -

    openAPIV3Schema is the OpenAPI v3 schema to use for parameter schema.
    supported properties types:
    - string
    - number
    - integer
    - array: only supported the item with string type.


    +

    openAPIV3Schema is the OpenAPI v3 schema to use for parameter schema. +supported properties types:

    +
      +
    • string
    • +
    • number
    • +
    • integer
    • +
    • array: only supported the item with string type.
    • +
    @@ -11369,7 +12052,7 @@ int32 @@ -11381,7 +12064,7 @@ int32 @@ -11393,7 +12076,7 @@ int32 @@ -11407,7 +12090,7 @@ LetterCase @@ -11419,7 +12102,8 @@ string @@ -11478,7 +12162,8 @@ map[string]any @@ -11492,7 +12177,11 @@ Kubernetes core/v1.ResourceRequirements @@ -11504,7 +12193,8 @@ string @@ -11518,7 +12208,7 @@ Kubernetes core/v1.PersistentVolumeMode @@ -11529,7 +12219,7 @@ Kubernetes core/v1.PersistentVolumeMode (Appears on:ClusterDefinitionStatus, ClusterVersionStatus, ComponentDefinitionStatus, OpsDefinitionStatus, ServiceDescriptorStatus)

    -

    Phase defines the ClusterDefinition and ClusterVersion CR .status.phase


    +

    Phase defines the ClusterDefinition and ClusterVersion CR .status.phase

    (Optional) -

    length defines the length of password.


    +

    length defines the length of password.

    (Optional) -

    numDigits defines number of digits.


    +

    numDigits defines number of digits.

    (Optional) -

    numSymbols defines number of symbols.


    +

    numSymbols defines number of symbols.

    (Optional) -

    letterCase defines to use lower-cases, upper-cases or mixed-cases of letters.


    +

    letterCase defines to use lower-cases, upper-cases or mixed-cases of letters.

    (Optional) -

    seed specifies the seed used to generate the account’s password.
    Cannot be updated.


    +

    seed specifies the seed used to generate the account’s password. +Cannot be updated.

    (Optional) -

    accessModes contains the desired access modes the volume should have.
    More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1.


    +

    accessModes contains the desired access modes the volume should have. +More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1.

    (Optional) -

    resources represents the minimum resources the volume should have.
    If RecoverVolumeExpansionFailure feature is enabled users are allowed to specify resource requirements
    that are lower than previous value but must still be higher than capacity recorded in the
    status field of the claim.
    More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources.


    +

    resources represents the minimum resources the volume should have. +If RecoverVolumeExpansionFailure feature is enabled users are allowed to specify resource requirements +that are lower than previous value but must still be higher than capacity recorded in the +status field of the claim. +More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources.

    (Optional) -

    storageClassName is the name of the StorageClass required by the claim.
    More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1.


    +

    storageClassName is the name of the StorageClass required by the claim. +More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1.

    (Optional) -

    volumeMode defines what type of volume is required by the claim.


    +

    volumeMode defines what type of volume is required by the claim.

    @@ -11550,7 +12240,7 @@ Kubernetes core/v1.PersistentVolumeMode (Appears on:Affinity)

    -

    PodAntiAffinity defines pod anti-affinity strategy.


    +

    PodAntiAffinity defines pod anti-affinity strategy.

    @@ -11571,7 +12261,7 @@ Kubernetes core/v1.PersistentVolumeMode (Appears on:VarsRef)

    -

    PodSelectionStrategy pod selection strategy.


    +

    PodSelectionStrategy pod selection strategy.

    @@ -11612,7 +12302,7 @@ Kubernetes meta/v1.Time @@ -11626,7 +12316,7 @@ RefNamespaceName @@ -11656,7 +12346,7 @@ CmdExecutorConfig @@ -11670,7 +12360,8 @@ CmdExecutorConfig @@ -11700,7 +12391,7 @@ Rule @@ -11714,7 +12405,8 @@ PreConditionExec @@ -11742,7 +12434,7 @@ string @@ -11756,7 +12448,7 @@ string @@ -11768,7 +12460,7 @@ string @@ -11780,7 +12472,7 @@ string @@ -11791,7 +12483,7 @@ string (Appears on:Action)

    -

    PreConditionType defines the preCondition type of the action execution.


    +

    PreConditionType defines the preCondition type of the action execution.

    (Optional) -

    specify the time point to restore, with UTC as the time zone.


    +

    specify the time point to restore, with UTC as the time zone.

    (Optional) -

    specify a reference source cluster to restore


    +

    specify a reference source cluster to restore

    -

    cmdExecutorConfig is the executor configuration of the post-start command.


    +

    cmdExecutorConfig is the executor configuration of the post-start command.

    (Optional) -

    scriptSpecSelectors defines the selector of the scriptSpecs that need to be referenced.
    Once ScriptSpecSelectors is defined, the scripts defined in scriptSpecs can be referenced in the PostStartAction.CmdExecutorConfig.


    +

    scriptSpecSelectors defines the selector of the scriptSpecs that need to be referenced. +Once ScriptSpecSelectors is defined, the scripts defined in scriptSpecs can be referenced in the PostStartAction.CmdExecutorConfig.

    -

    condition declares how the operation can be executed.


    +

    condition declares how the operation can be executed.

    (Optional) -

    a job will be run to execute preCondition.
    and the operation will be executed when the exec job is succeed.


    +

    a job will be run to execute preCondition. +and the operation will be executed when the exec job is succeed.

    -

    image name.


    +

    image name.

    (Optional) -

    container env.


    +

    container env.

    (Optional) -

    container commands.


    +

    container commands.

    (Optional) -

    container args.


    +

    container args.

    @@ -11816,7 +12508,7 @@ string (Appears on:ProgressStatusDetail)

    -

    ProgressStatus defines the status of the opsRequest progress.


    +

    ProgressStatus defines the status of the opsRequest progress.

    @@ -11859,7 +12551,8 @@ string @@ -11870,7 +12563,7 @@ string @@ -11883,7 +12576,7 @@ ProgressStatus @@ -11895,7 +12588,7 @@ string @@ -11909,7 +12602,7 @@ Kubernetes meta/v1.Time @@ -11923,7 +12616,7 @@ Kubernetes meta/v1.Time @@ -11952,7 +12645,7 @@ string @@ -11964,7 +12657,8 @@ int @@ -11975,7 +12669,7 @@ int (Appears on:SystemAccountConfig)

    -

    ProvisionPolicy defines the policy details for creating accounts.


    +

    ProvisionPolicy defines the policy details for creating accounts.

    (Optional) -

    group describes which group the current object belongs to.
    if the objects of a component belong to the same group, we can ignore it.


    +

    group describes which group the current object belongs to. +if the objects of a component belong to the same group, we can ignore it.

    -

    objectKey is the unique key of the object.


    +

    objectKey is the unique key of the object.

    -

    status describes the state of processing the object.


    +

    status describes the state of processing the object.

    (Optional) -

    message is a human readable message indicating details about the object condition.


    +

    message is a human readable message indicating details about the object condition.

    (Optional) -

    startTime is the start time of object processing.


    +

    startTime is the start time of object processing.

    (Optional) -

    endTime is the completion time of object processing.


    +

    endTime is the completion time of object processing.

    (Optional) -

    Name of volume to protect.


    +

    Name of volume to protect.

    (Optional) -

    Volume specified high watermark threshold, it will override the component level threshold.
    If the value is invalid, it will be ignored and the component level threshold will be used.


    +

    Volume specified high watermark threshold, it will override the component level threshold. +If the value is invalid, it will be ignored and the component level threshold will be used.

    @@ -11995,7 +12689,7 @@ ProvisionPolicyType @@ -12008,7 +12702,7 @@ ProvisionScope @@ -12022,7 +12716,7 @@ ProvisionStatements @@ -12036,7 +12730,7 @@ ProvisionSecretRef @@ -12047,7 +12741,7 @@ ProvisionSecretRef (Appears on:ProvisionPolicy)

    -

    ProvisionPolicyType defines the policy for creating accounts.


    +

    ProvisionPolicyType defines the policy for creating accounts.

    -

    type defines the way to provision an account, either CreateByStmt or ReferToExisting.


    +

    type defines the way to provision an account, either CreateByStmt or ReferToExisting.

    -

    scope is the scope to provision account, and the scope could be AnyPods or AllPods.


    +

    scope is the scope to provision account, and the scope could be AnyPods or AllPods.

    (Optional) -

    statements will be used when Type is CreateByStmt.


    +

    statements will be used when Type is CreateByStmt.

    (Optional) -

    secretRef will be used when Type is ReferToExisting.


    +

    secretRef will be used when Type is ReferToExisting.

    @@ -12057,9 +12751,11 @@ ProvisionSecretRef - + - +

    "CreateByStmt"

    CreateByStmt will create account w.r.t. deletion and creation statement given by provider.


    CreateByStmt will create account w.r.t. deletion and creation statement given by provider.

    +

    "ReferToExisting"

    ReferToExisting will not create account, but create a secret by copying data from referred secret file.


    ReferToExisting will not create account, but create a secret by copying data from referred secret file.

    +

    ProvisionScope @@ -12068,7 +12764,7 @@ ProvisionSecretRef (Appears on:ProvisionPolicy)

    -

    ProvisionScope defines the scope (within component) of provision.


    +

    ProvisionScope defines the scope (within component) of provision.

    @@ -12078,9 +12774,11 @@ ProvisionSecretRef - + - +

    "AllPods"

    AllPods will create accounts for all pods belong to the component.


    AllPods will create accounts for all pods belong to the component.

    +

    "AnyPods"

    AnyPods will only create accounts on one pod.


    AnyPods will only create accounts on one pod.

    +

    ProvisionSecretRef @@ -12089,7 +12787,7 @@ ProvisionSecretRef (Appears on:ProvisionPolicy, SystemAccount)

    -

    ProvisionSecretRef defines the information of secret referred to.


    +

    ProvisionSecretRef defines the information of secret referred to.

    @@ -12107,7 +12805,7 @@ string @@ -12118,7 +12816,7 @@ string @@ -12129,7 +12827,7 @@ string (Appears on:ProvisionPolicy)

    -

    ProvisionStatements defines the statements used to create accounts.


    +

    ProvisionStatements defines the statements used to create accounts.

    -

    name refers to the name of the secret.


    +

    name refers to the name of the secret.

    -

    namespace refers to the namespace of the secret.


    +

    namespace refers to the namespace of the secret.

    @@ -12147,7 +12845,7 @@ string @@ -12159,7 +12857,7 @@ string @@ -12171,7 +12869,10 @@ string @@ -12195,48 +12896,61 @@ string @@ -12265,7 +12979,7 @@ string @@ -12277,7 +12991,7 @@ string @@ -12289,7 +13003,7 @@ string @@ -12301,7 +13015,7 @@ int32 @@ -12313,7 +13027,7 @@ int32 @@ -12325,7 +13039,7 @@ string @@ -12336,7 +13050,7 @@ string (Appears on:OpsRequestSpec)

    -

    Reconfigure defines the variables that need to input when updating configuration.


    +

    Reconfigure defines the variables that need to input when updating configuration.

    -

    creation specifies statement how to create this account with required privileges.


    +

    creation specifies statement how to create this account with required privileges.

    (Optional) -

    update specifies statement how to update account’s password.


    +

    update specifies statement how to update account’s password.

    (Optional) -

    deletion specifies statement how to delete this account.
    Used in combination with CreateionStatement to delete the account before create it.
    For instance, one usually uses drop user if exists statement followed by create user statement to create an account.
    Deprecated: this field is deprecated, use update instead.


    +

    deletion specifies statement how to delete this account. +Used in combination with CreateionStatement to delete the account before create it. +For instance, one usually uses drop user if exists statement followed by create user statement to create an account. +Deprecated: this field is deprecated, use update instead.

    roles
    -[]github.com/apecloud/kubeblocks/apis/workloads/v1alpha1.ReplicaRole + +[]ReplicaRole +
    (Optional) -

    Roles, a list of roles defined in the system.


    +

    Roles, a list of roles defined in the system.

    roleProbe
    -github.com/apecloud/kubeblocks/apis/workloads/v1alpha1.RoleProbe + +RoleProbe +
    (Optional) -

    RoleProbe provides method to probe role.


    +

    RoleProbe provides method to probe role.

    membershipReconfiguration
    -github.com/apecloud/kubeblocks/apis/workloads/v1alpha1.MembershipReconfiguration + +MembershipReconfiguration +
    (Optional) -

    MembershipReconfiguration provides actions to do membership dynamic reconfiguration.


    +

    MembershipReconfiguration provides actions to do membership dynamic reconfiguration.

    memberUpdateStrategy
    -github.com/apecloud/kubeblocks/apis/workloads/v1alpha1.MemberUpdateStrategy + +MemberUpdateStrategy +
    (Optional) -

    MemberUpdateStrategy, Members(Pods) update strategy.
    serial: update Members one by one that guarantee minimum component unavailable time.
    Learner -> Follower(with AccessMode=none) -> Follower(with AccessMode=readonly) -> Follower(with AccessMode=readWrite) -> Leader
    bestEffortParallel: update Members in parallel that guarantee minimum component un-writable time.
    Learner, Follower(minority) in parallel -> Follower(majority) -> Leader, keep majority online all the time.
    parallel: force parallel


    +

    MemberUpdateStrategy, Members(Pods) update strategy. +serial: update Members one by one that guarantee minimum component unavailable time. +Learner -> Follower(with AccessMode=none) -> Follower(with AccessMode=readonly) -> Follower(with AccessMode=readWrite) -> Leader +bestEffortParallel: update Members in parallel that guarantee minimum component un-writable time. +Learner, Follower(minority) in parallel -> Follower(majority) -> Leader, keep majority online all the time. +parallel: force parallel

    (Optional) -

    policy is the policy of the latest execution.


    +

    policy is the policy of the latest execution.

    (Optional) -

    execResult is the result of the latest execution.


    +

    execResult is the result of the latest execution.

    (Optional) -

    currentRevision is the current revision of configurationItem.


    +

    currentRevision is the current revision of configurationItem.

    (Optional) -

    succeedCount is the number of pods for which configuration changes were successfully executed.


    +

    succeedCount is the number of pods for which configuration changes were successfully executed.

    (Optional) -

    expectedCount is the number of pods that need to be executed for configuration changes.


    +

    expectedCount is the number of pods that need to be executed for configuration changes.

    (Optional) -

    errMessage is the error message when the configuration change execution fails.


    +

    errMessage is the error message when the configuration change execution fails.

    @@ -12371,7 +13085,7 @@ ComponentOps @@ -12402,7 +13116,7 @@ ComponentOps @@ -12415,7 +13129,7 @@ ComponentOps @@ -12444,7 +13158,7 @@ string @@ -12456,7 +13170,7 @@ string @@ -12467,7 +13181,8 @@ string (Appears on:ConfigConstraintSpec)

    -

    ReloadOptions defines reload options
    Only one of its members may be specified.


    +

    ReloadOptions defines reload options +Only one of its members may be specified.

    -

    configurations defines which components perform the operation.


    +

    configurations defines which components perform the operation.

    (Optional) -

    conditions describes reconfiguring detail status.


    +

    conditions describes reconfiguring detail status.

    -

    configurationStatus describes the status of the component reconfiguring.


    +

    configurationStatus describes the status of the component reconfiguring.

    (Optional) -

    specified the name


    +

    specified the name

    (Optional) -

    specified the namespace


    +

    specified the namespace

    @@ -12488,7 +13203,7 @@ UnixSignalTrigger @@ -12502,7 +13217,7 @@ ShellTrigger @@ -12516,7 +13231,7 @@ TPLScriptTrigger @@ -12530,7 +13245,7 @@ AutoTrigger @@ -12541,7 +13256,7 @@ AutoTrigger (Appears on:ComponentDefinitionSpec)

    -

    ReplicaRole represents a role that can be assumed by a component instance.


    +

    ReplicaRole represents a role that can be assumed by a component instance.

    (Optional) -

    unixSignalTrigger used to reload by sending a signal.


    +

    unixSignalTrigger used to reload by sending a signal.

    (Optional) -

    shellTrigger performs the reload command.


    +

    shellTrigger performs the reload command.

    (Optional) -

    goTplTrigger performs the reload command.


    +

    goTplTrigger performs the reload command.

    (Optional) -

    autoTrigger performs the reload command.


    +

    autoTrigger performs the reload command.

    @@ -12559,7 +13274,8 @@ string @@ -12571,7 +13287,8 @@ bool @@ -12583,7 +13300,8 @@ bool @@ -12595,7 +13313,8 @@ bool @@ -12606,7 +13325,7 @@ bool (Appears on:ComponentDefinitionSpec)

    -

    ReplicasLimit defines the limit of valid replicas supported.


    +

    ReplicasLimit defines the limit of valid replicas supported.

    -

    Name of the role. It will apply to “apps.kubeblocks.io/role” object label value.
    Cannot be updated.


    +

    Name of the role. It will apply to “apps.kubeblocks.io/role” object label value. +Cannot be updated.

    (Optional) -

    Serviceable indicates whether a replica with this role can provide services.
    Cannot be updated.


    +

    Serviceable indicates whether a replica with this role can provide services. +Cannot be updated.

    (Optional) -

    Writable indicates whether a replica with this role is allowed to write data.
    Cannot be updated.


    +

    Writable indicates whether a replica with this role is allowed to write data. +Cannot be updated.

    (Optional) -

    Votable indicates whether a replica with this role is allowed to vote.
    Cannot be updated.


    +

    Votable indicates whether a replica with this role is allowed to vote. +Cannot be updated.

    @@ -12624,7 +13343,7 @@ int32 @@ -12635,7 +13354,7 @@ int32 @@ -12695,7 +13414,7 @@ string @@ -12708,7 +13427,7 @@ CPUConstraint @@ -12721,7 +13440,7 @@ MemoryConstraint @@ -12735,7 +13454,7 @@ StorageConstraint @@ -12763,7 +13482,7 @@ string @@ -12774,7 +13493,7 @@ string @@ -12786,7 +13505,7 @@ string @@ -12798,7 +13517,7 @@ string @@ -12829,7 +13548,7 @@ string @@ -12843,7 +13562,7 @@ PointInTimeRefSpec @@ -12871,7 +13590,7 @@ string @@ -12882,7 +13601,7 @@ bool @@ -12893,7 +13612,7 @@ string @@ -12904,7 +13623,7 @@ string @@ -12933,7 +13652,7 @@ int @@ -12945,7 +13664,7 @@ time.Duration @@ -12956,7 +13675,7 @@ time.Duration (Appears on:ComponentDefinitionSpec)

    -

    RoleArbitrator defines how to arbitrate the role of replicas.


    +

    RoleArbitrator defines how to arbitrate the role of replicas.

    -

    The minimum limit of replicas.


    +

    The minimum limit of replicas.

    -

    The maximum limit of replicas.


    +

    The maximum limit of replicas.

    -

    The name of the constraint.


    +

    The name of the constraint.

    -

    The constraint for vcpu cores.


    +

    The constraint for vcpu cores.

    -

    The constraint for memory size.


    +

    The constraint for memory size.

    (Optional) -

    The constraint for storage size.


    +

    The constraint for storage size.

    -

    name is the name of the referenced the Configmap/Secret object.


    +

    name is the name of the referenced the Configmap/Secret object.

    -

    mountPath is the path at which to mount the volume.


    +

    mountPath is the path at which to mount the volume.

    (Optional) -

    subPath is a relative file path within the volume to mount.


    +

    subPath is a relative file path within the volume to mount.

    (Optional) -

    asVolumeFrom defines the list of containers where volumeMounts will be injected into.


    +

    asVolumeFrom defines the list of containers where volumeMounts will be injected into.

    (Optional) -

    use the backup name and component name for restore, support for multiple components’ recovery.


    +

    use the backup name and component name for restore, support for multiple components’ recovery.

    (Optional) -

    specified the point in time to recovery


    +

    specified the point in time to recovery

    -

    backupName is the name of the backup.


    +

    backupName is the name of the backup.

    -

    effectiveCommonComponentDef describes this backup will be restored for all components which refer to common ComponentDefinition.


    +

    effectiveCommonComponentDef describes this backup will be restored for all components which refer to common ComponentDefinition.

    -

    restoreTime point in time to restore


    +

    restoreTime point in time to restore

    -

    the volume claim restore policy, support values: [Serial, Parallel]


    +

    the volume claim restore policy, support values: [Serial, Parallel]

    (Optional) -

    MaxRetries specifies the maximum number of times the action should be retried.


    +

    MaxRetries specifies the maximum number of times the action should be retried.

    (Optional) -

    RetryInterval specifies the interval between retry attempts.


    +

    RetryInterval specifies the interval between retry attempts.

    @@ -13010,7 +13729,8 @@ int32 @@ -13022,7 +13742,9 @@ int32 @@ -13034,7 +13756,8 @@ int32 @@ -13046,7 +13769,8 @@ int32 @@ -13058,7 +13782,8 @@ int32 @@ -13070,7 +13795,16 @@ int64 @@ -13098,7 +13832,13 @@ string @@ -13109,7 +13849,7 @@ string @@ -13138,7 +13878,7 @@ bool @@ -13149,7 +13889,7 @@ string @@ -13160,7 +13900,8 @@ string @@ -13172,7 +13913,18 @@ github.com/apecloud/kubeblocks/apis/dataprotection/v1alpha1.RetentionPeriod @@ -13200,7 +13952,7 @@ string @@ -13212,7 +13964,8 @@ string @@ -13223,7 +13976,7 @@ string (Appears on:ScriptSpec)

    -

    ScriptFrom defines the script to be executed from configMap or secret.


    +

    ScriptFrom defines the script to be executed from configMap or secret.

    (Optional) -

    Number of seconds after the container has started before liveness probes are initiated.
    More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes


    +

    Number of seconds after the container has started before liveness probes are initiated. +More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes

    (Optional) -

    Number of seconds after which the probe times out.
    Defaults to 1 second. Minimum value is 1.
    More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes


    +

    Number of seconds after which the probe times out. +Defaults to 1 second. Minimum value is 1. +More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes

    (Optional) -

    How often (in seconds) to perform the probe.
    Default to 10 seconds. Minimum value is 1.


    +

    How often (in seconds) to perform the probe. +Default to 10 seconds. Minimum value is 1.

    (Optional) -

    Minimum consecutive successes for the probe to be considered successful after having failed.
    Defaults to 1. Must be 1 for liveness and startup. Minimum value is 1.


    +

    Minimum consecutive successes for the probe to be considered successful after having failed. +Defaults to 1. Must be 1 for liveness and startup. Minimum value is 1.

    (Optional) -

    Minimum consecutive failures for the probe to be considered failed after having succeeded.
    Defaults to 3. Minimum value is 1.


    +

    Minimum consecutive failures for the probe to be considered failed after having succeeded. +Defaults to 3. Minimum value is 1.

    (Optional) -

    Optional duration in seconds the pod needs to terminate gracefully upon probe failure.
    The grace period is the duration in seconds after the processes running in the pod are sent
    a termination signal and the time when the processes are forcibly halted with a kill signal.
    Set this value longer than the expected cleanup time for your process.
    If this value is nil, the pod’s terminationGracePeriodSeconds will be used. Otherwise, this
    value overrides the value provided by the pod spec.
    Value must be non-negative integer. The value zero indicates stop immediately via
    the kill signal (no opportunity to shut down).
    This is a beta field and requires enabling ProbeTerminationGracePeriod feature gate.
    Minimum value is 1. spec.terminationGracePeriodSeconds is used if unset.


    +

    Optional duration in seconds the pod needs to terminate gracefully upon probe failure. +The grace period is the duration in seconds after the processes running in the pod are sent +a termination signal and the time when the processes are forcibly halted with a kill signal. +Set this value longer than the expected cleanup time for your process. +If this value is nil, the pod’s terminationGracePeriodSeconds will be used. Otherwise, this +value overrides the value provided by the pod spec. +Value must be non-negative integer. The value zero indicates stop immediately via +the kill signal (no opportunity to shut down). +This is a beta field and requires enabling ProbeTerminationGracePeriod feature gate. +Minimum value is 1. spec.terminationGracePeriodSeconds is used if unset.

    -

    expression declares how the operation can be executed using go template expression.
    it should return “true” or “false”, built-in objects:
    - “params” are input parameters.
    - “cluster” is referenced cluster object.
    - “component” is referenced the component Object.


    +

    expression declares how the operation can be executed using go template expression. +it should return “true” or “false”, built-in objects:

    +
      +
    • “params” are input parameters.
    • +
    • “cluster” is referenced cluster object.
    • +
    • “component” is referenced the component Object.
    • +
    -

    report the message if the rule is not matched.


    +

    report the message if the rule is not matched.

    (Optional) -

    enabled specifies whether the backup schedule is enabled or not.


    +

    enabled specifies whether the backup schedule is enabled or not.

    -

    backupMethod specifies the backup method name that is defined in backupPolicy.


    +

    backupMethod specifies the backup method name that is defined in backupPolicy.

    -

    the cron expression for schedule, the timezone is in UTC.
    see https://en.wikipedia.org/wiki/Cron.


    +

    the cron expression for schedule, the timezone is in UTC. +see https://en.wikipedia.org/wiki/Cron.

    (Optional) -

    retentionPeriod determines a duration up to which the backup should be kept.
    controller will remove all backups that are older than the RetentionPeriod.
    For example, RetentionPeriod of 30d will keep only the backups of last 30 days.
    Sample duration format:
    - years: 2y
    - months: 6mo
    - days: 30d
    - hours: 12h
    - minutes: 30m
    You can also combine the above durations. For example: 30d12h30m


    +

    retentionPeriod determines a duration up to which the backup should be kept. +controller will remove all backups that are older than the RetentionPeriod. +For example, RetentionPeriod of 30d will keep only the backups of last 30 days. +Sample duration format:

    +
      +
    • years: 2y
    • +
    • months: 6mo
    • +
    • days: 30d
    • +
    • hours: 12h
    • +
    • minutes: 30m +You can also combine the above durations. For example: 30d12h30m
    • +
    -

    scriptConfigMapRef used to execute for reload.


    +

    scriptConfigMapRef used to execute for reload.

    (Optional) -

    Specify the namespace of the referenced the tpl script ConfigMap object.
    An empty namespace is equivalent to the “default” namespace.


    +

    Specify the namespace of the referenced the tpl script ConfigMap object. +An empty namespace is equivalent to the “default” namespace.

    @@ -13244,7 +13997,7 @@ string @@ -13258,7 +14011,7 @@ string @@ -13269,7 +14022,7 @@ string (Appears on:ScriptSpec)

    -

    ScriptSecret defines the secret to be used to execute the script.


    +

    ScriptSecret defines the secret to be used to execute the script.

    (Optional) -

    configMapRef defines the configMap to be executed.


    +

    configMapRef defines the configMap to be executed.

    (Optional) -

    secretRef defines the secret to be executed.


    +

    secretRef defines the secret to be executed.

    @@ -13287,7 +14040,7 @@ string @@ -13299,7 +14052,7 @@ string @@ -13311,7 +14064,7 @@ string @@ -13322,7 +14075,9 @@ string (Appears on:OpsRequestSpec)

    -

    ScriptSpec defines the script to be executed. It is not a general purpose script executor.
    It is designed to execute the script to perform some specific operations, such as create database, create user, etc.
    It is applicable for engines, such as MySQL, PostgreSQL, Redis, MongoDB, etc.


    +

    ScriptSpec defines the script to be executed. It is not a general purpose script executor. +It is designed to execute the script to perform some specific operations, such as create database, create user, etc. +It is applicable for engines, such as MySQL, PostgreSQL, Redis, MongoDB, etc.

    -

    name is the name of the secret.


    +

    name is the name of the secret.

    (Optional) -

    usernameKey field is used to specify the username of the secret.


    +

    usernameKey field is used to specify the username of the secret.

    (Optional) -

    passwordKey field is used to specify the password of the secret.


    +

    passwordKey field is used to specify the password of the secret.

    @@ -13356,7 +14111,7 @@ string @@ -13370,7 +14125,8 @@ ScriptSecret @@ -13382,7 +14138,7 @@ ScriptSecret @@ -13396,7 +14152,7 @@ ScriptFrom @@ -13410,7 +14166,10 @@ Kubernetes meta/v1.LabelSelector @@ -13438,7 +14197,7 @@ string @@ -13483,7 +14242,7 @@ Kubernetes core/v1.SecretVolumeSource @@ -13511,7 +14270,10 @@ string @@ -13523,7 +14285,12 @@ string @@ -13535,7 +14302,8 @@ map[string]string @@ -13549,7 +14317,8 @@ Kubernetes core/v1.ServiceSpec @@ -13819,7 +14734,7 @@ string (Appears on:ServiceDescriptor)

    -

    ServiceDescriptorSpec defines the desired state of ServiceDescriptor


    +

    ServiceDescriptorSpec defines the desired state of ServiceDescriptor

    (Optional) -

    exec command with image, by default use the image of kubeblocks-datascript.


    +

    exec command with image, by default use the image of kubeblocks-datascript.

    (Optional) -

    secret defines the secret to be used to execute the script.
    If not specified, the default cluster root credential secret will be used.


    +

    secret defines the secret to be used to execute the script. +If not specified, the default cluster root credential secret will be used.

    (Optional) -

    script defines the script to be executed.


    +

    script defines the script to be executed.

    (Optional) -

    scriptFrom defines the script to be executed from configMap or secret.


    +

    scriptFrom defines the script to be executed from configMap or secret.

    (Optional) -

    KubeBlocks, by default, will execute the script on the primary pod, with role=leader.
    There are some exceptions, such as Redis, which does not synchronize accounts info between primary and secondary.
    In this case, we need to execute the script on all pods, matching the selector.
    selector indicates the components on which the script is executed.


    +

    KubeBlocks, by default, will execute the script on the primary pod, with role=leader. +There are some exceptions, such as Redis, which does not synchronize accounts info between primary and secondary. +In this case, we need to execute the script on all pods, matching the selector. +selector indicates the components on which the script is executed.

    -

    ScriptSpec name of the referent, refer to componentDefs[x].scriptSpecs[y].Name.


    +

    ScriptSpec name of the referent, refer to componentDefs[x].scriptSpecs[y].Name.

    -

    secret defines the secret volume source.


    +

    secret defines the secret volume source.

    -

    Name defines the name of the service.
    otherwise, it indicates the name of the service.
    Others can refer to this service by its name. (e.g., connection credential)
    Cannot be updated.


    +

    Name defines the name of the service. +otherwise, it indicates the name of the service. +Others can refer to this service by its name. (e.g., connection credential) +Cannot be updated.

    (Optional) -

    ServiceName defines the name of the underlying service object.
    If not specified, the default service name with different patterns will be used:
    - CLUSTER_NAME: for cluster-level services
    - CLUSTER_NAME-COMPONENT_NAME: for component-level services
    Only one default service name is allowed.
    Cannot be updated.


    +

    ServiceName defines the name of the underlying service object. +If not specified, the default service name with different patterns will be used: +- CLUSTER_NAME: for cluster-level services +- CLUSTER_NAME-COMPONENT_NAME: for component-level services +Only one default service name is allowed. +Cannot be updated.

    (Optional) -

    If ServiceType is LoadBalancer, cloud provider related parameters can be put here
    More info: https://kubernetes.io/docs/concepts/services-networking/service/#loadbalancer.


    +

    If ServiceType is LoadBalancer, cloud provider related parameters can be put here +More info: https://kubernetes.io/docs/concepts/services-networking/service/#loadbalancer.

    (Optional) -

    Spec defines the behavior of a service.
    https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status


    +

    Spec defines the behavior of a service. +https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status



    @@ -13563,7 +14332,8 @@ Kubernetes core/v1.ServiceSpec @@ -13575,7 +14345,12 @@ map[string]string @@ -13587,7 +14362,21 @@ string @@ -13599,7 +14388,28 @@ string @@ -13613,7 +14423,22 @@ Kubernetes core/v1.ServiceType @@ -13625,7 +14450,11 @@ Kubernetes core/v1.ServiceType @@ -13639,7 +14468,11 @@ Kubernetes core/v1.ServiceAffinity @@ -13651,7 +14484,13 @@ string @@ -13663,7 +14502,10 @@ string @@ -13675,7 +14517,10 @@ string @@ -13689,7 +14534,19 @@ Kubernetes core/v1.ServiceExternalTrafficPolicy @@ -13701,7 +14558,16 @@ int32 @@ -13713,7 +14579,14 @@ bool @@ -13727,7 +14600,7 @@ Kubernetes core/v1.SessionAffinityConfig @@ -13741,7 +14614,21 @@ Kubernetes core/v1.SessionAffinityConfig @@ -13755,7 +14642,14 @@ Kubernetes core/v1.IPFamilyPolicy @@ -13767,7 +14661,13 @@ bool @@ -13779,7 +14679,16 @@ string @@ -13793,7 +14702,12 @@ Kubernetes core/v1.ServiceInternalTrafficPolicy
    -

    The list of ports that are exposed by this service.
    More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies


    +

    The list of ports that are exposed by this service. +More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies

    (Optional) -

    Route service traffic to pods with label keys and values matching this
    selector. If empty or not present, the service is assumed to have an
    external process managing its endpoints, which Kubernetes will not
    modify. Only applies to types ClusterIP, NodePort, and LoadBalancer.
    Ignored if type is ExternalName.
    More info: https://kubernetes.io/docs/concepts/services-networking/service/


    +

    Route service traffic to pods with label keys and values matching this +selector. If empty or not present, the service is assumed to have an +external process managing its endpoints, which Kubernetes will not +modify. Only applies to types ClusterIP, NodePort, and LoadBalancer. +Ignored if type is ExternalName. +More info: https://kubernetes.io/docs/concepts/services-networking/service/

    (Optional) -

    clusterIP is the IP address of the service and is usually assigned
    randomly. If an address is specified manually, is in-range (as per
    system configuration), and is not in use, it will be allocated to the
    service; otherwise creation of the service will fail. This field may not
    be changed through updates unless the type field is also being changed
    to ExternalName (which requires this field to be blank) or the type
    field is being changed from ExternalName (in which case this field may
    optionally be specified, as describe above). Valid values are “None”,
    empty string (“”), or a valid IP address. Setting this to “None” makes a
    “headless service” (no virtual IP), which is useful when direct endpoint
    connections are preferred and proxying is not required. Only applies to
    types ClusterIP, NodePort, and LoadBalancer. If this field is specified
    when creating a Service of type ExternalName, creation will fail. This
    field will be wiped when updating a Service to type ExternalName.
    More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies


    +

    clusterIP is the IP address of the service and is usually assigned +randomly. If an address is specified manually, is in-range (as per +system configuration), and is not in use, it will be allocated to the +service; otherwise creation of the service will fail. This field may not +be changed through updates unless the type field is also being changed +to ExternalName (which requires this field to be blank) or the type +field is being changed from ExternalName (in which case this field may +optionally be specified, as describe above). Valid values are “None”, +empty string (“”), or a valid IP address. Setting this to “None” makes a +“headless service” (no virtual IP), which is useful when direct endpoint +connections are preferred and proxying is not required. Only applies to +types ClusterIP, NodePort, and LoadBalancer. If this field is specified +when creating a Service of type ExternalName, creation will fail. This +field will be wiped when updating a Service to type ExternalName. +More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies

    (Optional) -

    ClusterIPs is a list of IP addresses assigned to this service, and are
    usually assigned randomly. If an address is specified manually, is
    in-range (as per system configuration), and is not in use, it will be
    allocated to the service; otherwise creation of the service will fail.
    This field may not be changed through updates unless the type field is
    also being changed to ExternalName (which requires this field to be
    empty) or the type field is being changed from ExternalName (in which
    case this field may optionally be specified, as describe above). Valid
    values are “None”, empty string (“”), or a valid IP address. Setting
    this to “None” makes a “headless service” (no virtual IP), which is
    useful when direct endpoint connections are preferred and proxying is
    not required. Only applies to types ClusterIP, NodePort, and
    LoadBalancer. If this field is specified when creating a Service of type
    ExternalName, creation will fail. This field will be wiped when updating
    a Service to type ExternalName. If this field is not specified, it will
    be initialized from the clusterIP field. If this field is specified,
    clients must ensure that clusterIPs[0] and clusterIP have the same
    value.



    This field may hold a maximum of two entries (dual-stack IPs, in either order).
    These IPs must correspond to the values of the ipFamilies field. Both
    clusterIPs and ipFamilies are governed by the ipFamilyPolicy field.
    More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies


    +

    ClusterIPs is a list of IP addresses assigned to this service, and are +usually assigned randomly. If an address is specified manually, is +in-range (as per system configuration), and is not in use, it will be +allocated to the service; otherwise creation of the service will fail. +This field may not be changed through updates unless the type field is +also being changed to ExternalName (which requires this field to be +empty) or the type field is being changed from ExternalName (in which +case this field may optionally be specified, as describe above). Valid +values are “None”, empty string (“”), or a valid IP address. Setting +this to “None” makes a “headless service” (no virtual IP), which is +useful when direct endpoint connections are preferred and proxying is +not required. Only applies to types ClusterIP, NodePort, and +LoadBalancer. If this field is specified when creating a Service of type +ExternalName, creation will fail. This field will be wiped when updating +a Service to type ExternalName. If this field is not specified, it will +be initialized from the clusterIP field. If this field is specified, +clients must ensure that clusterIPs[0] and clusterIP have the same +value.

    +

    This field may hold a maximum of two entries (dual-stack IPs, in either order). +These IPs must correspond to the values of the ipFamilies field. Both +clusterIPs and ipFamilies are governed by the ipFamilyPolicy field. +More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies

    (Optional) -

    type determines how the Service is exposed. Defaults to ClusterIP. Valid
    options are ExternalName, ClusterIP, NodePort, and LoadBalancer.
    “ClusterIP” allocates a cluster-internal IP address for load-balancing
    to endpoints. Endpoints are determined by the selector or if that is not
    specified, by manual construction of an Endpoints object or
    EndpointSlice objects. If clusterIP is “None”, no virtual IP is
    allocated and the endpoints are published as a set of endpoints rather
    than a virtual IP.
    “NodePort” builds on ClusterIP and allocates a port on every node which
    routes to the same endpoints as the clusterIP.
    “LoadBalancer” builds on NodePort and creates an external load-balancer
    (if supported in the current cloud) which routes to the same endpoints
    as the clusterIP.
    “ExternalName” aliases this service to the specified externalName.
    Several other fields do not apply to ExternalName services.
    More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types


    +

    type determines how the Service is exposed. Defaults to ClusterIP. Valid +options are ExternalName, ClusterIP, NodePort, and LoadBalancer. +“ClusterIP” allocates a cluster-internal IP address for load-balancing +to endpoints. Endpoints are determined by the selector or if that is not +specified, by manual construction of an Endpoints object or +EndpointSlice objects. If clusterIP is “None”, no virtual IP is +allocated and the endpoints are published as a set of endpoints rather +than a virtual IP. +“NodePort” builds on ClusterIP and allocates a port on every node which +routes to the same endpoints as the clusterIP. +“LoadBalancer” builds on NodePort and creates an external load-balancer +(if supported in the current cloud) which routes to the same endpoints +as the clusterIP. +“ExternalName” aliases this service to the specified externalName. +Several other fields do not apply to ExternalName services. +More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types

    (Optional) -

    externalIPs is a list of IP addresses for which nodes in the cluster
    will also accept traffic for this service. These IPs are not managed by
    Kubernetes. The user is responsible for ensuring that traffic arrives
    at a node with this IP. A common example is external load-balancers
    that are not part of the Kubernetes system.


    +

    externalIPs is a list of IP addresses for which nodes in the cluster +will also accept traffic for this service. These IPs are not managed by +Kubernetes. The user is responsible for ensuring that traffic arrives +at a node with this IP. A common example is external load-balancers +that are not part of the Kubernetes system.

    (Optional) -

    Supports “ClientIP” and “None”. Used to maintain session affinity.
    Enable client IP based session affinity.
    Must be ClientIP or None.
    Defaults to None.
    More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies


    +

    Supports “ClientIP” and “None”. Used to maintain session affinity. +Enable client IP based session affinity. +Must be ClientIP or None. +Defaults to None. +More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies

    (Optional) -

    Only applies to Service Type: LoadBalancer.
    This feature depends on whether the underlying cloud-provider supports specifying
    the loadBalancerIP when a load balancer is created.
    This field will be ignored if the cloud-provider does not support the feature.
    Deprecated: This field was under-specified and its meaning varies across implementations.
    Using it is non-portable and it may not support dual-stack.
    Users are encouraged to use implementation-specific annotations when available.


    +

    Only applies to Service Type: LoadBalancer. +This feature depends on whether the underlying cloud-provider supports specifying +the loadBalancerIP when a load balancer is created. +This field will be ignored if the cloud-provider does not support the feature. +Deprecated: This field was under-specified and its meaning varies across implementations. +Using it is non-portable and it may not support dual-stack. +Users are encouraged to use implementation-specific annotations when available.

    (Optional) -

    If specified and supported by the platform, this will restrict traffic through the cloud-provider
    load-balancer will be restricted to the specified client IPs. This field will be ignored if the
    cloud-provider does not support the feature.”
    More info: https://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/


    +

    If specified and supported by the platform, this will restrict traffic through the cloud-provider +load-balancer will be restricted to the specified client IPs. This field will be ignored if the +cloud-provider does not support the feature.” +More info: https://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/

    (Optional) -

    externalName is the external reference that discovery mechanisms will
    return as an alias for this service (e.g. a DNS CNAME record). No
    proxying will be involved. Must be a lowercase RFC-1123 hostname
    (https://tools.ietf.org/html/rfc1123) and requires type to be “ExternalName”.


    +

    externalName is the external reference that discovery mechanisms will +return as an alias for this service (e.g. a DNS CNAME record). No +proxying will be involved. Must be a lowercase RFC-1123 hostname +(https://tools.ietf.org/html/rfc1123) and requires type to be “ExternalName”.

    (Optional) -

    externalTrafficPolicy describes how nodes distribute service traffic they
    receive on one of the Service’s “externally-facing” addresses (NodePorts,
    ExternalIPs, and LoadBalancer IPs). If set to “Local”, the proxy will configure
    the service in a way that assumes that external load balancers will take care
    of balancing the service traffic between nodes, and so each node will deliver
    traffic only to the node-local endpoints of the service, without masquerading
    the client source IP. (Traffic mistakenly sent to a node with no endpoints will
    be dropped.) The default value, “Cluster”, uses the standard behavior of
    routing to all endpoints evenly (possibly modified by topology and other
    features). Note that traffic sent to an External IP or LoadBalancer IP from
    within the cluster will always get “Cluster” semantics, but clients sending to
    a NodePort from within the cluster may need to take traffic policy into account
    when picking a node.


    +

    externalTrafficPolicy describes how nodes distribute service traffic they +receive on one of the Service’s “externally-facing” addresses (NodePorts, +ExternalIPs, and LoadBalancer IPs). If set to “Local”, the proxy will configure +the service in a way that assumes that external load balancers will take care +of balancing the service traffic between nodes, and so each node will deliver +traffic only to the node-local endpoints of the service, without masquerading +the client source IP. (Traffic mistakenly sent to a node with no endpoints will +be dropped.) The default value, “Cluster”, uses the standard behavior of +routing to all endpoints evenly (possibly modified by topology and other +features). Note that traffic sent to an External IP or LoadBalancer IP from +within the cluster will always get “Cluster” semantics, but clients sending to +a NodePort from within the cluster may need to take traffic policy into account +when picking a node.

    (Optional) -

    healthCheckNodePort specifies the healthcheck nodePort for the service.
    This only applies when type is set to LoadBalancer and
    externalTrafficPolicy is set to Local. If a value is specified, is
    in-range, and is not in use, it will be used. If not specified, a value
    will be automatically allocated. External systems (e.g. load-balancers)
    can use this port to determine if a given node holds endpoints for this
    service or not. If this field is specified when creating a Service
    which does not need it, creation will fail. This field will be wiped
    when updating a Service to no longer need it (e.g. changing type).
    This field cannot be updated once set.


    +

    healthCheckNodePort specifies the healthcheck nodePort for the service. +This only applies when type is set to LoadBalancer and +externalTrafficPolicy is set to Local. If a value is specified, is +in-range, and is not in use, it will be used. If not specified, a value +will be automatically allocated. External systems (e.g. load-balancers) +can use this port to determine if a given node holds endpoints for this +service or not. If this field is specified when creating a Service +which does not need it, creation will fail. This field will be wiped +when updating a Service to no longer need it (e.g. changing type). +This field cannot be updated once set.

    (Optional) -

    publishNotReadyAddresses indicates that any agent which deals with endpoints for this
    Service should disregard any indications of ready/not-ready.
    The primary use case for setting this field is for a StatefulSet’s Headless Service to
    propagate SRV DNS records for its Pods for the purpose of peer discovery.
    The Kubernetes controllers that generate Endpoints and EndpointSlice resources for
    Services interpret this to mean that all endpoints are considered “ready” even if the
    Pods themselves are not. Agents which consume only Kubernetes generated endpoints
    through the Endpoints or EndpointSlice resources can safely assume this behavior.


    +

    publishNotReadyAddresses indicates that any agent which deals with endpoints for this +Service should disregard any indications of ready/not-ready. +The primary use case for setting this field is for a StatefulSet’s Headless Service to +propagate SRV DNS records for its Pods for the purpose of peer discovery. +The Kubernetes controllers that generate Endpoints and EndpointSlice resources for +Services interpret this to mean that all endpoints are considered “ready” even if the +Pods themselves are not. Agents which consume only Kubernetes generated endpoints +through the Endpoints or EndpointSlice resources can safely assume this behavior.

    (Optional) -

    sessionAffinityConfig contains the configurations of session affinity.


    +

    sessionAffinityConfig contains the configurations of session affinity.

    (Optional) -

    IPFamilies is a list of IP families (e.g. IPv4, IPv6) assigned to this
    service. This field is usually assigned automatically based on cluster
    configuration and the ipFamilyPolicy field. If this field is specified
    manually, the requested family is available in the cluster,
    and ipFamilyPolicy allows it, it will be used; otherwise creation of
    the service will fail. This field is conditionally mutable: it allows
    for adding or removing a secondary IP family, but it does not allow
    changing the primary IP family of the Service. Valid values are “IPv4”
    and “IPv6”. This field only applies to Services of types ClusterIP,
    NodePort, and LoadBalancer, and does apply to “headless” services.
    This field will be wiped when updating a Service to type ExternalName.



    This field may hold a maximum of two entries (dual-stack families, in
    either order). These families must correspond to the values of the
    clusterIPs field, if specified. Both clusterIPs and ipFamilies are
    governed by the ipFamilyPolicy field.


    +

    IPFamilies is a list of IP families (e.g. IPv4, IPv6) assigned to this +service. This field is usually assigned automatically based on cluster +configuration and the ipFamilyPolicy field. If this field is specified +manually, the requested family is available in the cluster, +and ipFamilyPolicy allows it, it will be used; otherwise creation of +the service will fail. This field is conditionally mutable: it allows +for adding or removing a secondary IP family, but it does not allow +changing the primary IP family of the Service. Valid values are “IPv4” +and “IPv6”. This field only applies to Services of types ClusterIP, +NodePort, and LoadBalancer, and does apply to “headless” services. +This field will be wiped when updating a Service to type ExternalName.

    +

    This field may hold a maximum of two entries (dual-stack families, in +either order). These families must correspond to the values of the +clusterIPs field, if specified. Both clusterIPs and ipFamilies are +governed by the ipFamilyPolicy field.

    (Optional) -

    IPFamilyPolicy represents the dual-stack-ness requested or required by
    this Service. If there is no value provided, then this field will be set
    to SingleStack. Services can be “SingleStack” (a single IP family),
    “PreferDualStack” (two IP families on dual-stack configured clusters or
    a single IP family on single-stack clusters), or “RequireDualStack”
    (two IP families on dual-stack configured clusters, otherwise fail). The
    ipFamilies and clusterIPs fields depend on the value of this field. This
    field will be wiped when updating a service to type ExternalName.


    +

    IPFamilyPolicy represents the dual-stack-ness requested or required by +this Service. If there is no value provided, then this field will be set +to SingleStack. Services can be “SingleStack” (a single IP family), +“PreferDualStack” (two IP families on dual-stack configured clusters or +a single IP family on single-stack clusters), or “RequireDualStack” +(two IP families on dual-stack configured clusters, otherwise fail). The +ipFamilies and clusterIPs fields depend on the value of this field. This +field will be wiped when updating a service to type ExternalName.

    (Optional) -

    allocateLoadBalancerNodePorts defines if NodePorts will be automatically
    allocated for services with type LoadBalancer. Default is “true”. It
    may be set to “false” if the cluster load-balancer does not rely on
    NodePorts. If the caller requests specific NodePorts (by specifying a
    value), those requests will be respected, regardless of this field.
    This field may only be set for services with type LoadBalancer and will
    be cleared if the type is changed to any other type.


    +

    allocateLoadBalancerNodePorts defines if NodePorts will be automatically +allocated for services with type LoadBalancer. Default is “true”. It +may be set to “false” if the cluster load-balancer does not rely on +NodePorts. If the caller requests specific NodePorts (by specifying a +value), those requests will be respected, regardless of this field. +This field may only be set for services with type LoadBalancer and will +be cleared if the type is changed to any other type.

    (Optional) -

    loadBalancerClass is the class of the load balancer implementation this Service belongs to.
    If specified, the value of this field must be a label-style identifier, with an optional prefix,
    e.g. “internal-vip” or “example.com/internal-vip”. Unprefixed names are reserved for end-users.
    This field can only be set when the Service type is ‘LoadBalancer’. If not set, the default load
    balancer implementation is used, today this is typically done through the cloud provider integration,
    but should apply for any default implementation. If set, it is assumed that a load balancer
    implementation is watching for Services with a matching class. Any default load balancer
    implementation (e.g. cloud providers) should ignore Services that set this field.
    This field can only be set when creating or updating a Service to type ‘LoadBalancer’.
    Once set, it can not be changed. This field will be wiped when a service is updated to a non ‘LoadBalancer’ type.


    +

    loadBalancerClass is the class of the load balancer implementation this Service belongs to. +If specified, the value of this field must be a label-style identifier, with an optional prefix, +e.g. “internal-vip” or “example.com/internal-vip”. Unprefixed names are reserved for end-users. +This field can only be set when the Service type is ‘LoadBalancer’. If not set, the default load +balancer implementation is used, today this is typically done through the cloud provider integration, +but should apply for any default implementation. If set, it is assumed that a load balancer +implementation is watching for Services with a matching class. Any default load balancer +implementation (e.g. cloud providers) should ignore Services that set this field. +This field can only be set when creating or updating a Service to type ‘LoadBalancer’. +Once set, it can not be changed. This field will be wiped when a service is updated to a non ‘LoadBalancer’ type.

    (Optional) -

    InternalTrafficPolicy describes how nodes distribute service traffic they
    receive on the ClusterIP. If set to “Local”, the proxy will assume that pods
    only want to talk to endpoints of the service on the same node as the pod,
    dropping the traffic if there are no local endpoints. The default value,
    “Cluster”, uses the standard behavior of routing to all endpoints evenly
    (possibly modified by topology and other features).


    +

    InternalTrafficPolicy describes how nodes distribute service traffic they +receive on the ClusterIP. If set to “Local”, the proxy will assume that pods +only want to talk to endpoints of the service on the same node as the pod, +dropping the traffic if there are no local endpoints. The default value, +“Cluster”, uses the standard behavior of routing to all endpoints evenly +(possibly modified by topology and other features).

    @@ -13808,7 +14722,8 @@ string
    (Optional) -

    RoleSelector extends the ServiceSpec.Selector by allowing you to specify defined role as selector for the service.
    if GeneratePodOrdinalService sets to true, RoleSelector will be ignored.


    +

    RoleSelector extends the ServiceSpec.Selector by allowing you to specify defined role as selector for the service. +if GeneratePodOrdinalService sets to true, RoleSelector will be ignored.

    @@ -13837,7 +14752,9 @@ string @@ -13848,7 +14765,7 @@ string @@ -13862,7 +14779,7 @@ CredentialVar @@ -13876,7 +14793,7 @@ ConnectionCredentialAuth @@ -13890,7 +14807,7 @@ CredentialVar @@ -13901,7 +14818,7 @@ CredentialVar (Appears on:ServiceDescriptor)

    -

    ServiceDescriptorStatus defines the observed state of ServiceDescriptor


    +

    ServiceDescriptorStatus defines the observed state of ServiceDescriptor

    -

    service kind, indicating the type or nature of the service. It should be well-known application cluster type, e.g. {mysql, redis, mongodb}.
    The serviceKind is case-insensitive and supports abbreviations for some well-known databases.
    For example, both ‘zk’ and ‘zookeeper’ will be considered as a ZooKeeper cluster, and ‘pg’, ‘postgres’, ‘postgresql’ will all be considered as a PostgreSQL cluster.


    +

    service kind, indicating the type or nature of the service. It should be well-known application cluster type, e.g. {mysql, redis, mongodb}. +The serviceKind is case-insensitive and supports abbreviations for some well-known databases. +For example, both ‘zk’ and ‘zookeeper’ will be considered as a ZooKeeper cluster, and ‘pg’, ‘postgres’, ‘postgresql’ will all be considered as a PostgreSQL cluster.

    -

    The version of the service reference.


    +

    The version of the service reference.

    (Optional) -

    endpoint is the endpoint of the service connection credential.


    +

    endpoint is the endpoint of the service connection credential.

    (Optional) -

    auth is the auth of the service connection credential.


    +

    auth is the auth of the service connection credential.

    (Optional) -

    port is the port of the service connection credential.


    +

    port is the port of the service connection credential.

    @@ -13922,7 +14839,7 @@ Phase @@ -13934,7 +14851,7 @@ string @@ -13946,7 +14863,7 @@ int64 @@ -13974,7 +14891,10 @@ string @@ -13988,7 +14908,8 @@ Kubernetes core/v1.Protocol @@ -14000,7 +14921,12 @@ string @@ -14011,7 +14937,7 @@ int32 @@ -14025,7 +14951,14 @@ Kubernetes api utils intstr.IntOrString @@ -14053,7 +14986,7 @@ string @@ -14065,7 +14998,8 @@ string @@ -14077,7 +15011,11 @@ string @@ -14089,7 +15027,12 @@ string @@ -14117,7 +15060,9 @@ string @@ -14130,7 +15075,12 @@ string @@ -14158,7 +15108,9 @@ string @@ -14169,7 +15121,8 @@ string @@ -14180,7 +15133,7 @@ string (Appears on:VarSource)

    -

    ServiceRefVarSelector selects a var from a ServiceRefDeclaration.


    +

    ServiceRefVarSelector selects a var from a ServiceRefDeclaration.

    (Optional) -

    phase - in list of [Available,Unavailable]


    +

    phase - in list of [Available,Unavailable]

    (Optional) -

    A human-readable message indicating details about why the ServiceConnectionCredential is in this phase.


    +

    A human-readable message indicating details about why the ServiceConnectionCredential is in this phase.

    (Optional) -

    generation number


    +

    generation number

    -

    The name of this port within the service. This must be a DNS_LABEL.
    All ports within a ServiceSpec must have unique names. When considering
    the endpoints for a Service, this must match the ‘name’ field in the
    EndpointPort.


    +

    The name of this port within the service. This must be a DNS_LABEL. +All ports within a ServiceSpec must have unique names. When considering +the endpoints for a Service, this must match the ‘name’ field in the +EndpointPort.

    (Optional) -

    The IP protocol for this port. Supports “TCP”, “UDP”, and “SCTP”.
    Default is TCP.


    +

    The IP protocol for this port. Supports “TCP”, “UDP”, and “SCTP”. +Default is TCP.

    (Optional) -

    The application protocol for this port.
    This field follows standard Kubernetes label syntax.
    Un-prefixed names are reserved for IANA standard service names (as per
    RFC-6335 and https://www.iana.org/assignments/service-names).
    Non-standard protocols should use prefixed names such as
    mycompany.com/my-custom-protocol.


    +

    The application protocol for this port. +This field follows standard Kubernetes label syntax. +Un-prefixed names are reserved for IANA standard service names (as per +RFC-6335 and https://www.iana.org/assignments/service-names). +Non-standard protocols should use prefixed names such as +mycompany.com/my-custom-protocol.

    -

    The port that will be exposed by this service.


    +

    The port that will be exposed by this service.

    (Optional) -

    Number or name of the port to access on the pods targeted by the service.
    Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.
    If this is a string, it will be looked up as a named port in the
    target Pod’s container ports. If this is not specified, the value
    of the ‘port’ field is used (an identity map).
    This field is ignored for services with clusterIP=None, and should be
    omitted or set equal to the ‘port’ field.
    More info: https://kubernetes.io/docs/concepts/services-networking/service/#defining-a-service


    +

    Number or name of the port to access on the pods targeted by the service. +Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. +If this is a string, it will be looked up as a named port in the +target Pod’s container ports. If this is not specified, the value +of the ‘port’ field is used (an identity map). +This field is ignored for services with clusterIP=None, and should be +omitted or set equal to the ‘port’ field. +More info: https://kubernetes.io/docs/concepts/services-networking/service/#defining-a-service

    -

    name of the service reference declaration. references the serviceRefDeclaration name defined in clusterDefinition.componentDefs[].serviceRefDeclarations[].name


    +

    name of the service reference declaration. references the serviceRefDeclaration name defined in clusterDefinition.componentDefs[].serviceRefDeclarations[].name

    (Optional) -

    namespace defines the namespace of the referenced Cluster or the namespace of the referenced ServiceDescriptor object.
    If not set, the referenced Cluster and ServiceDescriptor will be searched in the namespace of the current cluster by default.


    +

    namespace defines the namespace of the referenced Cluster or the namespace of the referenced ServiceDescriptor object. +If not set, the referenced Cluster and ServiceDescriptor will be searched in the namespace of the current cluster by default.

    (Optional) -

    When referencing a service provided by other KubeBlocks cluster, you need to provide the name of the Cluster being referenced.
    By default, when other KubeBlocks Cluster are referenced, the ClusterDefinition.spec.connectionCredential secret corresponding to the referenced Cluster will be used to bind to the current component.
    Currently, if a KubeBlocks cluster is to be referenced, the connection credential secret should include and correspond to the following fields: endpoint, port, username, and password.
    Under this referencing approach, the ServiceKind and ServiceVersion of service reference declaration defined in the ClusterDefinition will not be validated.
    If both Cluster and ServiceDescriptor are specified, the Cluster takes precedence.


    +

    When referencing a service provided by other KubeBlocks cluster, you need to provide the name of the Cluster being referenced. +By default, when other KubeBlocks Cluster are referenced, the ClusterDefinition.spec.connectionCredential secret corresponding to the referenced Cluster will be used to bind to the current component. +Currently, if a KubeBlocks cluster is to be referenced, the connection credential secret should include and correspond to the following fields: endpoint, port, username, and password. +Under this referencing approach, the ServiceKind and ServiceVersion of service reference declaration defined in the ClusterDefinition will not be validated. +If both Cluster and ServiceDescriptor are specified, the Cluster takes precedence.

    (Optional) -

    serviceDescriptor defines the service descriptor of the service provided by external sources.
    When referencing a service provided by external sources, you need to provide the ServiceDescriptor object name to establish the service binding.
    And serviceDescriptor is the name of the ServiceDescriptor object, furthermore, the ServiceDescriptor.spec.serviceKind and ServiceDescriptor.spec.serviceVersion
    should match clusterDefinition.componentDefs[].serviceRefDeclarations[].serviceRefDeclarationSpecs[].serviceKind
    and the regular expression defines in clusterDefinition.componentDefs[
    ].serviceRefDeclarations[].serviceRefDeclarationSpecs[].serviceVersion.
    If both Cluster and ServiceDescriptor are specified, the Cluster takes precedence.


    +

    serviceDescriptor defines the service descriptor of the service provided by external sources. +When referencing a service provided by external sources, you need to provide the ServiceDescriptor object name to establish the service binding. +And serviceDescriptor is the name of the ServiceDescriptor object, furthermore, the ServiceDescriptor.spec.serviceKind and ServiceDescriptor.spec.serviceVersion +should match clusterDefinition.componentDefs[].serviceRefDeclarations[].serviceRefDeclarationSpecs[].serviceKind +and the regular expression defines in clusterDefinition.componentDefs[].serviceRefDeclarations[].serviceRefDeclarationSpecs[].serviceVersion. +If both Cluster and ServiceDescriptor are specified, the Cluster takes precedence.

    -

    The name of the service reference declaration.
    The service reference can come from an external service that is not part of KubeBlocks, or services provided by other KubeBlocks Cluster objects.
    The specific type of service reference depends on the binding declaration when creates a Cluster.


    +

    The name of the service reference declaration. +The service reference can come from an external service that is not part of KubeBlocks, or services provided by other KubeBlocks Cluster objects. +The specific type of service reference depends on the binding declaration when creates a Cluster.

    -

    serviceRefDeclarationSpecs is a collection of service descriptions for a service reference declaration.
    Each ServiceRefDeclarationSpec defines a service Kind and Version. When multiple ServiceRefDeclarationSpecs are defined,
    it indicates that the ServiceRefDeclaration can be any one of the specified ServiceRefDeclarationSpecs.
    For example, when the ServiceRefDeclaration is declared to require an OLTP database, which can be either MySQL or PostgreSQL,
    you can define a ServiceRefDeclarationSpec for MySQL and another ServiceRefDeclarationSpec for PostgreSQL,
    when referencing the service within the cluster, as long as the serviceKind and serviceVersion match either MySQL or PostgreSQL, it can be used.


    +

    serviceRefDeclarationSpecs is a collection of service descriptions for a service reference declaration. +Each ServiceRefDeclarationSpec defines a service Kind and Version. When multiple ServiceRefDeclarationSpecs are defined, +it indicates that the ServiceRefDeclaration can be any one of the specified ServiceRefDeclarationSpecs. +For example, when the ServiceRefDeclaration is declared to require an OLTP database, which can be either MySQL or PostgreSQL, +you can define a ServiceRefDeclarationSpec for MySQL and another ServiceRefDeclarationSpec for PostgreSQL, +when referencing the service within the cluster, as long as the serviceKind and serviceVersion match either MySQL or PostgreSQL, it can be used.

    -

    service kind, indicating the type or nature of the service. It should be well-known application cluster type, e.g. {mysql, redis, mongodb}.
    The serviceKind is case-insensitive and supports abbreviations for some well-known databases.
    For example, both ‘zk’ and ‘zookeeper’ will be considered as a ZooKeeper cluster, and ‘pg’, ‘postgres’, ‘postgresql’ will all be considered as a PostgreSQL cluster.


    +

    service kind, indicating the type or nature of the service. It should be well-known application cluster type, e.g. {mysql, redis, mongodb}. +The serviceKind is case-insensitive and supports abbreviations for some well-known databases. +For example, both ‘zk’ and ‘zookeeper’ will be considered as a ZooKeeper cluster, and ‘pg’, ‘postgres’, ‘postgresql’ will all be considered as a PostgreSQL cluster.

    -

    The service version of the service reference. It is a regular expression that matches a version number pattern.
    For example, ^8.0.8$, 8.0.\d{1,2}$, ^[v\-]*?(\d{1,2}\.){0,3}\d{1,2}$


    +

    The service version of the service reference. It is a regular expression that matches a version number pattern. +For example, ^8.0.8$, 8.0.\d{1,2}$, ^[v\-]*?(\d{1,2}\.){0,3}\d{1,2}$

    @@ -14203,7 +15156,7 @@ ClusterObjectReference

    (Members of ClusterObjectReference are embedded into this type.)

    -

    The ServiceRefDeclaration to select from.


    +

    The ServiceRefDeclaration to select from.

    @@ -14229,7 +15182,7 @@ ServiceRefVars (Appears on:ServiceRefVarSelector)

    -

    ServiceRefVars defines the vars can be referenced from a ServiceRef.


    +

    ServiceRefVars defines the vars can be referenced from a ServiceRef.

    @@ -14308,7 +15261,8 @@ CredentialVars @@ -14319,7 +15273,7 @@ CredentialVars (Appears on:VarSource)

    -

    ServiceVarSelector selects a var from a Service.


    +

    ServiceVarSelector selects a var from a Service.

    (Optional) -

    The list of ports that are exposed by this service.
    More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies


    +

    The list of ports that are exposed by this service. +More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies

    @@ -14342,7 +15296,8 @@ ClusterObjectReference

    (Members of ClusterObjectReference are embedded into this type.)

    -

    The Service to select from.
    It can be referenced from the default headless service by setting the name to “headless”.


    +

    The Service to select from. +It can be referenced from the default headless service by setting the name to “headless”.

    @@ -14369,7 +15324,22 @@ bool @@ -14380,7 +15350,7 @@ bool (Appears on:ServiceVarSelector)

    -

    ServiceVars defines the vars can be referenced from a Service.


    +

    ServiceVars defines the vars can be referenced from a Service.

    (Optional) -

    GeneratePodOrdinalServiceVar indicates whether to create a corresponding ServiceVars reference variable for each Pod.
    If set to true, a set of ServiceVars that can be referenced will be automatically generated for each Pod Ordinal.
    They can be referred to by adding the PodOrdinal to the defined name template with named pattern $(Vars[x].Name)_$(PodOrdinal).
    For example, a ServiceVarRef might be defined as follows:
    - name: MY_SERVICE_PORT
    valueFrom:
    serviceVarRef:
    compDef: my-component-definition
    name: my-service
    optional: true
    generatePodOrdinalServiceVar: true
    port:
    name: redis-sentinel
    Assuming that the Component has 3 replicas, then you can reference the port of existing services named my-service-0, my-service-1,
    and my-service-2 with $MY_SERVICE_PORT_0, $MY_SERVICE_PORT_1, and $MY_SERVICE_PORT_2, respectively.
    It should be used in conjunction with Service.GeneratePodOrdinalService.


    +

    GeneratePodOrdinalServiceVar indicates whether to create a corresponding ServiceVars reference variable for each Pod. +If set to true, a set of ServiceVars that can be referenced will be automatically generated for each Pod Ordinal. +They can be referred to by adding the PodOrdinal to the defined name template with named pattern $(Vars[x].Name)_$(PodOrdinal). +For example, a ServiceVarRef might be defined as follows: +- name: MY_SERVICE_PORT +valueFrom: +serviceVarRef: +compDef: my-component-definition +name: my-service +optional: true +generatePodOrdinalServiceVar: true +port: +name: redis-sentinel +Assuming that the Component has 3 replicas, then you can reference the port of existing services named my-service-0, my-service-1, +and my-service-2 with $MY_SERVICE_PORT_0, $MY_SERVICE_PORT_1, and $MY_SERVICE_PORT_2, respectively. +It should be used in conjunction with Service.GeneratePodOrdinalService.

    @@ -14437,7 +15407,7 @@ NamedVar (Appears on:ClusterSpec)

    -

    ShardingSpec defines the sharding spec.


    +

    ShardingSpec defines the sharding spec.

    @@ -14455,7 +15425,9 @@ string @@ -14468,7 +15440,8 @@ ClusterComponentSpec @@ -14479,7 +15452,13 @@ int32 @@ -14507,7 +15486,7 @@ int32 @@ -14519,7 +15498,7 @@ bool @@ -14530,7 +15509,7 @@ bool (Appears on:UnixSignalTrigger)

    -

    SignalType defines which signals are valid.


    +

    SignalType defines which signals are valid.

    -

    name defines sharding name, this name is also part of Service DNS name, so this name will comply with IANA Service Naming rule.
    The name is also used to generate the name of the underlying components with the naming pattern $(ShardingSpec.Name)-$(ShardID).
    At the same time, the name of component template defined in ShardingSpec.Template.Name will be ignored.


    +

    name defines sharding name, this name is also part of Service DNS name, so this name will comply with IANA Service Naming rule. +The name is also used to generate the name of the underlying components with the naming pattern $(ShardingSpec.Name)-$(ShardID). +At the same time, the name of component template defined in ShardingSpec.Template.Name will be ignored.

    -

    template defines the component template.
    A ShardingSpec generates a set of components (also called shards) based on the component template, and this group of components or shards have the same specifications and definitions.


    +

    template defines the component template. +A ShardingSpec generates a set of components (also called shards) based on the component template, and this group of components or shards have the same specifications and definitions.

    -

    shards indicates the number of component, and these components have the same specifications and definitions.
    It should be noted that the number of replicas for each component should be defined by template.replicas.
    Moreover, the logical relationship between these components should be maintained by the components themselves,
    KubeBlocks only provides the following capabilities for managing the lifecycle of sharding:
    1. When the number of shards increases, the postProvision Action defined in the ComponentDefinition will be executed if the conditions are met.
    2. When the number of shards decreases, the preTerminate Action defined in the ComponentDefinition will be executed if the conditions are met.
    Additionally, the resources and data associated with the corresponding Component will be deleted as well.


    +

    shards indicates the number of component, and these components have the same specifications and definitions. +It should be noted that the number of replicas for each component should be defined by template.replicas. +Moreover, the logical relationship between these components should be maintained by the components themselves, +KubeBlocks only provides the following capabilities for managing the lifecycle of sharding: +1. When the number of shards increases, the postProvision Action defined in the ComponentDefinition will be executed if the conditions are met. +2. When the number of shards decreases, the preTerminate Action defined in the ComponentDefinition will be executed if the conditions are met. +Additionally, the resources and data associated with the corresponding Component will be deleted as well.

    -

    command used to execute for reload.


    +

    command used to execute for reload.

    (Optional) -

    Specify synchronize updates parameters to the config manager.


    +

    Specify synchronize updates parameters to the config manager.

    @@ -14629,7 +15608,13 @@ UpdateStrategy @@ -14643,7 +15628,14 @@ Kubernetes apps/v1.PodManagementPolicyType @@ -14657,7 +15649,9 @@ Kubernetes apps/v1.StatefulSetUpdateStrategy @@ -14665,7 +15659,7 @@ Kubernetes apps/v1.StatefulSetUpdateStrategy

    StatefulSetWorkload

    -

    StatefulSetWorkload interface


    +

    StatefulSetWorkload interface

    StatelessSetSpec

    @@ -14693,7 +15687,7 @@ Kubernetes apps/v1.DeploymentStrategy @@ -14724,7 +15718,7 @@ Kubernetes resource.Quantity @@ -14738,7 +15732,7 @@ Kubernetes resource.Quantity @@ -14749,7 +15743,8 @@ Kubernetes resource.Quantity (Appears on:ClusterSwitchPolicy)

    -

    SwitchPolicyType defines switchPolicy type.
    Currently, only Noop is supported. MaximumAvailability and MaximumDataProtection will be supported in the future.


    +

    SwitchPolicyType defines switchPolicy type. +Currently, only Noop is supported. MaximumAvailability and MaximumDataProtection will be supported in the future.

    (Optional) -

    updateStrategy, Pods update strategy.
    In case of workloadType=Consensus the update strategy will be following:



    serial: update Pods one by one that guarantee minimum component unavailable time.
    Learner -> Follower(with AccessMode=none) -> Follower(with AccessMode=readonly) -> Follower(with AccessMode=readWrite) -> Leader
    bestEffortParallel: update Pods in parallel that guarantee minimum component un-writable time.
    Learner, Follower(minority) in parallel -> Follower(majority) -> Leader, keep majority online all the time.
    parallel: force parallel


    +

    updateStrategy, Pods update strategy. +In case of workloadType=Consensus the update strategy will be following:

    +

    serial: update Pods one by one that guarantee minimum component unavailable time. +Learner -> Follower(with AccessMode=none) -> Follower(with AccessMode=readonly) -> Follower(with AccessMode=readWrite) -> Leader +bestEffortParallel: update Pods in parallel that guarantee minimum component un-writable time. +Learner, Follower(minority) in parallel -> Follower(majority) -> Leader, keep majority online all the time. +parallel: force parallel

    (Optional) -

    llPodManagementPolicy is the low-level controls how pods are created during initial scale up,
    when replacing pods on nodes, or when scaling down.
    OrderedReady policy specify where pods are created in increasing order (pod-0, then
    pod-1, etc) and the controller will wait until each pod is ready before
    continuing. When scaling down, the pods are removed in the opposite order.
    Parallel policy specify create pods in parallel
    to match the desired scale without waiting, and on scale down will delete
    all pods at once.


    +

    llPodManagementPolicy is the low-level controls how pods are created during initial scale up, +when replacing pods on nodes, or when scaling down. +OrderedReady policy specify where pods are created in increasing order (pod-0, then +pod-1, etc) and the controller will wait until each pod is ready before +continuing. When scaling down, the pods are removed in the opposite order. +Parallel policy specify create pods in parallel +to match the desired scale without waiting, and on scale down will delete +all pods at once.

    (Optional) -

    llUpdateStrategy indicates the low-level StatefulSetUpdateStrategy that will be
    employed to update Pods in the StatefulSet when a revision is made to
    Template. Will ignore updateStrategy attribute if provided.


    +

    llUpdateStrategy indicates the low-level StatefulSetUpdateStrategy that will be +employed to update Pods in the StatefulSet when a revision is made to +Template. Will ignore updateStrategy attribute if provided.

    (Optional) -

    updateStrategy defines the underlying deployment strategy to use to replace existing pods with new ones.


    +

    updateStrategy defines the underlying deployment strategy to use to replace existing pods with new ones.

    (Optional) -

    The minimum size of storage.


    +

    The minimum size of storage.

    (Optional) -

    The maximum size of storage.


    +

    The maximum size of storage.

    @@ -14804,7 +15799,14 @@ string @@ -14834,7 +15836,7 @@ CmdExecutorConfig @@ -14848,7 +15850,8 @@ CmdExecutorConfig @@ -14859,7 +15862,7 @@ CmdExecutorConfig (Appears on:ClusterComponentVersion)

    -

    SwitchoverShortSpec is a short version of SwitchoverSpec, with only CommandExecutorEnvItem field.


    +

    SwitchoverShortSpec is a short version of SwitchoverSpec, with only CommandExecutorEnvItem field.

    -

    instanceName is used to specify the candidate primary or leader instanceName for switchover.
    If instanceName is set to “”, it means that no specific primary or leader is specified for the switchover,
    and the switchoverAction defined in clusterDefinition.componentDefs[x].switchoverSpec.withoutCandidate will be executed,
    It is required that clusterDefinition.componentDefs[x].switchoverSpec.withoutCandidate is not empty.
    If instanceName is set to a valid instanceName other than “
    ”, it means that a specific candidate primary or leader is specified for the switchover.
    the value of instanceName can be obtained using kbcli cluster list-instances, any other value is invalid.
    In this case, the switchoverAction defined in clusterDefinition.componentDefs[x].switchoverSpec.withCandidate will be executed,
    and it is required that clusterDefinition.componentDefs[x].switchoverSpec.withCandidate is not empty.


    +

    instanceName is used to specify the candidate primary or leader instanceName for switchover. +If instanceName is set to “”, it means that no specific primary or leader is specified for the switchover, +and the switchoverAction defined in clusterDefinition.componentDefs[x].switchoverSpec.withoutCandidate will be executed, +It is required that clusterDefinition.componentDefs[x].switchoverSpec.withoutCandidate is not empty. +If instanceName is set to a valid instanceName other than “”, it means that a specific candidate primary or leader is specified for the switchover. +the value of instanceName can be obtained using kbcli cluster list-instances, any other value is invalid. +In this case, the switchoverAction defined in clusterDefinition.componentDefs[x].switchoverSpec.withCandidate will be executed, +and it is required that clusterDefinition.componentDefs[x].switchoverSpec.withCandidate is not empty.

    -

    cmdExecutorConfig is the executor configuration of the switchover command.


    +

    cmdExecutorConfig is the executor configuration of the switchover command.

    (Optional) -

    scriptSpecSelectors defines the selector of the scriptSpecs that need to be referenced.
    Once ScriptSpecSelectors is defined, the scripts defined in scriptSpecs can be referenced in the SwitchoverAction.CmdExecutorConfig.


    +

    scriptSpecSelectors defines the selector of the scriptSpecs that need to be referenced. +Once ScriptSpecSelectors is defined, the scripts defined in scriptSpecs can be referenced in the SwitchoverAction.CmdExecutorConfig.

    @@ -14879,7 +15882,7 @@ CommandExecutorEnvItem @@ -14910,7 +15913,7 @@ SwitchoverAction @@ -14924,7 +15927,7 @@ SwitchoverAction @@ -14952,7 +15955,9 @@ string @@ -14964,7 +15969,9 @@ bool @@ -14976,7 +15983,8 @@ string @@ -14990,7 +15998,8 @@ PasswordConfig @@ -15004,7 +16013,8 @@ ProvisionSecretRef @@ -15015,7 +16025,7 @@ ProvisionSecretRef (Appears on:SystemAccountSpec)

    -

    SystemAccountConfig specifies how to create and delete system accounts.


    +

    SystemAccountConfig specifies how to create and delete system accounts.

    -

    CmdExecutorConfig is the command executor config.


    +

    CmdExecutorConfig is the command executor config.

    (Optional) -

    withCandidate corresponds to the switchover of the specified candidate primary or leader instance.


    +

    withCandidate corresponds to the switchover of the specified candidate primary or leader instance.

    (Optional) -

    withoutCandidate corresponds to a switchover that does not specify a candidate primary or leader instance.


    +

    withoutCandidate corresponds to a switchover that does not specify a candidate primary or leader instance.

    -

    The name of the account.
    Others can refer to this account by the name.
    Cannot be updated.


    +

    The name of the account. +Others can refer to this account by the name. +Cannot be updated.

    (Optional) -

    InitAccount indicates whether this is the unique system initialization account (e.g., MySQL root).
    Only one system init account is allowed.
    Cannot be updated.


    +

    InitAccount indicates whether this is the unique system initialization account (e.g., MySQL root). +Only one system init account is allowed. +Cannot be updated.

    (Optional) -

    Statement specifies the statement used to create the account with required privileges.
    Cannot be updated.


    +

    Statement specifies the statement used to create the account with required privileges. +Cannot be updated.

    (Optional) -

    PasswordGenerationPolicy defines the policy for generating the account’s password.
    Cannot be updated.


    +

    PasswordGenerationPolicy defines the policy for generating the account’s password. +Cannot be updated.

    (Optional) -

    SecretRef specifies the secret from which data will be copied to create the new account.
    Cannot be updated.


    +

    SecretRef specifies the secret from which data will be copied to create the new account. +Cannot be updated.

    @@ -15035,7 +16045,7 @@ AccountName @@ -15048,7 +16058,7 @@ ProvisionPolicy @@ -15059,7 +16069,7 @@ ProvisionPolicy (Appears on:ClusterComponentVersion)

    -

    SystemAccountShortSpec is a short version of SystemAccountSpec, with only CmdExecutorConfig field.


    +

    SystemAccountShortSpec is a short version of SystemAccountSpec, with only CmdExecutorConfig field.

    -

    name is the name of a system account.


    +

    name is the name of a system account.

    -

    provisionPolicy defines how to create account.


    +

    provisionPolicy defines how to create account.

    @@ -15079,7 +16089,7 @@ CommandExecutorEnvItem @@ -15090,7 +16100,7 @@ CommandExecutorEnvItem (Appears on:ClusterComponentDefinition)

    -

    SystemAccountSpec specifies information to create system accounts.


    +

    SystemAccountSpec specifies information to create system accounts.

    -

    cmdExecutorConfig configs how to get client SDK and perform statements.


    +

    cmdExecutorConfig configs how to get client SDK and perform statements.

    @@ -15110,7 +16120,7 @@ CmdExecutorConfig @@ -15123,7 +16133,7 @@ PasswordConfig @@ -15136,7 +16146,7 @@ PasswordConfig @@ -15188,7 +16198,7 @@ Issuer (Appears on:Issuer)

    -

    TLSSecretRef defines Secret contains Tls certs


    +

    TLSSecretRef defines Secret contains Tls certs

    -

    cmdExecutorConfig configs how to get client SDK and perform statements.


    +

    cmdExecutorConfig configs how to get client SDK and perform statements.

    -

    passwordConfig defines the pattern to generate password.


    +

    passwordConfig defines the pattern to generate password.

    -

    accounts defines system account config settings.


    +

    accounts defines system account config settings.

    @@ -15206,7 +16216,7 @@ string @@ -15217,7 +16227,7 @@ string @@ -15228,7 +16238,7 @@ string @@ -15239,7 +16249,7 @@ string @@ -15283,7 +16293,7 @@ bool @@ -15311,7 +16321,15 @@ string @@ -15323,7 +16341,10 @@ string @@ -15335,7 +16356,13 @@ github.com/apecloud/kubeblocks/apis/dataprotection/v1alpha1.PodSelectionStrategy @@ -15349,7 +16376,9 @@ ConnectionCredentialKey @@ -15360,7 +16389,7 @@ ConnectionCredentialKey (Appears on:Action)

    -

    TargetPodSelector defines how to select pod(s) to execute a action.


    +

    TargetPodSelector defines how to select pod(s) to execute a action.

    -

    Name of the Secret


    +

    Name of the Secret

    -

    CA cert key in Secret


    +

    CA cert key in Secret

    -

    Cert key in Secret


    +

    Cert key in Secret

    -

    Key of TLS private key in Secret


    +

    Key of TLS private key in Secret

    (Optional) -

    Specify synchronize updates parameters to the config manager.


    +

    Specify synchronize updates parameters to the config manager.

    -

    select instance of corresponding role for backup, role are:
    - the name of Leader/Follower/Leaner for Consensus component.
    - primary or secondary for Replication component.
    finally, invalid role of the component will be ignored.
    such as if workload type is Replication and component’s replicas is 1,
    the secondary role is invalid. and it also will be ignored when component is Stateful/Stateless.
    the role will be transformed to a role LabelSelector for BackupPolicy’s target attribute.


    +

    select instance of corresponding role for backup, role are:

    +
      +
    • the name of Leader/Follower/Leaner for Consensus component.
    • +
    • primary or secondary for Replication component.
    • +
    +

    finally, invalid role of the component will be ignored. +such as if workload type is Replication and component’s replicas is 1, +the secondary role is invalid. and it also will be ignored when component is Stateful/Stateless. +the role will be transformed to a role LabelSelector for BackupPolicy’s target attribute.

    (Optional) -

    refer to spec.componentDef.systemAccounts.accounts[*].name in ClusterDefinition.
    the secret created by this account will be used to connect the database.
    if not set, the secret created by spec.ConnectionCredential of the ClusterDefinition will be used.
    it will be transformed to a secret for BackupPolicy’s target secret.


    +

    refer to spec.componentDef.systemAccounts.accounts[*].name in ClusterDefinition. +the secret created by this account will be used to connect the database. +if not set, the secret created by spec.ConnectionCredential of the ClusterDefinition will be used. +it will be transformed to a secret for BackupPolicy’s target secret.

    (Optional) -

    PodSelectionStrategy specifies the strategy to select when multiple pods are
    selected for backup target.
    Valid values are:
    - Any: select any one pod that match the labelsSelector.
    - All: select all pods that match the labelsSelector.


    +

    PodSelectionStrategy specifies the strategy to select when multiple pods are +selected for backup target. +Valid values are:

    +
      +
    • Any: select any one pod that match the labelsSelector.
    • +
    • All: select all pods that match the labelsSelector.
    • +
    (Optional) -

    connectionCredentialKey defines connection credential key in secret
    which created by spec.ConnectionCredential of the ClusterDefinition.
    it will be ignored when “account” is set.


    +

    connectionCredentialKey defines connection credential key in secret +which created by spec.ConnectionCredential of the ClusterDefinition. +it will be ignored when “account” is set.

    @@ -15385,7 +16414,7 @@ ConnectionCredentialKey (Appears on:Affinity, ClusterSpec)

    -

    TenancyType for cluster tenant resources.


    +

    TenancyType for cluster tenant resources.

    @@ -15406,7 +16435,7 @@ ConnectionCredentialKey (Appears on:ClusterSpec)

    -

    TerminationPolicyType defines termination policy types.


    +

    TerminationPolicyType defines termination policy types.

    @@ -15448,7 +16477,7 @@ string @@ -15460,7 +16489,7 @@ string @@ -15471,7 +16500,7 @@ string @@ -15499,7 +16528,7 @@ string @@ -15513,7 +16542,7 @@ string @@ -15543,7 +16572,9 @@ SignalType @@ -15554,7 +16585,7 @@ string @@ -15565,7 +16596,7 @@ string (Appears on:ClusterComponentSpec, ComponentDefinitionSpec, StatefulSetSpec)

    -

    UpdateStrategy defines Cluster Component update strategy.


    +

    UpdateStrategy defines Cluster Component update strategy.

    -

    Specify the name of initContainer. Must be a DNS_LABEL name.


    +

    Specify the name of initContainer. Must be a DNS_LABEL name.

    (Optional) -

    tools Container image name.


    +

    tools Container image name.

    -

    exec used to execute for init containers.


    +

    exec used to execute for init containers.

    -

    mountPoint is the mount point of the scripts file.


    +

    mountPoint is the mount point of the scripts file.

    (Optional) -

    toolConfig used to config init container.


    +

    toolConfig used to config init container.

    -

    signal is valid for unix signal.
    e.g: SIGHUP
    url: ../../pkg/configuration/configmap/handler.go:allUnixSignals


    +

    signal is valid for unix signal. +e.g: SIGHUP +url: ../../pkg/configuration/configmap/handler.go:allUnixSignals

    -

    processName is process name, sends unix signal to proc.


    +

    processName is process name, sends unix signal to proc.

    @@ -15606,7 +16637,7 @@ map[string]string @@ -15618,7 +16649,7 @@ map[string]string @@ -15630,7 +16661,7 @@ map[string]string @@ -15641,7 +16672,7 @@ map[string]string (Appears on:OpsRequestSpec)

    -

    Upgrade defines the variables of upgrade operation.


    +

    Upgrade defines the variables of upgrade operation.

    (Optional) -

    addedKeys describes the key added.


    +

    addedKeys describes the key added.

    (Optional) -

    deletedKeys describes the key deleted.


    +

    deletedKeys describes the key deleted.

    (Optional) -

    updatedKeys describes the key updated.


    +

    updatedKeys describes the key updated.

    @@ -15659,7 +16690,7 @@ string @@ -15670,7 +16701,7 @@ string (Appears on:ConfigurationItem, ConfigurationItemStatus)

    -

    UpgradePolicy defines the policy of reconfiguring.


    +

    UpgradePolicy defines the policy of reconfiguring.

    -

    clusterVersionRef references ClusterVersion name.


    +

    clusterVersionRef references ClusterVersion name.

    @@ -15719,7 +16750,7 @@ string @@ -15733,7 +16764,7 @@ string @@ -15764,7 +16795,7 @@ string @@ -15778,7 +16809,7 @@ string @@ -15806,7 +16837,7 @@ string @@ -15817,7 +16848,7 @@ string @@ -15828,7 +16859,7 @@ string (Appears on:CredentialVars, NamedVar, ServiceRefVars, ServiceVars)

    -

    VarOption defines whether a variable is required or optional.


    +

    VarOption defines whether a variable is required or optional.

    VarSource

    @@ -15836,7 +16867,7 @@ string (Appears on:EnvVar)

    -

    VarSource represents a source for the value of an EnvVar.


    +

    VarSource represents a source for the value of an EnvVar.

    (Optional) -

    secretRefs defines the user-defined secrets.


    +

    secretRefs defines the user-defined secrets.

    (Optional) -

    configMapRefs defines the user-defined configmaps.


    +

    configMapRefs defines the user-defined configmaps.

    (Optional) -

    mapped ClusterVersionRef to env value.


    +

    mapped ClusterVersionRef to env value.

    (Optional) -

    mapped ComponentDefinition to env value.


    +

    mapped ComponentDefinition to env value.

    -

    the array of ClusterVersion name which can be mapped to the env value.


    +

    the array of ClusterVersion name which can be mapped to the env value.

    -

    mapping value for the specified ClusterVersion names.


    +

    mapping value for the specified ClusterVersion names.

    @@ -15857,7 +16888,7 @@ Kubernetes core/v1.ConfigMapKeySelector @@ -15871,7 +16902,7 @@ Kubernetes core/v1.SecretKeySelector @@ -15885,7 +16916,7 @@ ServiceVarSelector @@ -15899,7 +16930,7 @@ CredentialVarSelector @@ -15913,7 +16944,7 @@ ServiceRefVarSelector @@ -15943,7 +16974,11 @@ PodSelectionStrategy @@ -15956,7 +16991,7 @@ PodSelectionStrategy @@ -15987,7 +17022,8 @@ PodSelectionStrategy @@ -16001,7 +17037,8 @@ PodSelectionStrategy @@ -16012,7 +17049,7 @@ PodSelectionStrategy (Appears on:OpsRequestSpec)

    -

    VerticalScaling defines the variables that need to input when scaling compute resources.


    +

    VerticalScaling defines the variables that need to input when scaling compute resources.

    (Optional) -

    Selects a key of a ConfigMap.


    +

    Selects a key of a ConfigMap.

    (Optional) -

    Selects a key of a Secret.


    +

    Selects a key of a Secret.

    (Optional) -

    Selects a defined var of a Service.


    +

    Selects a defined var of a Service.

    (Optional) -

    Selects a defined var of a Credential (SystemAccount).


    +

    Selects a defined var of a Credential (SystemAccount).

    (Optional) -

    Selects a defined var of a ServiceRef.


    +

    Selects a defined var of a ServiceRef.

    -

    podSelectionStrategy how to select the target component pod for variable references based on the strategy.
    - PreferredAvailable: prioritize the selection of available pod.
    - Available: only select available pod. if not found, terminating the operation.


    +

    podSelectionStrategy how to select the target component pod for variable references based on the strategy.

    +
      +
    • PreferredAvailable: prioritize the selection of available pod.
    • +
    • Available: only select available pod. if not found, terminating the operation.
    • +
    -

    List of environment variables to set in the job’s container.


    +

    List of environment variables to set in the job’s container.

    (Optional) -

    Provide ClusterDefinition.spec.componentDefs.podSpec.initContainers override
    values, typical scenarios are application container image updates.


    +

    Provide ClusterDefinition.spec.componentDefs.podSpec.initContainers override +values, typical scenarios are application container image updates.

    (Optional) -

    Provide ClusterDefinition.spec.componentDefs.podSpec.containers override
    values, typical scenarios are application container image updates.


    +

    Provide ClusterDefinition.spec.componentDefs.podSpec.containers override +values, typical scenarios are application container image updates.

    @@ -16050,7 +17087,7 @@ Kubernetes core/v1.ResourceRequirements

    (Members of ResourceRequirements are embedded into this type.)

    -

    resources specifies the computing resource size of verticalScaling.


    +

    resources specifies the computing resource size of verticalScaling.

    @@ -16064,7 +17101,7 @@ ClassDefRef @@ -16075,7 +17112,7 @@ ClassDefRef (Appears on:OpsRequestSpec)

    -

    VolumeExpansion defines the variables of volume expansion operation.


    +

    VolumeExpansion defines the variables of volume expansion operation.

    (Optional) -

    classDefRef reference class defined in ComponentClassDefinition.


    +

    classDefRef reference class defined in ComponentClassDefinition.

    @@ -16110,7 +17147,7 @@ ComponentOps @@ -16139,7 +17176,11 @@ int @@ -16153,7 +17194,7 @@ int @@ -16164,7 +17205,7 @@ int (Appears on:VolumeTypeSpec)

    -

    VolumeType defines volume type for backup data or log.


    +

    VolumeType defines volume type for backup data or log.

    -

    volumeClaimTemplates specifies the storage size and volumeClaimTemplate name.


    +

    volumeClaimTemplates specifies the storage size and volumeClaimTemplate name.

    (Optional) -

    The high watermark threshold for volume space usage.
    If there is any specified volumes who’s space usage is over the threshold, the pre-defined “LOCK” action
    will be triggered to degrade the service to protect volume from space exhaustion, such as to set the instance
    as read-only. And after that, if all volumes’ space usage drops under the threshold later, the pre-defined
    “UNLOCK” action will be performed to recover the service normally.


    +

    The high watermark threshold for volume space usage. +If there is any specified volumes who’s space usage is over the threshold, the pre-defined “LOCK” action +will be triggered to degrade the service to protect volume from space exhaustion, such as to set the instance +as read-only. And after that, if all volumes’ space usage drops under the threshold later, the pre-defined +“UNLOCK” action will be performed to recover the service normally.

    (Optional) -

    Volumes to protect.


    +

    Volumes to protect.

    @@ -16202,7 +17243,8 @@ string @@ -16216,7 +17258,9 @@ VolumeType @@ -16227,7 +17271,7 @@ VolumeType (Appears on:ClusterComponentDefinition, OpsRequestComponentStatus)

    -

    WorkloadType defines ClusterDefinition’s component workload type.


    +

    WorkloadType defines ClusterDefinition’s component workload type.

    -

    name definition is the same as the name of the VolumeMounts field in PodSpec.Container,
    similar to the relations of Volumes[].name and VolumesMounts[].name in Pod.Spec.


    +

    name definition is the same as the name of the VolumeMounts field in PodSpec.Container, +similar to the relations of Volumes[].name and VolumesMounts[].name in Pod.Spec.

    (Optional) -

    type is in enum of {data, log}.
    VolumeTypeData: the volume is for the persistent data storage.
    VolumeTypeLog: the volume is for the persistent log storage.


    +

    type is in enum of {data, log}. +VolumeTypeData: the volume is for the persistent data storage. +VolumeTypeLog: the volume is for the persistent log storage.

    @@ -16247,6 +17291,1400 @@ VolumeType

    +

    workloads.kubeblocks.io/v1alpha1

    +
    +
    +Resource Types: + +

    ReplicatedStateMachine +

    +
    +

    ReplicatedStateMachine is the Schema for the replicatedstatemachines API.

    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    FieldDescription
    +apiVersion
    +string
    +workloads.kubeblocks.io/v1alpha1 +
    +kind
    +string +
    ReplicatedStateMachine
    +metadata
    + + +Kubernetes meta/v1.ObjectMeta + + +
    +Refer to the Kubernetes API documentation for the fields of the +metadata field. +
    +spec
    + + +ReplicatedStateMachineSpec + + +
    +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +replicas
    + +int32 + +
    +(Optional) +

    replicas is the desired number of replicas of the given Template. +These are replicas in the sense that they are instantiations of the +same Template, but individual replicas also have a consistent identity. +If unspecified, defaults to 1.

    +
    +minReadySeconds
    + +int32 + +
    +(Optional) +

    Minimum number of seconds for which a newly created pod should be ready +without any of its container crashing for it to be considered available. +Defaults to 0 (pod will be considered available as soon as it is ready)

    +
    +selector
    + + +Kubernetes meta/v1.LabelSelector + + +
    +

    selector is a label query over pods that should match the replica count. +It must match the pod template’s labels. +More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors

    +
    +serviceName
    + +string + +
    +

    serviceName is the name of the service that governs this StatefulSet. +This service must exist before the StatefulSet, and is responsible for +the network identity of the set. Pods get DNS/hostnames that follow the +pattern: pod-specific-string.serviceName.default.svc.cluster.local +where “pod-specific-string” is managed by the StatefulSet controller.

    +
    +service
    + + +Kubernetes core/v1.Service + + +
    +(Optional) +

    service defines the behavior of a service spec. +provides read-write service +https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status

    +
    +alternativeServices
    + + +[]Kubernetes core/v1.Service + + +
    +(Optional) +

    AlternativeServices defines Alternative Services selector pattern specifier. +can be used for creating Readonly service.

    +
    +template
    + + +Kubernetes core/v1.PodTemplateSpec + + +
    +
    +volumeClaimTemplates
    + + +[]Kubernetes core/v1.PersistentVolumeClaim + + +
    +(Optional) +

    volumeClaimTemplates is a list of claims that pods are allowed to reference. +The ReplicatedStateMachine controller is responsible for mapping network identities to +claims in a way that maintains the identity of a pod. Every claim in +this list must have at least one matching (by name) volumeMount in one +container in the template. A claim in this list takes precedence over +any volumes in the template, with the same name.

    +
    +podManagementPolicy
    + + +Kubernetes apps/v1.PodManagementPolicyType + + +
    +(Optional) +

    podManagementPolicy controls how pods are created during initial scale up, +when replacing pods on nodes, or when scaling down. The default policy is +OrderedReady, where pods are created in increasing order (pod-0, then +pod-1, etc) and the controller will wait until each pod is ready before +continuing. When scaling down, the pods are removed in the opposite order. +The alternative policy is Parallel which will create pods in parallel +to match the desired scale without waiting, and on scale down will delete +all pods at once.

    +
    +updateStrategy
    + + +Kubernetes apps/v1.StatefulSetUpdateStrategy + + +
    +

    updateStrategy indicates the StatefulSetUpdateStrategy that will be +employed to update Pods in the RSM when a revision is made to +Template. +UpdateStrategy.Type will be set to appsv1.OnDeleteStatefulSetStrategyType if MemberUpdateStrategy is not nil

    +
    +roles
    + + +[]ReplicaRole + + +
    +(Optional) +

    Roles, a list of roles defined in the system.

    +
    +roleProbe
    + + +RoleProbe + + +
    +(Optional) +

    RoleProbe provides method to probe role.

    +
    +membershipReconfiguration
    + + +MembershipReconfiguration + + +
    +(Optional) +

    MembershipReconfiguration provides actions to do membership dynamic reconfiguration.

    +
    +memberUpdateStrategy
    + + +MemberUpdateStrategy + + +
    +(Optional) +

    MemberUpdateStrategy, Members(Pods) update strategy. +serial: update Members one by one that guarantee minimum component unavailable time. +Learner -> Follower(with AccessMode=none) -> Follower(with AccessMode=readonly) -> Follower(with AccessMode=readWrite) -> Leader +bestEffortParallel: update Members in parallel that guarantee minimum component un-writable time. +Learner, Follower(minority) in parallel -> Follower(majority) -> Leader, keep majority online all the time. +parallel: force parallel

    +
    +paused
    + +bool + +
    +(Optional) +

    Paused indicates that the rsm is paused, means the reconciliation of this rsm object will be paused.

    +
    +credential
    + + +Credential + + +
    +(Optional) +

    Credential used to connect to DB engine

    +
    +rsmTransformPolicy
    + + +RsmTransformPolicy + + +
    +(Optional) +

    RsmTransformPolicy defines the policy generate sts using rsm. Passed from cluster. +ToSts: rsm transform to statefulSet +ToPod: rsm transform to pod

    +
    +nodeAssignment
    + + +[]NodeAssignment + + +
    +(Optional) +

    NodeAssignment defines the expected assignment of nodes.

    +
    +
    +status
    + + +ReplicatedStateMachineStatus + + +
    +
    +

    AccessMode +(string alias)

    +

    +(Appears on:ReplicaRole) +

    +
    +

    AccessMode defines SVC access mode enums.

    +
    + + + + + + + + + + + + + + +
    ValueDescription

    "None"

    "ReadWrite"

    "Readonly"

    +

    Action +

    +

    +(Appears on:MembershipReconfiguration, RoleProbe) +

    +
    +
    + + + + + + + + + + + + + + + + + + + + + +
    FieldDescription
    +image
    + +string + +
    +(Optional) +

    utility image contains command that can be used to retrieve of process role info

    +
    +command
    + +[]string + +
    +

    Command will be executed in Container to retrieve or process role info

    +
    +args
    + +[]string + +
    +(Optional) +

    Args is used to perform statements.

    +
    +

    Credential +

    +

    +(Appears on:ReplicatedStateMachineSpec) +

    +
    +
    + + + + + + + + + + + + + + + + + +
    FieldDescription
    +username
    + + +CredentialVar + + +
    +

    Username +variable name will be KB_RSM_USERNAME

    +
    +password
    + + +CredentialVar + + +
    +

    Password +variable name will be KB_RSM_PASSWORD

    +
    +

    CredentialVar +

    +

    +(Appears on:Credential) +

    +
    +
    + + + + + + + + + + + + + + + + + +
    FieldDescription
    +value
    + +string + +
    +(Optional) +

    Variable references $(VAR_NAME) are expanded +using the previously defined environment variables in the container and +any service environment variables. If a variable cannot be resolved, +the reference in the input string will be unchanged. Double $$ are reduced +to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. +“$$(VAR_NAME)” will produce the string literal “$(VAR_NAME)”. +Escaped references will never be expanded, regardless of whether the variable +exists or not. +Defaults to “”.

    +
    +valueFrom
    + + +Kubernetes core/v1.EnvVarSource + + +
    +(Optional) +

    Source for the environment variable’s value. Cannot be used if value is not empty.

    +
    +

    MemberStatus +

    +

    +(Appears on:ClusterComponentStatus, ReplicatedStateMachineStatus) +

    +
    +
    + + + + + + + + + + + + + + + + + + + + + +
    FieldDescription
    +podName
    + +string + +
    +

    PodName pod name.

    +
    +role
    + + +ReplicaRole + + +
    +
    +readyWithoutPrimary
    + +bool + +
    +(Optional) +

    Is it required for rsm to have at least one primary pod to be ready.

    +
    +

    MemberUpdateStrategy +(string alias)

    +

    +(Appears on:RSMSpec, ReplicatedStateMachineSpec) +

    +
    +

    MemberUpdateStrategy defines Cluster Component update strategy.

    +
    + + + + + + + + + + + + + + +
    ValueDescription

    "BestEffortParallel"

    "Parallel"

    "Serial"

    +

    MembershipReconfiguration +

    +

    +(Appears on:RSMSpec, ReplicatedStateMachineSpec) +

    +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    FieldDescription
    +switchoverAction
    + + +Action + + +
    +(Optional) +

    Environment variables can be used in all following Actions:

    +
      +
    • KB_RSM_USERNAME username part of credential
    • +
    • KB_RSM_PASSWORD password part of credential
    • +
    • KB_RSM_LEADER_HOST leader host
    • +
    • KB_RSM_TARGET_HOST target host
    • +
    • KB_RSM_SERVICE_PORT port
    • +
    +

    SwitchoverAction specifies how to do switchover +latest BusyBox image will be used if Image not configured

    +
    +memberJoinAction
    + + +Action + + +
    +(Optional) +

    MemberJoinAction specifies how to add member +previous none-nil action’s Image will be used if not configured

    +
    +memberLeaveAction
    + + +Action + + +
    +(Optional) +

    MemberLeaveAction specifies how to remove member +previous none-nil action’s Image will be used if not configured

    +
    +logSyncAction
    + + +Action + + +
    +(Optional) +

    LogSyncAction specifies how to trigger the new member to start log syncing +previous none-nil action’s Image will be used if not configured

    +
    +promoteAction
    + + +Action + + +
    +(Optional) +

    PromoteAction specifies how to tell the cluster that the new member can join voting now +previous none-nil action’s Image will be used if not configured

    +
    +

    NodeAssignment +

    +

    +(Appears on:ReplicatedStateMachineSpec) +

    +
    +
    + + + + + + + + + + + + + + + + + +
    FieldDescription
    +name
    + +string + +
    +(Optional) +

    Name defines the name of statefulSet that needs to allocate node.

    +
    +nodeSpec
    + + +NodeSpec + + +
    +(Optional) +

    NodeSpec defines the detailed node info that will assign to the statefulSet.

    +
    +

    NodeSpec +

    +

    +(Appears on:NodeAssignment) +

    +
    +
    + + + + + + + + + + + + + +
    FieldDescription
    +nodeName
    + + +k8s.io/apimachinery/pkg/types.NodeName + + +
    +(Optional) +
    +

    ReplicaRole +

    +

    +(Appears on:RSMSpec, MemberStatus, ReplicatedStateMachineSpec) +

    +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + +
    FieldDescription
    +name
    + +string + +
    +

    Name, role name.

    +
    +accessMode
    + + +AccessMode + + +
    +

    AccessMode, what service this member capable.

    +
    +canVote
    + +bool + +
    +(Optional) +

    CanVote, whether this member has voting rights

    +
    +isLeader
    + +bool + +
    +(Optional) +

    IsLeader, whether this member is the leader

    +
    +

    ReplicatedStateMachineSpec +

    +

    +(Appears on:ReplicatedStateMachine) +

    +
    +

    ReplicatedStateMachineSpec defines the desired state of ReplicatedStateMachine

    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    FieldDescription
    +replicas
    + +int32 + +
    +(Optional) +

    replicas is the desired number of replicas of the given Template. +These are replicas in the sense that they are instantiations of the +same Template, but individual replicas also have a consistent identity. +If unspecified, defaults to 1.

    +
    +minReadySeconds
    + +int32 + +
    +(Optional) +

    Minimum number of seconds for which a newly created pod should be ready +without any of its container crashing for it to be considered available. +Defaults to 0 (pod will be considered available as soon as it is ready)

    +
    +selector
    + + +Kubernetes meta/v1.LabelSelector + + +
    +

    selector is a label query over pods that should match the replica count. +It must match the pod template’s labels. +More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors

    +
    +serviceName
    + +string + +
    +

    serviceName is the name of the service that governs this StatefulSet. +This service must exist before the StatefulSet, and is responsible for +the network identity of the set. Pods get DNS/hostnames that follow the +pattern: pod-specific-string.serviceName.default.svc.cluster.local +where “pod-specific-string” is managed by the StatefulSet controller.

    +
    +service
    + + +Kubernetes core/v1.Service + + +
    +(Optional) +

    service defines the behavior of a service spec. +provides read-write service +https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status

    +
    +alternativeServices
    + + +[]Kubernetes core/v1.Service + + +
    +(Optional) +

    AlternativeServices defines Alternative Services selector pattern specifier. +can be used for creating Readonly service.

    +
    +template
    + + +Kubernetes core/v1.PodTemplateSpec + + +
    +
    +volumeClaimTemplates
    + + +[]Kubernetes core/v1.PersistentVolumeClaim + + +
    +(Optional) +

    volumeClaimTemplates is a list of claims that pods are allowed to reference. +The ReplicatedStateMachine controller is responsible for mapping network identities to +claims in a way that maintains the identity of a pod. Every claim in +this list must have at least one matching (by name) volumeMount in one +container in the template. A claim in this list takes precedence over +any volumes in the template, with the same name.

    +
    +podManagementPolicy
    + + +Kubernetes apps/v1.PodManagementPolicyType + + +
    +(Optional) +

    podManagementPolicy controls how pods are created during initial scale up, +when replacing pods on nodes, or when scaling down. The default policy is +OrderedReady, where pods are created in increasing order (pod-0, then +pod-1, etc) and the controller will wait until each pod is ready before +continuing. When scaling down, the pods are removed in the opposite order. +The alternative policy is Parallel which will create pods in parallel +to match the desired scale without waiting, and on scale down will delete +all pods at once.

    +
    +updateStrategy
    + + +Kubernetes apps/v1.StatefulSetUpdateStrategy + + +
    +

    updateStrategy indicates the StatefulSetUpdateStrategy that will be +employed to update Pods in the RSM when a revision is made to +Template. +UpdateStrategy.Type will be set to appsv1.OnDeleteStatefulSetStrategyType if MemberUpdateStrategy is not nil

    +
    +roles
    + + +[]ReplicaRole + + +
    +(Optional) +

    Roles, a list of roles defined in the system.

    +
    +roleProbe
    + + +RoleProbe + + +
    +(Optional) +

    RoleProbe provides method to probe role.

    +
    +membershipReconfiguration
    + + +MembershipReconfiguration + + +
    +(Optional) +

    MembershipReconfiguration provides actions to do membership dynamic reconfiguration.

    +
    +memberUpdateStrategy
    + + +MemberUpdateStrategy + + +
    +(Optional) +

    MemberUpdateStrategy, Members(Pods) update strategy. +serial: update Members one by one that guarantee minimum component unavailable time. +Learner -> Follower(with AccessMode=none) -> Follower(with AccessMode=readonly) -> Follower(with AccessMode=readWrite) -> Leader +bestEffortParallel: update Members in parallel that guarantee minimum component un-writable time. +Learner, Follower(minority) in parallel -> Follower(majority) -> Leader, keep majority online all the time. +parallel: force parallel

    +
    +paused
    + +bool + +
    +(Optional) +

    Paused indicates that the rsm is paused, means the reconciliation of this rsm object will be paused.

    +
    +credential
    + + +Credential + + +
    +(Optional) +

    Credential used to connect to DB engine

    +
    +rsmTransformPolicy
    + + +RsmTransformPolicy + + +
    +(Optional) +

    RsmTransformPolicy defines the policy generate sts using rsm. Passed from cluster. +ToSts: rsm transform to statefulSet +ToPod: rsm transform to pod

    +
    +nodeAssignment
    + + +[]NodeAssignment + + +
    +(Optional) +

    NodeAssignment defines the expected assignment of nodes.

    +
    +

    ReplicatedStateMachineStatus +

    +

    +(Appears on:ReplicatedStateMachine) +

    +
    +

    ReplicatedStateMachineStatus defines the observed state of ReplicatedStateMachine

    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    FieldDescription
    +StatefulSetStatus
    + + +Kubernetes apps/v1.StatefulSetStatus + + +
    +

    +(Members of StatefulSetStatus are embedded into this type.) +

    +
    +initReplicas
    + +int32 + +
    +

    InitReplicas is the number of pods(members) when cluster first initialized +it’s set to spec.Replicas at object creation time and never changes

    +
    +readyInitReplicas
    + +int32 + +
    +(Optional) +

    ReadyInitReplicas is the number of pods(members) already in MembersStatus in the cluster initialization stage +will never change once equals to InitReplicas

    +
    +currentGeneration
    + +int64 + +
    +(Optional) +

    CurrentGeneration, if not empty, indicates the version of the RSM used to generate the underlying workload

    +
    +membersStatus
    + + +[]MemberStatus + + +
    +(Optional) +

    members’ status.

    +
    +

    RoleProbe +

    +

    +(Appears on:RSMSpec, ReplicatedStateMachineSpec) +

    +
    +

    RoleProbe defines how to observe role

    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    FieldDescription
    +builtinHandlerName
    + +string + +
    +(Optional) +

    BuiltinHandler specifies the builtin handler name to use to probe the role of the main container. +current available handlers: mysql, postgres, mongodb, redis, etcd, kafka. +use CustomHandler to define your own role probe function if none of them satisfies the requirement.

    +
    +customHandler
    + + +[]Action + + +
    +(Optional) +

    CustomHandler defines the custom way to do role probe. +if the BuiltinHandler satisfies the requirement, use it instead.

    +

    how the actions defined here works:

    +

    Actions will be taken in serial. +after all actions done, the final output should be a single string of the role name defined in spec.Roles +latest BusyBox image will be used if Image not configured +Environment variables can be used in Command:

    +
      +
    • v_KB_RSM_LASTSTDOUT stdout from last action, watch ‘v’ prefixed
    • +
    • KB_RSM_USERNAME username part of credential
    • +
    • KB_RSM_PASSWORD password part of credential
    • +
    +
    +initialDelaySeconds
    + +int32 + +
    +(Optional) +

    Number of seconds after the container has started before role probe has started.

    +
    +timeoutSeconds
    + +int32 + +
    +(Optional) +

    Number of seconds after which the probe times out. +Defaults to 1 second. Minimum value is 1.

    +
    +periodSeconds
    + +int32 + +
    +(Optional) +

    How often (in seconds) to perform the probe. +Default to 2 seconds. Minimum value is 1.

    +
    +successThreshold
    + +int32 + +
    +(Optional) +

    Minimum consecutive successes for the probe to be considered successful after having failed. +Defaults to 1. Minimum value is 1.

    +
    +failureThreshold
    + +int32 + +
    +(Optional) +

    Minimum consecutive failures for the probe to be considered failed after having succeeded. +Defaults to 3. Minimum value is 1.

    +
    +roleUpdateMechanism
    + + +RoleUpdateMechanism + + +
    +(Optional) +

    RoleUpdateMechanism specifies the way how pod role label being updated.

    +
    +

    RoleUpdateMechanism +(string alias)

    +

    +(Appears on:RoleProbe) +

    +
    +

    RoleUpdateMechanism defines the way how pod role label being updated.

    +
    + + + + + + + + + + + + +
    ValueDescription

    "DirectAPIServerEventUpdate"

    "ReadinessProbeEventUpdate"

    +

    RsmTransformPolicy +(string alias)

    +

    +(Appears on:ClusterComponentSpec, ComponentSpec, ReplicatedStateMachineSpec) +

    +
    +

    RsmTransformPolicy defines rsm transform type +ToSts and ToPod is supported

    +
    + + + + + + + + + + + + +
    ValueDescription

    "ToPod"

    "ToSts"

    +

    Generated with gen-crd-api-reference-docs

    diff --git a/hack/docgen/api/gen-api-doc-config.json b/hack/docgen/api/gen-api-doc-config.json index ed8c2a561e9..59180da2265 100644 --- a/hack/docgen/api/gen-api-doc-config.json +++ b/hack/docgen/api/gen-api-doc-config.json @@ -22,6 +22,10 @@ { "typeMatchPrefix": "^k8s\\.io/apimachinery/pkg/util", "docsURLTemplate": "https://pkg.go.dev/k8s.io/apimachinery/pkg/util/{{arrIndex .PackageSegments -1}}#{{.TypeIdentifier}}" + }, + { + "typeMatchPrefix": "^k8s\\.io/apimachinery/pkg/types", + "docsURLTemplate": "https://pkg.go.dev/k8s.io/apimachinery/pkg/types#{{.TypeIdentifier}}" } ], "typeDisplayNamePrefixOverrides": { @@ -31,5 +35,22 @@ "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/": "Kubernetes api extensions ", "k8s.io/apimachinery/pkg/util/": "Kubernetes api utils " }, + "packageGroups": [ + { + "groupName": "cluster", + "packages": ["apps.kubeblocks.io", "workloads.kubeblocks.io"], + "order": 1 + }, + { + "groupName": "backup", + "packages": ["dataprotection.kubeblocks.io", "storage.kubeblocks.io"], + "order": 2 + }, + { + "groupName": "add-on", + "packages": ["extensions.kubeblocks.io"], + "order": 3 + } + ], "markdownDisabled": false } diff --git a/hack/docgen/api/generate.sh b/hack/docgen/api/generate.sh deleted file mode 100755 index c193ea14ffc..00000000000 --- a/hack/docgen/api/generate.sh +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/bash -# -# Copyright (C) 2022-2024 ApeCloud Co., Ltd -# -# 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. - - -set -o errexit -set -o nounset -set -o pipefail - -SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" -PROJECT_DIR=${SCRIPT_DIR%/*/*/*} - -echo "> Generate API docs from $PROJECT_DIR" -go generate "$PROJECT_DIR/apis/..." - diff --git a/hack/docgen/api/main.go b/hack/docgen/api/main.go index 6613e7e5f6b..cbcf302ef16 100644 --- a/hack/docgen/api/main.go +++ b/hack/docgen/api/main.go @@ -27,7 +27,6 @@ import ( "fmt" "html/template" "io" - "net/http" "os" "path/filepath" "reflect" @@ -36,7 +35,6 @@ import ( "strconv" "strings" texttemplate "text/template" - "time" "unicode" "golang.org/x/text/cases" @@ -50,14 +48,11 @@ import ( ) var ( - flConfig = flag.String("config", "", "path to config file") - flAPIDir = flag.String("api-dir", "", "api directory (or import path), point this to pkg/apis") - flTemplateDir = flag.String("template-dir", "template", "path to template/ dir") - - flHTTPAddr = flag.String("http-addr", "", "start an HTTP server on specified addr to view the result (e.g. :8080)") - flOutFile = flag.String("out-file", "", "path to output file to save the result") - - apiOrder = map[string]int{"cluster": 1, "backup": 2, "add-on": 3} + flConfig = flag.String("config", "", "path to config file") + flAPIDir = flag.String("api-dir", "", "api directory (or import path), point this to pkg/apis") + flTemplateDir = flag.String("template-dir", "template", "path to template/ dir") + flOutDir = flag.String("out-dir", "", "path to output file to save the result") + filterPrefixPattern = regexp.MustCompile(`^\+|TODO|FIXME`) ) const ( @@ -82,6 +77,18 @@ type generatorConfig struct { // MarkdownDisabled controls markdown rendering for comment lines. MarkdownDisabled bool `json:"markdownDisabled"` + + // PackageGroups is a list of package groups to be rendered. + PackageGroups []PackageGroup `json:"packageGroups"` +} + +type PackageGroup struct { + // GroupName is the name of the package group. + GroupName string `json:"groupName"` + // Packages is a list of packages to be rendered. + Packages []string `json:"packages"` + // Order is the order of the package group. + Order int `json:"order"` } type externalPackage struct { @@ -113,12 +120,9 @@ func init() { if *flAPIDir == "" { panic("-api-dir not specified") } - if *flHTTPAddr == "" && *flOutFile == "" { + if *flOutDir == "" { panic("-out-file or -http-addr must be specified") } - if *flHTTPAddr != "" && *flOutFile != "" { - panic("only -out-file or -http-addr can be specified") - } if err := resolveTemplateDir(*flTemplateDir); err != nil { panic(err) } @@ -161,14 +165,14 @@ func main() { klog.Fatalf("no API packages found in %s", *flAPIDir) } - apiPackages, err := combineAPIPackages(pkgs) + allAPIPackages, err := combineAPIPackages(pkgs) if err != nil { klog.Fatal(err) } - mkOutput := func() (string, error) { + mkOutput := func(groupName string, groupAPIPakcages []*apiPackage) (string, error) { var b bytes.Buffer - err := render(&b, apiPackages, config) + err := render(&b, groupName, groupAPIPakcages, config) if err != nil { return "", errors.Wrap(err, "failed to render the result") } @@ -178,38 +182,32 @@ func main() { return s, nil } - if *flOutFile != "" { - dir := filepath.Dir(*flOutFile) + for _, pg := range config.PackageGroups { + klog.Infof("using group: %s with packages: %s", pg.GroupName, pg.Packages) + var groupAPIPakcages []*apiPackage + for _, pkg := range allAPIPackages { + for _, groupPkg := range pg.Packages { + if pkg.apiGroup == groupPkg { + groupAPIPakcages = append(groupAPIPakcages, pkg) + } + } + } + + outfile := fmt.Sprintf("%s%s.md", *flOutDir, pg.GroupName) + dir := filepath.Dir(outfile) if err := os.MkdirAll(dir, 0755); err != nil { klog.Fatalf("failed to create dir %s: %v", dir, err) } - s, err := mkOutput() + s, err := mkOutput(pg.GroupName, groupAPIPakcages) if err != nil { klog.Fatalf("failed: %+v", err) } - if err := os.WriteFile(*flOutFile, []byte(s), 0644); err != nil { + if err := os.WriteFile(outfile, []byte(s), 0644); err != nil { klog.Fatalf("failed to write to out file: %v", err) } - klog.Infof("written to %s", *flOutFile) + klog.Infof("written to %s\n", outfile) } - if *flHTTPAddr != "" { - h := func(w http.ResponseWriter, r *http.Request) { - now := time.Now() - defer func() { klog.Infof("request took %v", time.Since(now)) }() - s, err := mkOutput() - if err != nil { - _, _ = fmt.Fprintf(w, "error: %+v", err) - klog.Warningf("failed: %+v", err) - } - if _, err := fmt.Fprint(w, s); err != nil { - klog.Warningf("response write error: %v", err) - } - } - http.HandleFunc("/", h) - klog.Infof("server listening at %s", *flHTTPAddr) - klog.Fatal(http.ListenAndServe(*flHTTPAddr, nil)) - } } // groupName extracts the "//+groupName" meta-comment from the specified @@ -254,7 +252,6 @@ func parseAPIPackages() ([]*types.Package, error) { sort.Strings(pkgNames) var pkgs []*types.Package for _, p := range pkgNames { - klog.Infof("using package=%s", p) pkgs = append(pkgs, scan[p]) } return pkgs, nil @@ -368,7 +365,6 @@ func renderComments(s []string, markdown bool) string { if markdown { doc = string(blackfriday.Run([]byte(doc))) - doc = strings.ReplaceAll(doc, "\n", string(template.HTML("
    "))) doc = strings.ReplaceAll(doc, "{", string(template.HTML("{"))) doc = strings.ReplaceAll(doc, "}", string(template.HTML("}"))) return doc @@ -596,7 +592,7 @@ func visibleTypes(in []*types.Type, c generatorConfig) []*types.Type { func filterCommentTags(comments []string) []string { var out []string for _, v := range comments { - if !strings.HasPrefix(strings.TrimSpace(v), "+") { + if !filterPrefixPattern.MatchString(v) { out = append(out, v) } } @@ -649,14 +645,16 @@ func constantsOfType(t *types.Type, pkg *apiPackage) []*types.Type { return sortTypes(constants) } -func getAPIOrder(filename string) int { - if order, ok := apiOrder[filename]; ok { - return order +func getAPIDocOrder(filename string, pg []PackageGroup) int { + for _, p := range pg { + if filename == p.GroupName { + return p.Order + } } return 1000 } -func render(w io.Writer, pkgs []*apiPackage, config generatorConfig) error { +func render(w io.Writer, groupName string, pkgs []*apiPackage, config generatorConfig) error { references := findTypeReferences(pkgs) typePkgMap := extractTypeToPackageMap(pkgs) @@ -695,12 +693,11 @@ func render(w io.Writer, pkgs []*apiPackage, config generatorConfig) error { return errors.Wrap(err, "parse error") } - apiName := strings.Split(filepath.Base(*flOutFile), ".")[0] - filerOrder := getAPIOrder(apiName) + filerOrder := getAPIDocOrder(groupName, config.PackageGroups) return errors.Wrap(t.ExecuteTemplate(w, "packages", map[string]interface{}{ "packages": pkgs, - "apiName": apiName, + "apiName": groupName, "filerOrder": filerOrder, }), "template execution error") } diff --git a/pkg/client/clientset/versioned/typed/workloads/v1alpha1/workloads_client.go b/pkg/client/clientset/versioned/typed/workloads/v1alpha1/workloads_client.go index a3d2bf03d49..d6a59b1e808 100644 --- a/pkg/client/clientset/versioned/typed/workloads/v1alpha1/workloads_client.go +++ b/pkg/client/clientset/versioned/typed/workloads/v1alpha1/workloads_client.go @@ -31,7 +31,7 @@ type WorkloadsV1alpha1Interface interface { ReplicatedStateMachinesGetter } -// WorkloadsV1alpha1Client is used to interact with features provided by the workloads group. +// WorkloadsV1alpha1Client is used to interact with features provided by the workloads.kubeblocks.io group. type WorkloadsV1alpha1Client struct { restClient rest.Interface } diff --git a/pkg/client/informers/externalversions/generic.go b/pkg/client/informers/externalversions/generic.go index 5e59db02c8d..d937f6a6417 100644 --- a/pkg/client/informers/externalversions/generic.go +++ b/pkg/client/informers/externalversions/generic.go @@ -104,7 +104,7 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource case storagev1alpha1.SchemeGroupVersion.WithResource("storageproviders"): return &genericInformer{resource: resource.GroupResource(), informer: f.Storage().V1alpha1().StorageProviders().Informer()}, nil - // Group=workloads, Version=v1alpha1 + // Group=workloads.kubeblocks.io, Version=v1alpha1 case workloadsv1alpha1.SchemeGroupVersion.WithResource("replicatedstatemachines"): return &genericInformer{resource: resource.GroupResource(), informer: f.Workloads().V1alpha1().ReplicatedStateMachines().Informer()}, nil