# Functions
ComponentPodsAreReady checks if the pods of component are ready.
GetClusterUpRunningPhases returns Cluster running or partially running phases.
GetComponentTerminalPhases return Cluster's component terminal phases.
GetComponentUpRunningPhase returns component running or partially running phases.
GetInstanceTemplateName get the instance template name by instance name.
GetReconfiguringRunningPhases return Cluster running or partially running phases.
No description provided by the author
Resource takes an unqualified resource and returns a Group qualified GroupResource.
# Constants
AbnormalClusterCompPhase indicates the component has more than zero replicas, but there are some failed pods.
AbnormalClusterPhase represents some components are in `Failed` or `Abnormal` phase, indicates that the cluster is in a fragile state and troubleshooting is required.
No description provided by the author
AllPods indicates that accounts will be created for all pods within the component.
No description provided by the author
AnyPods indicates that accounts will be created only on a single pod within the component.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
AvailabilityPolicyNode specifies that resources should be distributed across different nodes within the same zone.
AvailabilityPolicyNone specifies that no specific availability policy is applied.
AvailabilityPolicyZone specifies that resources should be distributed across different availability zones.
AvailablePhase indicates that the object is in an available state.
No description provided by the author
BestEffortParallelStrategy indicates that the replicas are updated in parallel, with the operator making a best-effort attempt to update as many replicas as possible concurrently while maintaining the component's availability.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
ConditionTypeApplyResources the operator start to apply resources to create or change the cluster.
ConditionTypeHaltRecovery describe Halt recovery processing stage.
ConditionTypeProvisioningStarted the operator starts resource provisioning to create or change the cluster.
ConditionTypeReady all components are running.
ConditionTypeReplicasReady all pods of components are ready.
Consensus represents a workload type involving distributed consensus algorithms for coordinated decision-making.
No description provided by the author
CreateByStmt will create account w.r.t.
CreatingClusterCompPhase indicates the component is being created.
CreatingClusterPhase represents all components are in `Creating` phase.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
DedicatedNode means each pod runs on their own dedicated node.
Delete is based on Halt and deletes PVCs.
DeletingClusterCompPhase indicates the component is currently being deleted.
DeletingClusterPhase indicates the cluster is being deleted.
DoNotTerminate will block delete operation.
No description provided by the author
No description provided by the author
No description provided by the author
FailedClusterCompPhase indicates the component has more than zero replicas, but there are some failed pods.
FailedClusterPhase represents all components are in `Failed` phase, indicates that the cluster is unavailable.
FailurePolicyFail means that an error will be reported.
FailurePolicyIgnore means that an error will be ignored but logged.
No description provided by the author
FromFieldRef refers to the value of a specific field in the object.
FromHeadlessServiceRef refers to a headless service within the same namespace as the object.
FromServiceRef refers to a service within the same namespace as the object.
Halt will delete workload resources such as statefulset, deployment workloads but keep PVCs.
HScaleDataClonePolicyCloneVolume indicates that data will be cloned from existing volumes during horizontal scaling.
HScaleDataClonePolicyFromSnapshot indicates that data will be cloned from a snapshot during horizontal scaling.
HScaleDataClonePolicyNone indicates that no data cloning will occur during horizontal scaling.
No description provided by the author
No description provided by the author
No description provided by the author
IssuerKubeBlocks represents certificates that are signed by the KubeBlocks Operator.
IssuerUserProvided indicates that the user has provided their own CA-signed certificates.
No description provided by the author
LowerCases represents the use of lower case letters only.
MaximumAvailability represents a switch policy that aims for maximum availability.
MaximumDataProtection represents a switch policy focused on maximum data protection.
MixedCases represents the use of a mix of both lower and upper case letters.
No description provided by the author
No description provided by the author
MultipleClusterObjectStrategyCombined - the values from all matched components will be combined into a single variable using the specified option.
MultipleClusterObjectStrategyIndividual - each matched component will have its individual variable with its name as the suffix.
No description provided by the author
None implies no access.
No description provided by the author
No description provided by the author
No description provided by the author
Noop indicates that KubeBlocks will not perform any high-availability switching for the components.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
ParallelStrategy indicates that updates are applied simultaneously to all Pods of a Component.
No description provided by the author
No description provided by the author
No description provided by the author
Preferred indicates that the scheduler will try to enforce the anti-affinity rules, but it will not guarantee it.
No description provided by the author
Readonly allows only read operations.
ReadWrite permits both read and write operations.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
ReferToExisting will not create account, but create a secret by copying data from referred secret file.
No description provided by the author
Replication represents a workload type that involves replication, typically used for achieving high availability and fault tolerance.
No description provided by the author
Required indicates that the scheduler must enforce the anti-affinity rules and will not schedule the pods unless the rules are met.
No description provided by the author
No description provided by the author
No description provided by the author
RunningClusterCompPhase indicates the component has more than zero replicas, and all pods are up-to-date and in a 'Running' state.
RunningClusterPhase represents all components are in `Running` phase, indicates that the cluster is functioning properly.
No description provided by the author
SerialStrategy indicates that updates are applied one at a time in a sequential manner.
SharedNode means multiple pods may share the same node.
Stateful represents a workload type where components maintain state, and each instance has a unique identity.
Stateless represents a workload type where components do not maintain state, and instances are interchangeable.
StoppedClusterCompPhase indicates the component has zero replicas, and all pods have been deleted.
StoppedClusterPhase represents all components are in `Stopped` phase, indicates that the cluster has stopped and is not providing any functionality.
StoppingClusterCompPhase indicates the component has zero replicas, and there are pods that are terminating.
StoppingClusterPhase represents at least one component is in `Stopping` phase, indicates that the cluster is in the process of stopping.
No description provided by the author
UnavailablePhase indicates that the object is in an unavailable state.
No description provided by the author
No description provided by the author
UpdatingClusterCompPhase indicates the component has more than zero replicas, and there are no failed pods, it is currently being updated.
UpdatingClusterPhase represents all components are in `Creating`, `Running` or `Updating` phase, and at least one component is in `Creating` or `Updating` phase, indicates that the cluster is undergoing an update.
UpperCases represents the use of upper case letters only.
No description provided by the author
VolumeTypeData indicates a volume designated for storing backup data.
VolumeTypeLog indicates a volume designated for storing logs.
No description provided by the author
WipeOut is based on Delete and wipe out all volume snapshots and snapshot data from backup storage location.
# Variables
AddToScheme adds the types in this group-version to the given scheme.
No description provided by the author
No description provided by the author
No description provided by the author
GroupVersion is group version used to register these objects.
SchemeBuilder is used to add go types to the GroupVersionKind scheme.
SchemeGroupVersion is group version used to register these objects.
No description provided by the author
No description provided by the author
# Structs
Action defines a customizable hook or procedure tailored for different database engines, designed to be invoked at predetermined points within the lifecycle of a Component instance.
No description provided by the author
ClassDefRef is deprecated since v0.9.
Cluster offers a unified management interface for a wide variety of database and storage systems:
- Relational databases: MySQL, PostgreSQL, MariaDB - NoSQL databases: Redis, MongoDB - KV stores: ZooKeeper, etcd - Analytics systems: ElasticSearch, OpenSearch, ClickHouse, Doris, StarRocks, Solr - Message queues: Kafka, Pulsar - Distributed SQL: TiDB, OceanBase - Vector databases: Qdrant, Milvus, Weaviate - Object storage: Minio
KubeBlocks utilizes an abstraction layer to encapsulate the characteristics of these diverse systems.
No description provided by the author
ClusterComponentConfig represents a config with its source bound.
ClusterComponentConfigSource represents the source of a config.
ClusterComponentDefinition defines a Component within a ClusterDefinition but is deprecated and has been replaced by ComponentDefinition.
No description provided by the author
ClusterComponentSpec defines the specification of a Component within a Cluster.
ClusterComponentStatus records Component status.
No description provided by the author
ClusterDefinition defines the topology for databases or storage systems, offering a variety of topological configurations to meet diverse deployment needs and scenarios.
ClusterDefinitionList contains a list of ClusterDefinition.
ClusterDefinitionProbe is deprecated since v0.8.
ClusterDefinitionProbeCMDs is deprecated since v0.8.
ClusterDefinitionProbes is deprecated since v0.8.
ClusterDefinitionSpec defines the desired state of ClusterDefinition.
ClusterDefinitionStatus defines the observed state of ClusterDefinition.
ClusterList contains a list of Cluster.
ClusterNetwork is deprecated since v0.9.
ClusterObjectReference defines information to let you locate the referenced object inside the same Cluster.
ClusterResources is deprecated since v0.9.
ClusterService defines a service that is exposed externally, allowing entities outside the cluster to access it.
ClusterSpec defines the desired state of Cluster.
ClusterStatus defines the observed state of the Cluster.
ClusterStorage is deprecated since v0.9.
ClusterSwitchPolicy defines the switch policy for a Cluster.
ClusterTopology represents the definition for a specific cluster topology.
ClusterTopologyComponent defines a Component within a ClusterTopology.
ClusterTopologyOrders manages the lifecycle of components within a cluster by defining their provisioning, terminating, and updating sequences.
CmdExecutorConfig specifies how to perform creation and deletion statements.
CommandExecutorEnvItem is deprecated since v0.8.
CommandExecutorItem is deprecated since v0.8.
Component is a fundamental building block of a Cluster object.
No description provided by the author
ComponentDefinition serves as a reusable blueprint for creating Components, encapsulating essential static settings such as Component description, Pod templates, configuration file templates, scripts, parameter lists, injected environment variables and their sources, and event handlers.
ComponentDefinitionList contains a list of ComponentDefinition.
No description provided by the author
ComponentDefinitionStatus defines the observed state of ComponentDefinition.
ComponentDefRef is used to select the component and its fields to be referenced.
ComponentLifecycleActions defines a collection of Actions for customizing the behavior of a Component.
ComponentList contains a list of Component.
ComponentRefEnv specifies name and value of an env.
ComponentService defines a service that would be exposed as an inter-component service within a Cluster.
ComponentSpec defines the desired state of Component.
ComponentStatus represents the observed state of a Component within the Cluster.
No description provided by the author
No description provided by the author
No description provided by the author
ComponentValueFrom is deprecated since v0.8.
No description provided by the author
ComponentVarSelector selects a var from a Component.
ComponentVersion is the Schema for the componentversions API.
ComponentVersionCompatibilityRule defines the compatibility between a set of component definitions and a set of releases.
ComponentVersionList contains a list of ComponentVersion.
ComponentVersionRelease represents a release of component instances within a ComponentVersion.
ComponentVersionSpec defines the desired state of ComponentVersion.
ComponentVersionStatus defines the observed state of ComponentVersion.
No description provided by the author
ConfigConstraint manages the parameters across multiple configuration files contained in a single configure template.
ConfigConstraintList contains a list of ConfigConstraints.
ConfigConstraintSpec defines the desired state of ConfigConstraint.
ConfigConstraintStatus represents the observed state of a ConfigConstraint.
ConfigMapRef defines a reference to a ConfigMap.
No description provided by the author
No description provided by the author
Configuration represents the complete set of configurations for a specific Component of a Cluster.
ConfigurationItemDetail corresponds to settings of a configuration template (a ConfigMap).
No description provided by the author
ConfigurationList contains a list of Configuration.
ConfigurationSpec defines the desired state of a Configuration resource.
ConfigurationStatus represents the observed state of a Configuration resource.
ConnectionCredentialAuth specifies the authentication credentials required for accessing an external service.
ConsensusMember is deprecated since v0.7.
ConsensusSetSpec is deprecated since v0.7.
ContainerVars defines the vars that can be referenced from a Container.
CredentialVar represents a variable that retrieves its value either directly from a specified expression or from a source defined in `valueFrom`.
CredentialVars defines the vars that can be referenced from a Credential (SystemAccount).
CredentialVarSelector selects a var from a Credential (SystemAccount).
CustomLabelSpec is deprecated since v0.8.
CustomParametersValidation Defines a list of configuration items with their names, default values, descriptions, types, and constraints.
EnvVar represents a variable present in the env of Pod/Action or the template of config/script.
ExecAction describes an Action that executes a command inside a container.
No description provided by the author
No description provided by the author
GVKResource is deprecated since v0.8.
HorizontalScalePolicy is deprecated since v0.8.
No description provided by the author
No description provided by the author
HostNetworkVars defines the vars that can be referenced from host-network resources.
HostNetworkVarSelector selects a var from host-network resources.
HTTPAction describes an Action that triggers HTTP requests.
InstanceTemplate allows customization of individual replica configurations in a Component.
InstanceUpdateStrategy indicates the strategy that the InstanceSet controller will use to perform updates.
Issuer defines the TLS certificates issuer for the Cluster.
LegacyRenderedTemplateSpec describes the configuration extension for the lazy rendered template.
LifecycleActionHandler describes the implementation of a specific lifecycle action.
No description provided by the author
No description provided by the author
MultipleClusterObjectCombinedOption defines options for handling combined variables.
MultipleClusterObjectOption defines the options for handling multiple cluster objects matched.
MultipleClusterObjectValueFormatFlatten defines the flatten format for the value.
No description provided by the author
PasswordConfig helps provide to customize complexity of password generation pattern.
No description provided by the author
No description provided by the author
PostStartAction is deprecated since v0.8.
No description provided by the author
No description provided by the author
ProvisionPolicy defines the policy details for creating accounts.
ProvisionSecretRef represents the reference to a secret.
ProvisionStatements defines the statements used to create accounts.
No description provided by the author
ReloadOptions defines the mechanisms available for dynamically reloading a process within K8s without requiring a restart.
ReplicaRole represents a role that can be assumed by a component instance.
ReplicasLimit defines the valid range of number of replicas supported.
ReplicationSetSpec is deprecated since v0.7.
ResourceMeta encapsulates metadata and configuration for referencing ConfigMaps and Secrets as volumes.
No description provided by the author
No description provided by the author
RSMSpec is deprecated since v0.8.
No description provided by the author
No description provided by the author
SecretRef defines a reference to a Secret.
No description provided by the author
ServiceDescriptor describes a service provided by external sources.
ServiceDescriptorList contains a list of ServiceDescriptor.
ServiceDescriptorSpec defines the desired state of ServiceDescriptor.
ServiceDescriptorStatus defines the observed state of ServiceDescriptor.
ServicePort is deprecated since v0.8.
No description provided by the author
No description provided by the author
No description provided by the author
ServiceRefDeclaration represents a reference to a service that can be either provided by a KubeBlocks Cluster or an external service.
No description provided by the author
No description provided by the author
ServiceRefVars defines the vars that can be referenced from a ServiceRef.
ServiceRefVarSelector selects a var from a ServiceRefDeclaration.
ServiceSpec is deprecated since v0.8.
ServiceVars defines the vars that can be referenced from a Service.
ServiceVarSelector selects a var from a Service.
ShardingSpec defines how KubeBlocks manage dynamic provisioned shards.
StatefulSetSpec is deprecated since v0.7.
StatelessSetSpec is deprecated since v0.7.
SwitchoverAction is deprecated since v0.8.
SwitchoverSpec is deprecated since v0.8.
No description provided by the author
SystemAccountConfig specifies how to create and delete system accounts.
SystemAccountSpec specifies information to create system accounts.
No description provided by the author
TLSSecretRef defines Secret contains Tls certs.
UserResourceRefs defines references to user-defined Secrets and ConfigMaps.
VarSource represents a source for the value of an EnvVar.
VolumeProtectionSpec is deprecated since v0.9, replaced with ComponentVolume.HighWatermark.
VolumeTypeSpec is deprecated since v0.9, replaced with ComponentVolume.
# Interfaces
StatefulSetWorkload interface +kubebuilder:object:generate=false.
# Type aliases
AccessMode defines the modes of access granted to the SVC.
AccountName defines system account names.
AvailabilityPolicyType defines the type of availability policy to be applied for cluster affinity, influencing how resources are distributed across zones or nodes for high availability and resilience.
BackupStatusUpdateStage defines the stage of backup status update.
BaseBackupType the base backup type, keep synchronized with the BaseBackupType of the data protection API.
BuiltinActionHandlerType defines build-in action handlers provided by Lorry, including:
- `mysql` - `wesql` - `oceanbase` - `redis` - `mongodb` - `etcd` - `postgresql` - `vanilla-postgresql` - `apecloud-postgresql` - `polardbx` - `custom` - `unknown`.
ClusterComponentPhase defines the phase of a cluster component as represented in cluster.status.components.phase field.
ClusterPhase defines the phase of the Cluster within the .status.phase field.
No description provided by the author
ComponentValueFromType specifies the type of component value from which the data is derived.
ConfigurationPhase defines the Configuration FSM phase +enum +kubebuilder:validation:Enum={Creating,Init,Running,Pending,Merged,MergeFailed,FailedAndPause,Upgrading,Deleting,FailedAndRetry,Finished}.
FailurePolicyType specifies the type of failure policy.
HScaleDataClonePolicyType defines the data clone policy to be used during horizontal scaling.
IssuerName defines the name of the TLS certificates issuer.
LetterCase defines the available cases to be used in password generation.
MergedPolicy defines how to merge external imported templates into component templates.
MultipleClusterObjectStrategy defines the strategy for handling multiple cluster objects.
MultipleClusterObjectValueFormat defines the format details for the value.
Phase represents the current status of the ClusterDefinition CR.
PodAntiAffinity defines the pod anti-affinity strategy.
PodAvailabilityPolicy pod availability strategy.
PreConditionType defines the preCondition type of the action execution.
PrometheusScheme defines the protocol of prometheus scrape metrics.
ProvisionPolicyType defines the policy for creating accounts.
ProvisionScope defines the scope of provision within a component.
RerenderResourceType defines the resource requirements for a component.
RoleArbitrator defines how to arbitrate the role of replicas.
SwitchPolicyType defines the types of switch policies that can be applied to a cluster.
TargetPodSelector defines how to select pod(s) to execute an Action.
TenancyType defines the type of tenancy for cluster tenant resources.
TerminationPolicyType defines termination policy types.
UpdateStrategy defines the update strategy for cluster components.
UpgradePolicy defines the policy of reconfiguring.
VarOption defines whether a variable is required or optional.
VolumeType defines the type of volume, specifically distinguishing between volumes used for backup data and those used for logs.
WorkloadType defines the type of workload for the components of the ClusterDefinition.