Documentation
¶
Overview ¶
+k8s:deepcopy-gen=package +groupName=starrocks.com
Package v1 stores the v1 version of the API. +kubebuilder:object:generate=true +groupName=starrocks.com
Index ¶
- Constants
- Variables
- func Register()
- func ValidUpdateStrategy(updateStrategy *appsv1.StatefulSetUpdateStrategy) error
- type AnnotationOperationValue
- type AutoScalerVersion
- type AutoScalingPolicy
- type ComponentPhase
- type ConfigMapInfo
- type ConfigMapReference
- type DRPhase
- type DisasterRecovery
- type DisasterRecoveryStatus
- type HPAPolicy
- type HorizontalScaler
- type MountInfo
- type Phase
- type SecretReference
- type SpecInterface
- type StarRocksBeSpec
- type StarRocksBeStatus
- type StarRocksCluster
- type StarRocksClusterList
- type StarRocksClusterSpec
- type StarRocksClusterStatus
- type StarRocksCnSpec
- type StarRocksCnStatus
- type StarRocksComponentSpec
- func (in *StarRocksComponentSpec) DeepCopy() *StarRocksComponentSpec
- func (in *StarRocksComponentSpec) DeepCopyInto(out *StarRocksComponentSpec)
- func (spec *StarRocksComponentSpec) GetArgs() []string
- func (spec *StarRocksComponentSpec) GetCapabilities() *corev1.Capabilities
- func (spec *StarRocksComponentSpec) GetCommand() []string
- func (spec *StarRocksComponentSpec) GetHostAliases() []corev1.HostAlias
- func (spec *StarRocksComponentSpec) GetInitContainers() []corev1.Container
- func (spec *StarRocksComponentSpec) GetMinReadySeconds() *int32
- func (spec *StarRocksComponentSpec) GetPodManagementPolicy() appsv1.PodManagementPolicyType
- func (spec *StarRocksComponentSpec) GetRunAsNonRoot() (*int64, *int64)
- func (spec *StarRocksComponentSpec) GetSidecars() []corev1.Container
- func (spec *StarRocksComponentSpec) GetSysctls() []corev1.Sysctl
- func (spec *StarRocksComponentSpec) GetTerminationGracePeriodSeconds() *int64
- func (spec *StarRocksComponentSpec) GetUpdateStrategy() *appsv1.StatefulSetUpdateStrategy
- func (spec *StarRocksComponentSpec) IsReadOnlyRootFilesystem() *bool
- type StarRocksComponentStatus
- type StarRocksFeProxySpec
- func (in *StarRocksFeProxySpec) DeepCopy() *StarRocksFeProxySpec
- func (in *StarRocksFeProxySpec) DeepCopyInto(out *StarRocksFeProxySpec)
- func (spec *StarRocksFeProxySpec) GetArgs() []string
- func (spec *StarRocksFeProxySpec) GetCapabilities() *corev1.Capabilities
- func (spec *StarRocksFeProxySpec) GetCommand() []string
- func (spec *StarRocksFeProxySpec) GetHostAliases() []corev1.HostAlias
- func (spec *StarRocksFeProxySpec) GetInitContainers() []corev1.Container
- func (spec *StarRocksFeProxySpec) GetMinReadySeconds() *int32
- func (spec *StarRocksFeProxySpec) GetPodManagementPolicy() appsv1.PodManagementPolicyType
- func (spec *StarRocksFeProxySpec) GetReplicas() *int32
- func (spec *StarRocksFeProxySpec) GetRunAsNonRoot() (*int64, *int64)
- func (spec *StarRocksFeProxySpec) GetSidecars() []corev1.Container
- func (spec *StarRocksFeProxySpec) GetSysctls() []corev1.Sysctl
- func (spec *StarRocksFeProxySpec) GetTerminationGracePeriodSeconds() *int64
- func (spec *StarRocksFeProxySpec) GetUpdateStrategy() *appsv1.StatefulSetUpdateStrategy
- func (spec *StarRocksFeProxySpec) IsReadOnlyRootFilesystem() *bool
- type StarRocksFeProxyStatus
- type StarRocksFeSpec
- type StarRocksFeStatus
- type StarRocksLoadSpec
- func (in *StarRocksLoadSpec) DeepCopy() *StarRocksLoadSpec
- func (in *StarRocksLoadSpec) DeepCopyInto(out *StarRocksLoadSpec)
- func (spec *StarRocksLoadSpec) GetAffinity() *corev1.Affinity
- func (spec *StarRocksLoadSpec) GetAnnotations() map[string]string
- func (spec *StarRocksLoadSpec) GetImage() string
- func (spec *StarRocksLoadSpec) GetImagePullPolicy() corev1.PullPolicy
- func (spec *StarRocksLoadSpec) GetImagePullSecrets() []corev1.LocalObjectReference
- func (spec *StarRocksLoadSpec) GetLifecycle() *corev1.Lifecycle
- func (spec *StarRocksLoadSpec) GetLivenessProbeFailureSeconds() *int32
- func (spec *StarRocksLoadSpec) GetNodeSelector() map[string]string
- func (spec *StarRocksLoadSpec) GetReadinessProbeFailureSeconds() *int32
- func (spec *StarRocksLoadSpec) GetReplicas() *int32
- func (spec *StarRocksLoadSpec) GetSchedulerName() string
- func (spec *StarRocksLoadSpec) GetService() *StarRocksService
- func (spec *StarRocksLoadSpec) GetServiceAccount() string
- func (spec *StarRocksLoadSpec) GetShareProcessNamespace() *bool
- func (spec *StarRocksLoadSpec) GetStartupProbeFailureSeconds() *int32
- func (spec *StarRocksLoadSpec) GetStorageVolumes() []StorageVolume
- func (spec *StarRocksLoadSpec) GetTolerations() []corev1.Toleration
- func (spec *StarRocksLoadSpec) GetTopologySpreadConstraints() []corev1.TopologySpreadConstraint
- type StarRocksProbe
- type StarRocksService
- type StarRocksServicePort
- type StarRocksWarehouse
- type StarRocksWarehouseList
- type StarRocksWarehouseSpec
- type StarRocksWarehouseStatus
- type StorageVolume
- type WarehouseComponentSpec
- type WarehouseComponentStatus
Constants ¶
const ( // ComponentLabelKey is Kubernetes recommended label key, it represents the component within the architecture ComponentLabelKey string = "app.kubernetes.io/component" // OwnerReference represents owner of the object OwnerReference string = "app.starrocks.ownerreference/name" // ComponentResourceHash the component hash ComponentResourceHash string = "app.starrocks.components/hash" )
the labels key
const ( DEFAULT_FE = "fe" DEFAULT_BE = "be" DEFAULT_CN = "cn" DEFAULT_FE_PROXY = "fe-proxy" )
the labels value. default statefulset name
const ( COMPONENT_NAME = "COMPONENT_NAME" FE_SERVICE_NAME = "FE_SERVICE_NAME" )
the env of container
const ( EmptyDir = "emptyDir" HostPath = "hostPath" )
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: "starrocks.com", Version: "v1"} // SchemeBuilder is used to add go types to the GroupVersionKind scheme SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion} // AddToScheme adds the types in this group-version to the given scheme. AddToScheme = SchemeBuilder.AddToScheme )
var ErrHostPathRequired = errors.New("if storageClassName is hostPath, hostPath and hostPath.path is required")
var (
Scheme = runtime.NewScheme()
)
Functions ¶
func ValidUpdateStrategy ¶ added in v1.9.9
func ValidUpdateStrategy(updateStrategy *appsv1.StatefulSetUpdateStrategy) error
Types ¶
type AnnotationOperationValue ¶
type AnnotationOperationValue string
AnnotationOperationValue present the operation for fe, cn, be.
type AutoScalerVersion ¶
type AutoScalerVersion string
const ( // AutoScalerV1 the cn service use v1 autoscaler. Reference to https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/ AutoScalerV1 AutoScalerVersion = "v1" // AutoScalerV2Beta2 the cn service use v2beta2. Reference to https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/ AutoScalerV2Beta2 AutoScalerVersion = "v2beta2" // AutoScalerV2 the cn service use v2. Reference to https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/ AutoScalerV2 AutoScalerVersion = "v2" )
func (AutoScalerVersion) Complete ¶ added in v1.8.1
func (version AutoScalerVersion) Complete(major, minor string) AutoScalerVersion
Complete completes the default value of AutoScalerVersion
func (AutoScalerVersion) CreateEmptyHPA ¶ added in v1.9.0
func (version AutoScalerVersion) CreateEmptyHPA(major, minor string) client.Object
CreateEmptyHPA create an empty HPA object based on the version information
type AutoScalingPolicy ¶
type AutoScalingPolicy struct { // the policy of autoscaling. operator use autoscaling v2. HPAPolicy *HPAPolicy `json:"hpaPolicy,omitempty"` // version represents the autoscaler version for cn service. only support v1,v2beta2,v2 // +optional Version AutoScalerVersion `json:"version,omitempty"` // MinReplicas is the lower limit for the number of replicas to which the autoscaler // can scale down. It defaults to 1 pod. // +optional MinReplicas *int32 `json:"minReplicas,omitempty"` // MaxReplicas is the upper limit for the number of pods that can be set by the autoscaler; // cannot be smaller than MinReplicas. MaxReplicas int32 `json:"maxReplicas"` }
AutoScalingPolicy defines the auto scale
func (*AutoScalingPolicy) DeepCopy ¶
func (in *AutoScalingPolicy) DeepCopy() *AutoScalingPolicy
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AutoScalingPolicy.
func (*AutoScalingPolicy) DeepCopyInto ¶
func (in *AutoScalingPolicy) DeepCopyInto(out *AutoScalingPolicy)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ComponentPhase ¶ added in v1.9.0
type ComponentPhase string
ComponentPhase represent the component phase. e.g. 1. StarRocksCluster contains three components: FE, CN, BE. 2. StarRocksWarehouse reuse the CN component. The possible value for component phase are: reconciling, failed, running.
const ( // ComponentReconciling the starrocks component is reconciling ComponentReconciling ComponentPhase = "reconciling" // ComponentFailed the pod of component is failed ComponentFailed ComponentPhase = "failed" // ComponentRunning all components runs available. ComponentRunning ComponentPhase = "running" )
type ConfigMapInfo ¶
type ConfigMapInfo struct { // the config info for start progress. ConfigMapName string `json:"configMapName,omitempty"` // the config response key in configmap. ResolveKey string `json:"resolveKey,omitempty"` }
func (*ConfigMapInfo) DeepCopy ¶
func (in *ConfigMapInfo) DeepCopy() *ConfigMapInfo
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigMapInfo.
func (*ConfigMapInfo) DeepCopyInto ¶
func (in *ConfigMapInfo) DeepCopyInto(out *ConfigMapInfo)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ConfigMapReference ¶ added in v1.7.0
type ConfigMapReference MountInfo
func (*ConfigMapReference) DeepCopy ¶ added in v1.7.0
func (in *ConfigMapReference) DeepCopy() *ConfigMapReference
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigMapReference.
func (*ConfigMapReference) DeepCopyInto ¶ added in v1.7.0
func (in *ConfigMapReference) DeepCopyInto(out *ConfigMapReference)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DisasterRecovery ¶ added in v1.10.0
type DisasterRecovery struct { // Enabled is used to determine whether to enter disaster recovery mode. Enabled bool `json:"enabled,omitempty"` // Generation records the generation of disaster recovery. If you want to trigger disaster recovery, you should // increase the generation. Generation int64 `json:"generation,omitempty"` }
DisasterRecovery is used to determine whether to enter disaster recovery mode.
func (*DisasterRecovery) DeepCopy ¶ added in v1.10.0
func (in *DisasterRecovery) DeepCopy() *DisasterRecovery
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DisasterRecovery.
func (*DisasterRecovery) DeepCopyInto ¶ added in v1.10.0
func (in *DisasterRecovery) DeepCopyInto(out *DisasterRecovery)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DisasterRecoveryStatus ¶ added in v1.10.0
type DisasterRecoveryStatus struct { // the available phase include: todo, doing, done Phase DRPhase `json:"phase,omitempty"` // the reason of disaster recovery. Reason string `json:"reason,omitempty"` // the unix time of starting disaster recovery. StartTimestamp int64 `json:"startTimestamp,omitempty"` // the unix time of ending disaster recovery. EndTimestamp int64 `json:"endTimestamp,omitempty"` // the observed generation of disaster recovery. // If the observed generation is less than the generation, it will trigger disaster recovery. ObservedGeneration int64 `json:"observedGeneration,omitempty"` }
DisasterRecoveryStatus represents the status of disaster recovery. Note: you should create a new instance of DisasterRecoveryStatus by NewDisasterRecoveryStatus.
func NewDisasterRecoveryStatus ¶ added in v1.10.0
func NewDisasterRecoveryStatus(generation int64) *DisasterRecoveryStatus
NewDisasterRecoveryStatus creates a new disaster recovery status which the phase is todo.
func (*DisasterRecoveryStatus) DeepCopy ¶ added in v1.10.0
func (in *DisasterRecoveryStatus) DeepCopy() *DisasterRecoveryStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DisasterRecoveryStatus.
func (*DisasterRecoveryStatus) DeepCopyInto ¶ added in v1.10.0
func (in *DisasterRecoveryStatus) DeepCopyInto(out *DisasterRecoveryStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type HPAPolicy ¶
type HPAPolicy struct { // +optional // Metrics specifies how to scale based on a single metric // the struct copy from k8s.io/api/autoscaling/v2beta2/types.go. the redundancy code will hide the restriction about // HorizontalPodAutoscaler version and kubernetes releases matching issue. // the splice will have unsafe.Pointer convert, so be careful to edit the struct fields. Metrics []autoscalingv2beta2.MetricSpec `json:"metrics,omitempty"` // +optional // HorizontalPodAutoscalerBehavior configures the scaling behavior of the target. // the struct copy from k8s.io/api/autoscaling/v2beta2/types.go. the redundancy code will hide the restriction about // HorizontalPodAutoscaler version and kubernetes releases matching issue. // the Behavior *autoscalingv2beta2.HorizontalPodAutoscalerBehavior `json:"behavior,omitempty"` }
func (*HPAPolicy) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HPAPolicy.
func (*HPAPolicy) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type HorizontalScaler ¶
type HorizontalScaler struct { // the horizontal scaler name Name string `json:"name,omitempty"` // the horizontal version. Version AutoScalerVersion `json:"version,omitempty"` }
func (*HorizontalScaler) DeepCopy ¶
func (in *HorizontalScaler) DeepCopy() *HorizontalScaler
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HorizontalScaler.
func (*HorizontalScaler) DeepCopyInto ¶
func (in *HorizontalScaler) DeepCopyInto(out *HorizontalScaler)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type MountInfo ¶ added in v1.7.0
type MountInfo struct { // This must match the Name of a ConfigMap or Secret in the same namespace, and // the length of name must not more than 50 characters. Name string `json:"name,omitempty"` // Path within the container at which the volume should be mounted. Must // not contain ':'. MountPath string `json:"mountPath,omitempty"` // SubPath within the volume from which the container's volume should be mounted. // Defaults to "" (volume's root). // +optional SubPath string `json:"subPath,omitempty"` }
MountInfo The reason why we do not support defaultMode is that we use hash.HashObject to calculate the actual volume name. This volume name is used in pod template of statefulset, and if this MountInfo type has been changed, the volume name will be changed too, and that will make pods restart. The default mode is 0644, and in order to support to set permission information for a configMap or secret, we add should specify the subPath and specify a command or args in the container. And It will be set 0755.
func (*MountInfo) DeepCopy ¶ added in v1.7.0
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MountInfo.
func (*MountInfo) DeepCopyInto ¶ added in v1.7.0
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Phase ¶ added in v1.9.0
type Phase string
Phase is defined under status, e.g. 1. StarRocksClusterStatus.Phase represents the phase of starrocks cluster. 2. StarRocksWarehouseStatus.Phase represents the phase of starrocks warehouse. The possible value for cluster phase are: running, failed, pending, deleting.
type SecretReference ¶ added in v1.7.0
type SecretReference MountInfo
func (*SecretReference) DeepCopy ¶ added in v1.7.0
func (in *SecretReference) DeepCopy() *SecretReference
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecretReference.
func (*SecretReference) DeepCopyInto ¶ added in v1.7.0
func (in *SecretReference) DeepCopyInto(out *SecretReference)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SpecInterface ¶ added in v1.7.0
type SpecInterface interface { // GetHostAliases returns the host aliases configuration for the pod. Host aliases allow adding entries to // the pod's /etc/hosts file to configure custom host-to-IP mappings. GetHostAliases() []corev1.HostAlias // GetRunAsNonRoot returns the user ID and group ID to run the container as non-root. // Returns (*uid, *gid) where nil means use container defaults. GetRunAsNonRoot() (*int64, *int64) // GetTerminationGracePeriodSeconds returns the grace period in seconds for pod termination. // This is how long to wait for the pod to terminate gracefully before forcefully killing it. GetTerminationGracePeriodSeconds() *int64 // GetCapabilities returns the Linux capabilities configuration for the container. // Capabilities allow granting specific privileges to processes. GetCapabilities() *corev1.Capabilities // GetSidecars returns the list of sidecar containers to add to the pod. // Sidecars run alongside the main container to provide additional functionality. GetSidecars() []corev1.Container // GetInitContainers returns the list of init containers to run before the main containers. // Init containers run to completion in order, before the main containers start. GetInitContainers() []corev1.Container // IsReadOnlyRootFilesystem returns whether the container's root filesystem should be read-only. // A read-only root filesystem prevents modifications to improve security. IsReadOnlyRootFilesystem() *bool // GetSysctls returns the sysctl parameters to set for the container. // Sysctls allow configuring kernel parameters at runtime. GetSysctls() []corev1.Sysctl // GetCommand returns the command to run in the container. // This overrides the container image's default entrypoint. GetCommand() []string // GetArgs returns the arguments to pass to the container command. // These are the arguments passed to either the default entrypoint or GetCommand(). GetArgs() []string // GetUpdateStrategy returns the update strategy for the StatefulSet. // This controls how pods are replaced during updates. GetUpdateStrategy() *appsv1.StatefulSetUpdateStrategy // GetMinReadySeconds returns the 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. GetMinReadySeconds() *int32 GetPodManagementPolicy() appsv1.PodManagementPolicyType // contains filtered or unexported methods }
SpecInterface defines the common interface that must be implemented by all StarRocks component specs (FE, BE, CN, FE Proxy). It provides methods to configure pod and container settings like security context, lifecycle hooks, networking, and storage. All components including StarRocksFeSpec, StarRocksBeSpec, StarRocksCnSpec, StarRocksFeProxySpec have implemented the SpecInterface. If a method has the same implementation, we will implement in StarRocksLoadSpec which implements the loadInterface interface. +kubebuilder:object:generate=false
type StarRocksBeSpec ¶
type StarRocksBeSpec struct { StarRocksComponentSpec `json:",inline"` // +optional // beEnvVars is a slice of environment variables that are added to the pods, the default is empty. BeEnvVars []corev1.EnvVar `json:"beEnvVars,omitempty"` }
StarRocksBeSpec defines the desired state of be.
func (*StarRocksBeSpec) DeepCopy ¶
func (in *StarRocksBeSpec) DeepCopy() *StarRocksBeSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksBeSpec.
func (*StarRocksBeSpec) DeepCopyInto ¶
func (in *StarRocksBeSpec) DeepCopyInto(out *StarRocksBeSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*StarRocksBeSpec) GetReplicas ¶ added in v1.7.0
func (spec *StarRocksBeSpec) GetReplicas() *int32
type StarRocksBeStatus ¶
type StarRocksBeStatus struct {
StarRocksComponentStatus `json:",inline"`
}
StarRocksBeStatus represents the status of starrocks be.
func (*StarRocksBeStatus) DeepCopy ¶
func (in *StarRocksBeStatus) DeepCopy() *StarRocksBeStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksBeStatus.
func (*StarRocksBeStatus) DeepCopyInto ¶
func (in *StarRocksBeStatus) DeepCopyInto(out *StarRocksBeStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StarRocksCluster ¶
type StarRocksCluster struct { metav1.TypeMeta `json:",inline"` // +k8s:openapi-gen=false metav1.ObjectMeta `json:"metadata,omitempty"` // Specification of the desired state of the starrocks cluster. Spec StarRocksClusterSpec `json:"spec,omitempty"` // Most recent observed status of the starrocks cluster Status StarRocksClusterStatus `json:"status,omitempty"` }
StarRocksCluster defines a starrocks cluster deployment. +kubebuilder:object:root=true +kubebuilder:metadata:annotations="version=v1.11.2" +kubebuilder:resource:shortName=src +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:subresource:status +kubebuilder:subresource:scale:specpath=.spec.starRocksCnSpec.replicas,statuspath=.status.starRocksCnStatus.replicas,selectorpath=.status.starRocksCnStatus.selector +kubebuilder:printcolumn:name="Phase",type=string,JSONPath=`.status.phase` +kubebuilder:printcolumn:name="FeStatus",type=string,JSONPath=`.status.starRocksFeStatus.phase` +kubebuilder:printcolumn:name="BeStatus",type=string,JSONPath=`.status.starRocksBeStatus.phase` +kubebuilder:printcolumn:name="CnStatus",type=string,JSONPath=`.status.starRocksCnStatus.phase` +kubebuilder:printcolumn:name="FeProxyStatus",type=string,JSONPath=`.status.starRocksFeProxyStatus.phase` +kubebuilder:storageversion +k8s:openapi-gen=true +genclient
func (*StarRocksCluster) DeepCopy ¶
func (in *StarRocksCluster) DeepCopy() *StarRocksCluster
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksCluster.
func (*StarRocksCluster) DeepCopyInto ¶
func (in *StarRocksCluster) DeepCopyInto(out *StarRocksCluster)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*StarRocksCluster) DeepCopyObject ¶
func (in *StarRocksCluster) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type StarRocksClusterList ¶
type StarRocksClusterList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []StarRocksCluster `json:"items"` }
StarRocksClusterList contains a list of StarRocksCluster +kubebuilder:object:root=true +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +k8s:openapi-gen=true
func (*StarRocksClusterList) DeepCopy ¶
func (in *StarRocksClusterList) DeepCopy() *StarRocksClusterList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksClusterList.
func (*StarRocksClusterList) DeepCopyInto ¶
func (in *StarRocksClusterList) DeepCopyInto(out *StarRocksClusterList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*StarRocksClusterList) DeepCopyObject ¶
func (in *StarRocksClusterList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type StarRocksClusterSpec ¶
type StarRocksClusterSpec struct { // Specify a Service Account for starRocksCluster use k8s cluster. // +optional // Deprecated: component use serviceAccount in own's field. ServiceAccount string `json:"serviceAccount,omitempty"` // StarRocksFeSpec define fe configuration for start fe service. StarRocksFeSpec *StarRocksFeSpec `json:"starRocksFeSpec,omitempty"` // StarRocksBeSpec define be configuration for start be service. StarRocksBeSpec *StarRocksBeSpec `json:"starRocksBeSpec,omitempty"` // StarRocksCnSpec define cn configuration for start cn service. StarRocksCnSpec *StarRocksCnSpec `json:"starRocksCnSpec,omitempty"` // StarRocksLoadSpec define a proxy for fe. StarRocksFeProxySpec *StarRocksFeProxySpec `json:"starRocksFeProxySpec,omitempty"` // +optional // DisasterRecovery is used to determine whether to enter disaster recovery mode. DisasterRecovery *DisasterRecovery `json:"disasterRecovery,omitempty"` }
StarRocksClusterSpec defines the desired state of StarRocksCluster
func (*StarRocksClusterSpec) DeepCopy ¶
func (in *StarRocksClusterSpec) DeepCopy() *StarRocksClusterSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksClusterSpec.
func (*StarRocksClusterSpec) DeepCopyInto ¶
func (in *StarRocksClusterSpec) DeepCopyInto(out *StarRocksClusterSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StarRocksClusterStatus ¶
type StarRocksClusterStatus struct { // Represents the state of cluster. the possible value are: running, failed, pending Phase Phase `json:"phase"` // Reason represents the errors when calling sub-controllers Reason string `json:"reason,omitempty"` // Represents the status of fe. the status have running, failed and creating pods. StarRocksFeStatus *StarRocksFeStatus `json:"starRocksFeStatus,omitempty"` // Represents the status of be. the status have running, failed and creating pods. StarRocksBeStatus *StarRocksBeStatus `json:"starRocksBeStatus,omitempty"` // Represents the status of cn. the status have running, failed and creating pods. StarRocksCnStatus *StarRocksCnStatus `json:"starRocksCnStatus,omitempty"` // Represents the status of fe proxy. the status have running, failed and creating pods. StarRocksFeProxyStatus *StarRocksFeProxyStatus `json:"starRocksFeProxyStatus,omitempty"` // +optional // DisasterRecoveryStatus represents the status of disaster recovery. DisasterRecoveryStatus *DisasterRecoveryStatus `json:"disasterRecoveryStatus,omitempty"` }
StarRocksClusterStatus defines the observed state of StarRocksCluster.
func (*StarRocksClusterStatus) DeepCopy ¶
func (in *StarRocksClusterStatus) DeepCopy() *StarRocksClusterStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksClusterStatus.
func (*StarRocksClusterStatus) DeepCopyInto ¶
func (in *StarRocksClusterStatus) DeepCopyInto(out *StarRocksClusterStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StarRocksCnSpec ¶
type StarRocksCnSpec struct { StarRocksComponentSpec `json:",inline"` // +optional // cnEnvVars is a slice of environment variables that are added to the pods, the default is empty. CnEnvVars []corev1.EnvVar `json:"cnEnvVars,omitempty"` // AutoScalingPolicy auto scaling strategy AutoScalingPolicy *AutoScalingPolicy `json:"autoScalingPolicy,omitempty"` }
StarRocksCnSpec defines the desired state of cn.
func (*StarRocksCnSpec) DeepCopy ¶
func (in *StarRocksCnSpec) DeepCopy() *StarRocksCnSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksCnSpec.
func (*StarRocksCnSpec) DeepCopyInto ¶
func (in *StarRocksCnSpec) DeepCopyInto(out *StarRocksCnSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*StarRocksCnSpec) GetReplicas ¶ added in v1.7.0
func (spec *StarRocksCnSpec) GetReplicas() *int32
type StarRocksCnStatus ¶
type StarRocksCnStatus struct { StarRocksComponentStatus `json:",inline"` // The policy name of autoScale. // Deprecated HpaName string `json:"hpaName,omitempty"` // HorizontalAutoscaler have the autoscaler information. HorizontalScaler HorizontalScaler `json:"horizontalScaler,omitempty"` // Replicas is the total number of non-terminated CN pods targeted. Replicas int32 `json:"replicas,omitempty"` // Selector for CN pods. The HPA will use this selector to know which pods to monitor. Selector string `json:"selector,omitempty"` }
StarRocksCnStatus represents the status of starrocks cn.
func (*StarRocksCnStatus) DeepCopy ¶
func (in *StarRocksCnStatus) DeepCopy() *StarRocksCnStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksCnStatus.
func (*StarRocksCnStatus) DeepCopyInto ¶
func (in *StarRocksCnStatus) DeepCopyInto(out *StarRocksCnStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StarRocksComponentSpec ¶ added in v1.7.0
type StarRocksComponentSpec struct { StarRocksLoadSpec `json:",inline"` // RunAsNonRoot is used to determine whether to run starrocks as a normal user. // If RunAsNonRoot is true, operator will set RunAsUser and RunAsGroup to 1000 in securityContext. // default: nil RunAsNonRoot *bool `json:"runAsNonRoot,omitempty"` // refer to https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-capabilities-for-a-container // grant certain privileges to a process without granting all the privileges of the root user // +optional Capabilities *corev1.Capabilities `json:"capabilities,omitempty"` // the reference for configMap which allow users to mount any files to container. // +optional ConfigMaps []ConfigMapReference `json:"configMaps,omitempty"` // the reference for secrets. // +optional Secrets []SecretReference `json:"secrets,omitempty"` // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts // file if specified. This is only valid for non-hostNetwork pods. // +optional HostAliases []corev1.HostAlias `json:"hostAliases,omitempty"` // TerminationGracePeriodSeconds defines duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. // Value must be non-negative integer. The value zero indicates stop immediately via // the kill signal (no opportunity to shut down). // If this value is nil, the default grace period will be used instead. // 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. // Defaults to 120 seconds. // +optional TerminationGracePeriodSeconds *int64 `json:"terminationGracePeriodSeconds,omitempty"` // Sidecars is an optional list of containers that are run in the same pod as the starrocks component. // You can use this field to launch helper containers that provide additional functionality to the main container. // See https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#Container for how to configure a container. // +optional Sidecars []corev1.Container `json:"sidecars,omitempty"` // InitContainers is an optional list of containers that are run in the same pod as the starrocks component. // You can use this field to launch helper containers that run before the main container starts. // See https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#Container for how to configure a container. InitContainers []corev1.Container `json:"initContainers,omitempty"` // Entrypoint array. Not executed within a shell. // If this is not provided, it will use default entrypoint for different components: // 1. For FE, it will use /opt/starrocks/fe_entrypoint.sh as the entrypoint. // 2. For BE, it will use /opt/starrocks/be_entrypoint.sh as the entrypoint. // 3. For CN, it will use /opt/starrocks/cn_entrypoint.sh as the entrypoint. // More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell // +optional Command []string `json:"command,omitempty"` // Arguments to the entrypoint. // If this is not provided, it will use $(FE_SERVICE_NAME) for all components. // Variable references $(VAR_NAME) are expanded using the container's environment. 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. Cannot be updated. // More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell // +optional Args []string `json:"args,omitempty"` // StarRocksCluster use StatefulSet to deploy FE/BE/CN components. // UpdateStrategy indicates the StatefulSetUpdateStrategy that will be // employed to update Pods in the StatefulSet when a revision is made to // Template. See https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/#rolling-updates for more details. // Note: The maxUnavailable field is in Alpha stage and it is honored only by API servers that are running with the // MaxUnavailableStatefulSet feature gate enabled. // +optional UpdateStrategy *appsv1.StatefulSetUpdateStrategy `json:"updateStrategy,omitempty"` // Whether this container has a read-only root filesystem. // Default is false. // Note that: // 1. This field cannot be set when spec.os.name is windows. // 2. The FE/BE/CN container should support read-only root filesystem. The newest version of FE/BE/CN is 3.3.6, // and does not support read-only root filesystem // +optional ReadOnlyRootFilesystem *bool `json:"readOnlyRootFilesystem,omitempty" protobuf:"varint,6,opt,name=readOnlyRootFilesystem"` // Sysctls defines a list of namespaced sysctls for the podSecurityContext.sysctls // See https://kubernetes.io/docs/tasks/administer-cluster/sysctl-cluster/ for more details. Sysctls []corev1.Sysctl `json:"sysctls,omitempty"` // PersistentVolumeClaimRetentionPolicy specifies the retention policy for PersistentVolumeClaims associated with the component. // The WhenDeleted field is supported for all components, and it determines whether to delete PVCs when the StatefulSet is deleted. // The WhenScaled field is only supported for the CN component. //nolint:lll PersistentVolumeClaimRetentionPolicy *appsv1.StatefulSetPersistentVolumeClaimRetentionPolicy `json:"persistentVolumeClaimRetentionPolicy,omitempty"` // MinReadySeconds specifies the 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). // +optional MinReadySeconds *int32 `json:"minReadySeconds,omitempty"` // podManagementPolicy controls how pods are created during initial scale up, when replacing pods on nodes, or when scaling down. // The default policy is Parallel which is not the same as statefulset's default policy which maybe a not a good choice // to use a different default value. // +optional PodManagementPolicy appsv1.PodManagementPolicyType `json:"podManagementPolicy,omitempty"` }
StarRocksComponentSpec defines the shared specification for all StarRocks components except FE Proxy
func (*StarRocksComponentSpec) DeepCopy ¶ added in v1.7.0
func (in *StarRocksComponentSpec) DeepCopy() *StarRocksComponentSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksComponentSpec.
func (*StarRocksComponentSpec) DeepCopyInto ¶ added in v1.7.0
func (in *StarRocksComponentSpec) DeepCopyInto(out *StarRocksComponentSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*StarRocksComponentSpec) GetArgs ¶ added in v1.9.6
func (spec *StarRocksComponentSpec) GetArgs() []string
func (*StarRocksComponentSpec) GetCapabilities ¶ added in v1.9.1
func (spec *StarRocksComponentSpec) GetCapabilities() *corev1.Capabilities
func (*StarRocksComponentSpec) GetCommand ¶ added in v1.9.6
func (spec *StarRocksComponentSpec) GetCommand() []string
func (*StarRocksComponentSpec) GetHostAliases ¶ added in v1.7.0
func (spec *StarRocksComponentSpec) GetHostAliases() []corev1.HostAlias
func (*StarRocksComponentSpec) GetInitContainers ¶ added in v1.9.5
func (spec *StarRocksComponentSpec) GetInitContainers() []corev1.Container
func (*StarRocksComponentSpec) GetMinReadySeconds ¶ added in v1.11.1
func (spec *StarRocksComponentSpec) GetMinReadySeconds() *int32
func (*StarRocksComponentSpec) GetPodManagementPolicy ¶ added in v1.11.2
func (spec *StarRocksComponentSpec) GetPodManagementPolicy() appsv1.PodManagementPolicyType
func (*StarRocksComponentSpec) GetRunAsNonRoot ¶ added in v1.8.0
func (spec *StarRocksComponentSpec) GetRunAsNonRoot() (*int64, *int64)
func (*StarRocksComponentSpec) GetSidecars ¶ added in v1.9.5
func (spec *StarRocksComponentSpec) GetSidecars() []corev1.Container
func (*StarRocksComponentSpec) GetSysctls ¶ added in v1.10.2
func (spec *StarRocksComponentSpec) GetSysctls() []corev1.Sysctl
func (*StarRocksComponentSpec) GetTerminationGracePeriodSeconds ¶ added in v1.8.4
func (spec *StarRocksComponentSpec) GetTerminationGracePeriodSeconds() *int64
func (*StarRocksComponentSpec) GetUpdateStrategy ¶ added in v1.9.9
func (spec *StarRocksComponentSpec) GetUpdateStrategy() *appsv1.StatefulSetUpdateStrategy
func (*StarRocksComponentSpec) IsReadOnlyRootFilesystem ¶ added in v1.9.9
func (spec *StarRocksComponentSpec) IsReadOnlyRootFilesystem() *bool
type StarRocksComponentStatus ¶ added in v1.7.0
type StarRocksComponentStatus struct { // the name of fe service exposed for user. ServiceName string `json:"serviceName,omitempty"` // FailedInstances failed pod names. FailedInstances []string `json:"failedInstances,omitempty"` // CreatingInstances in creating pod names. CreatingInstances []string `json:"creatingInstances,omitempty"` // RunningInstances in running status pod names. RunningInstances []string `json:"runningInstances,omitempty"` // ResourceNames the statefulset names of fe. ResourceNames []string `json:"resourceNames,omitempty"` // Phase the value from all pods of component status. If component have one failed pod phase=failed, // also if fe have one creating pod phase=creating, also if component all running phase=running, others unknown. Phase ComponentPhase `json:"phase"` // Reason represents the reason of not running. Reason string `json:"reason,omitempty"` }
StarRocksComponentStatus represents the status of a starrocks component.
func (*StarRocksComponentStatus) DeepCopy ¶ added in v1.7.0
func (in *StarRocksComponentStatus) DeepCopy() *StarRocksComponentStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksComponentStatus.
func (*StarRocksComponentStatus) DeepCopyInto ¶ added in v1.7.0
func (in *StarRocksComponentStatus) DeepCopyInto(out *StarRocksComponentStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StarRocksFeProxySpec ¶ added in v1.8.0
type StarRocksFeProxySpec struct { StarRocksLoadSpec `json:",inline"` Resolver string `json:"resolver,omitempty"` }
StarRocksFeProxySpec defines the specification for FE Proxy Note: it includes StarRocksLoadSpec, not StarRocksComponentSpec
func (*StarRocksFeProxySpec) DeepCopy ¶ added in v1.8.0
func (in *StarRocksFeProxySpec) DeepCopy() *StarRocksFeProxySpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksFeProxySpec.
func (*StarRocksFeProxySpec) DeepCopyInto ¶ added in v1.8.0
func (in *StarRocksFeProxySpec) DeepCopyInto(out *StarRocksFeProxySpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*StarRocksFeProxySpec) GetArgs ¶ added in v1.9.6
func (spec *StarRocksFeProxySpec) GetArgs() []string
GetArgs fe proxy does not have field args
func (*StarRocksFeProxySpec) GetCapabilities ¶ added in v1.9.1
func (spec *StarRocksFeProxySpec) GetCapabilities() *corev1.Capabilities
GetCapabilities fe proxy does not have field Capabilities, the reason why implementing this method is that StarRocksFeProxySpec needs to implement SpecInterface interface
func (*StarRocksFeProxySpec) GetCommand ¶ added in v1.9.6
func (spec *StarRocksFeProxySpec) GetCommand() []string
GetCommand fe proxy does not have field command, the reason why implementing this method is that StarRocksFeProxySpec needs to implement SpecInterface interface
func (*StarRocksFeProxySpec) GetHostAliases ¶ added in v1.8.0
func (spec *StarRocksFeProxySpec) GetHostAliases() []corev1.HostAlias
GetHostAliases fe proxy does not have field HostAliases, the reason why implementing this method is that StarRocksFeProxySpec needs to implement SpecInterface interface
func (*StarRocksFeProxySpec) GetInitContainers ¶ added in v1.9.5
func (spec *StarRocksFeProxySpec) GetInitContainers() []corev1.Container
GetInitContainers fe proxy does not have field InitContainers, the reason why implementing this method is that StarRocksFeProxySpec needs to implement SpecInterface interface
func (*StarRocksFeProxySpec) GetMinReadySeconds ¶ added in v1.11.1
func (spec *StarRocksFeProxySpec) GetMinReadySeconds() *int32
GetMinReadySeconds fe proxy does not have field MinReadySeconds, the reason why implementing this method is that StarRocksFeProxySpec needs to implement SpecInterface interface
func (*StarRocksFeProxySpec) GetPodManagementPolicy ¶ added in v1.11.2
func (spec *StarRocksFeProxySpec) GetPodManagementPolicy() appsv1.PodManagementPolicyType
GetPodManagementPolicy fe proxy does not have field PodManagementPolicy, the reason why implementing this method is that StarRocksFeProxySpec needs to implement SpecInterface interface
func (*StarRocksFeProxySpec) GetReplicas ¶ added in v1.8.0
func (spec *StarRocksFeProxySpec) GetReplicas() *int32
func (*StarRocksFeProxySpec) GetRunAsNonRoot ¶ added in v1.8.0
func (spec *StarRocksFeProxySpec) GetRunAsNonRoot() (*int64, *int64)
GetRunAsNonRoot fe proxy does not have field RunAsNonRoot, the reason why implementing this method is that StarRocksFeProxySpec needs to implement SpecInterface interface
func (*StarRocksFeProxySpec) GetSidecars ¶ added in v1.9.5
func (spec *StarRocksFeProxySpec) GetSidecars() []corev1.Container
GetSidecars fe proxy does not have field Sidecars, the reason why implementing this method is that StarRocksFeProxySpec needs to implement SpecInterface interface
func (*StarRocksFeProxySpec) GetSysctls ¶ added in v1.10.2
func (spec *StarRocksFeProxySpec) GetSysctls() []corev1.Sysctl
GetSysctls fe proxy does not have field Sysctls, the reason why implementing this method is that StarRocksFeProxySpec needs to implement SpecInterface interface
func (*StarRocksFeProxySpec) GetTerminationGracePeriodSeconds ¶ added in v1.8.4
func (spec *StarRocksFeProxySpec) GetTerminationGracePeriodSeconds() *int64
GetTerminationGracePeriodSeconds fe proxy does not have field TerminationGracePeriodSeconds, the reason why implementing this method is that StarRocksFeProxySpec needs to implement SpecInterface interface
func (*StarRocksFeProxySpec) GetUpdateStrategy ¶ added in v1.9.9
func (spec *StarRocksFeProxySpec) GetUpdateStrategy() *appsv1.StatefulSetUpdateStrategy
GetUpdateStrategy fe proxy is deployed by deployment, and it does not have field UpdateStrategy
func (*StarRocksFeProxySpec) IsReadOnlyRootFilesystem ¶ added in v1.9.9
func (spec *StarRocksFeProxySpec) IsReadOnlyRootFilesystem() *bool
IsReadOnlyRootFilesystem fe proxy does not have field ReadOnlyRootFilesystem, the reason why implementing this method is that StarRocksFeProxySpec needs to implement SpecInterface interface
type StarRocksFeProxyStatus ¶ added in v1.8.0
type StarRocksFeProxyStatus struct {
StarRocksComponentStatus `json:",inline"`
}
func (*StarRocksFeProxyStatus) DeepCopy ¶ added in v1.8.0
func (in *StarRocksFeProxyStatus) DeepCopy() *StarRocksFeProxyStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksFeProxyStatus.
func (*StarRocksFeProxyStatus) DeepCopyInto ¶ added in v1.8.0
func (in *StarRocksFeProxyStatus) DeepCopyInto(out *StarRocksFeProxyStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StarRocksFeSpec ¶
type StarRocksFeSpec struct { StarRocksComponentSpec `json:",inline"` // +optional // feEnvVars is a slice of environment variables that are added to the pods, the default is empty. FeEnvVars []corev1.EnvVar `json:"feEnvVars,omitempty"` }
StarRocksFeSpec defines the desired state of fe.
func (*StarRocksFeSpec) DeepCopy ¶
func (in *StarRocksFeSpec) DeepCopy() *StarRocksFeSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksFeSpec.
func (*StarRocksFeSpec) DeepCopyInto ¶
func (in *StarRocksFeSpec) DeepCopyInto(out *StarRocksFeSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*StarRocksFeSpec) GetReplicas ¶ added in v1.7.0
func (spec *StarRocksFeSpec) GetReplicas() *int32
type StarRocksFeStatus ¶
type StarRocksFeStatus struct {
StarRocksComponentStatus `json:",inline"`
}
StarRocksFeStatus represents the status of starrocks fe.
func (*StarRocksFeStatus) DeepCopy ¶
func (in *StarRocksFeStatus) DeepCopy() *StarRocksFeStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksFeStatus.
func (*StarRocksFeStatus) DeepCopyInto ¶
func (in *StarRocksFeStatus) DeepCopyInto(out *StarRocksFeStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StarRocksLoadSpec ¶ added in v1.8.0
type StarRocksLoadSpec struct { // defines the specification of resource cpu and mem. // +optional corev1.ResourceRequirements `json:",inline"` // annotation for pods. user can config monitor annotation for collect to monitor system. Annotations map[string]string `json:"annotations,omitempty"` // +optional // the pod labels for user select or classify pods. PodLabels map[string]string `json:"podLabels,omitempty"` // Replicas is the number of desired Pods. // When HPA policy is enabled with a fixed replica count in StarRocksCnSpec: every time // the starrockscluster CR is applied, the replica count of the StatefulSet // object in K8S will be reset to the value specified by the 'Replicas' // field, erasing the value previously set by HPA. // +kubebuilder:validation:Minimum=0 // +kubebuilder:default=1 // +optional Replicas *int32 `json:"replicas,omitempty"` // Image for a starrocks deployment. // +optional Image string `json:"image"` // Image pull policy. // One of Always, Never, IfNotPresent. // Defaults to IfNotPresent for compatibility. // More info: https://kubernetes.io/docs/concepts/containers/images#updating-images // +optional ImagePullPolicy corev1.PullPolicy `json:"imagePullPolicy,omitempty"` // ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the // images used by this PodSpec. If specified, these secrets will be passed to individual puller implementations for // them to use. // More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod // +optional // +patchMergeKey=name // +patchStrategy=merge ImagePullSecrets []corev1.LocalObjectReference `json:"imagePullSecrets,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,15,rep,name=imagePullSecrets"` //nolint:lll // SchedulerName is the name of the kubernetes scheduler that will be used to schedule the pods. // +optional SchedulerName string `json:"schedulerName,omitempty"` // (Optional) If specified, the pod's nodeSelector,displayName="Map of nodeSelectors to match when scheduling pods on nodes" // +optional NodeSelector map[string]string `json:"nodeSelector,omitempty"` // +optional // If specified, the pod's scheduling constraints. Affinity *corev1.Affinity `json:"affinity,omitempty"` // (Optional) Tolerations for scheduling pods onto some dedicated nodes // +optional Tolerations []corev1.Toleration `json:"tolerations,omitempty"` // (Optional) TopologySpreadConstraints for spreading pods across failure-domains // More info: https://kubernetes.io/docs/concepts/scheduling-eviction/topology-spread-constraints/ // +optional TopologySpreadConstraints []corev1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"` // Service defines the template for the associated Kubernetes Service object. // +optional Service *StarRocksService `json:"service,omitempty"` // StorageVolumes defines the additional storage for FE meta or BE/CN storage. // // For FE component // If the storage volume name is fe-meta or the volume mount path is /opt/starrocks/fe/meta, // then it will be recognized as storing the FE meta. // If the storage volume name is fe-log or the volume mount path is /opt/starrocks/fe/log, // then it will be recognized as storing the FE log. // // For BE component // If the storage volume name is be-storage(or be-data) or the volume mount path is /opt/starrocks/be/storage, // then it will be recognized as storing the BE data. // If the storage volume name is be-log or the volume mount path is /opt/starrocks/be/log, // then it will be recognized as storing the BE log. // // For CN component // If the storage volume name is cn-log or the volume mount path is /opt/starrocks/cn/log, // then it will be recognized as storing the cn log. // // If operator can't find the above storage volume names or the volume mount paths, it will create // default storage volumes by using emptyDir. // // +optional StorageVolumes []StorageVolume `json:"storageVolumes,omitempty"` // serviceAccount for access cloud service. ServiceAccount string `json:"serviceAccount,omitempty"` // the reference for configMap which store the config info to start starrocks. e.g. be.conf, fe.conf, cn.conf. // +optional ConfigMapInfo ConfigMapInfo `json:"configMapInfo,omitempty"` // StartupProbeFailureSeconds defines the total failure seconds of startup Probe. // Default failureThreshold is 60 and the periodSeconds is 5, this means the startup // will fail if the pod can't start in 300 seconds. Your StartupProbeFailureSeconds is // the total time of seconds before startupProbe give up and fail the container start. // If startupProbeFailureSeconds can't be divided by defaultPeriodSeconds, the failureThreshold // will be rounded up. // Note: you can set it to 0 to disable the startup probe. // +optional StartupProbeFailureSeconds *int32 `json:"startupProbeFailureSeconds,omitempty"` // LivenessProbeFailureSeconds defines the total failure seconds of liveness Probe. // Default failureThreshold is 3 and the periodSeconds is 5, this means the liveness // will fail if the pod can't respond in 15 seconds. Your LivenessProbeFailureSeconds is // the total time of seconds before the container restart. If LivenessProbeFailureSeconds // can't be divided by defaultPeriodSeconds, the failureThreshold will be rounded up. // Note: you can set it to 0 to disable the liveness probe. // +optional LivenessProbeFailureSeconds *int32 `json:"livenessProbeFailureSeconds,omitempty"` // ReadinessProbeFailureSeconds defines the total failure seconds of readiness Probe. // Default failureThreshold is 3 and the periodSeconds is 5, this means the readiness // will fail if the pod can't respond in 15 seconds. Your ReadinessProbeFailureSeconds is // the total time of seconds before pods becomes not ready. If ReadinessProbeFailureSeconds // can't be divided by defaultPeriodSeconds, the failureThreshold will be rounded up. // Note: you can set it to 0 to disable the readiness probe. // +optional ReadinessProbeFailureSeconds *int32 `json:"readinessProbeFailureSeconds,omitempty"` // Lifecycle describes actions that the management system should take in response to container lifecycle events. // By default, Operator will add corresponding preStop hooks for different components. For example, the preStop // script for the FE Component is /opt/starrocks/fe_prestop.sh, for the BE Component is /opt/starrocks/be_prestop.sh, // and for the CN Component is /opt/starrocks/cn_prestop.sh. // +optional Lifecycle *corev1.Lifecycle `json:"lifecycle,omitempty"` // When this is set containers will be able to view and signal processes from other containers // in the same pod, and the first process in each container will not be assigned PID 1. // Optional: Default to false. // +optional ShareProcessNamespace *bool `json:"shareProcessNamespace,omitempty"` }
func (*StarRocksLoadSpec) DeepCopy ¶ added in v1.8.0
func (in *StarRocksLoadSpec) DeepCopy() *StarRocksLoadSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksLoadSpec.
func (*StarRocksLoadSpec) DeepCopyInto ¶ added in v1.8.0
func (in *StarRocksLoadSpec) DeepCopyInto(out *StarRocksLoadSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*StarRocksLoadSpec) GetAffinity ¶ added in v1.8.0
func (spec *StarRocksLoadSpec) GetAffinity() *corev1.Affinity
func (*StarRocksLoadSpec) GetAnnotations ¶ added in v1.8.0
func (spec *StarRocksLoadSpec) GetAnnotations() map[string]string
func (*StarRocksLoadSpec) GetImage ¶ added in v1.11.1
func (spec *StarRocksLoadSpec) GetImage() string
func (*StarRocksLoadSpec) GetImagePullPolicy ¶ added in v1.9.6
func (spec *StarRocksLoadSpec) GetImagePullPolicy() corev1.PullPolicy
func (*StarRocksLoadSpec) GetImagePullSecrets ¶ added in v1.8.0
func (spec *StarRocksLoadSpec) GetImagePullSecrets() []corev1.LocalObjectReference
func (*StarRocksLoadSpec) GetLifecycle ¶ added in v1.9.3
func (spec *StarRocksLoadSpec) GetLifecycle() *corev1.Lifecycle
func (*StarRocksLoadSpec) GetLivenessProbeFailureSeconds ¶ added in v1.8.7
func (spec *StarRocksLoadSpec) GetLivenessProbeFailureSeconds() *int32
func (*StarRocksLoadSpec) GetNodeSelector ¶ added in v1.8.0
func (spec *StarRocksLoadSpec) GetNodeSelector() map[string]string
func (*StarRocksLoadSpec) GetReadinessProbeFailureSeconds ¶ added in v1.8.7
func (spec *StarRocksLoadSpec) GetReadinessProbeFailureSeconds() *int32
func (*StarRocksLoadSpec) GetReplicas ¶ added in v1.8.0
func (spec *StarRocksLoadSpec) GetReplicas() *int32
func (*StarRocksLoadSpec) GetSchedulerName ¶ added in v1.8.0
func (spec *StarRocksLoadSpec) GetSchedulerName() string
func (*StarRocksLoadSpec) GetService ¶ added in v1.9.0
func (spec *StarRocksLoadSpec) GetService() *StarRocksService
func (*StarRocksLoadSpec) GetServiceAccount ¶ added in v1.8.0
func (spec *StarRocksLoadSpec) GetServiceAccount() string
func (*StarRocksLoadSpec) GetShareProcessNamespace ¶ added in v1.9.10
func (spec *StarRocksLoadSpec) GetShareProcessNamespace() *bool
func (*StarRocksLoadSpec) GetStartupProbeFailureSeconds ¶ added in v1.8.4
func (spec *StarRocksLoadSpec) GetStartupProbeFailureSeconds() *int32
func (*StarRocksLoadSpec) GetStorageVolumes ¶ added in v1.8.0
func (spec *StarRocksLoadSpec) GetStorageVolumes() []StorageVolume
func (*StarRocksLoadSpec) GetTolerations ¶ added in v1.8.0
func (spec *StarRocksLoadSpec) GetTolerations() []corev1.Toleration
func (*StarRocksLoadSpec) GetTopologySpreadConstraints ¶ added in v1.9.7
func (spec *StarRocksLoadSpec) GetTopologySpreadConstraints() []corev1.TopologySpreadConstraint
type StarRocksProbe ¶
type StarRocksProbe struct { // Type identifies the mode of probe main container // +kubebuilder:validation:Enum=tcp;command Type string `json:"type"` // Number of seconds after the container has started before liveness probes are initiated. // Default to 10 seconds. // +kubebuilder:validation:Minimum=0 // +optional InitialDelaySeconds *int32 `json:"initialDelaySeconds,omitempty"` // How often (in seconds) to perform the probe. // Default to Kubernetes default (10 seconds). Minimum value is 1. // +kubebuilder:validation:Minimum=1 // +optional PeriodSeconds *int32 `json:"periodSeconds,omitempty"` }
StarRocksProbe defines the mode for probe be alive.
func (*StarRocksProbe) DeepCopy ¶
func (in *StarRocksProbe) DeepCopy() *StarRocksProbe
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksProbe.
func (*StarRocksProbe) DeepCopyInto ¶
func (in *StarRocksProbe) DeepCopyInto(out *StarRocksProbe)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StarRocksService ¶
type StarRocksService struct { // Annotations' store Kubernetes Service annotations. These will be added to the external service // only (not internal). // +optional Annotations map[string]string `json:"annotations,omitempty"` // Labels store Kubernetes Service labels. These will be added to the external service only (not // internal). StarRocks may add its own default labels. // +optional Labels map[string]string `json:"labels,omitempty"` // type of service,the possible value for the service type are : ClusterIP, NodePort, LoadBalancer,ExternalName. // More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types // +optional Type corev1.ServiceType `json:"type,omitempty"` // 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. // This field was under-specified and its meaning varies across implementations, // and it cannot support dual-stack. // As of Kubernetes v1.24, users are encouraged to use implementation-specific annotations when available. // This field may be removed in a future API version. // +optional LoadBalancerIP string `json:"loadBalancerIP,omitempty"` // Ports are the ports that are exposed by this service. // You can override the default port information by specifying the same StarRocksServicePort.Name in the ports list. // e.g. if you want to use a dedicated node port, you can just specify the StarRocksServicePort.Name and // StarRocksServicePort.NodePort field. // +optional Ports []StarRocksServicePort `json:"ports,omitempty"` // 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 LoadBalancerSourceRanges []string `json:"loadBalancerSourceRanges,omitempty"` }
StarRocksService defines external service for starrocks component.
func (*StarRocksService) DeepCopy ¶
func (in *StarRocksService) DeepCopy() *StarRocksService
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksService.
func (*StarRocksService) DeepCopyInto ¶
func (in *StarRocksService) DeepCopyInto(out *StarRocksService)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StarRocksServicePort ¶
type StarRocksServicePort struct { // Name of this port within the service. // For fe, port name can be http, query, rpc, edit-log, and their default container port is 8030, 9030, 9020, 9010. // For be, port name can be webserver, heartbeat, brpc, be, and their default container port is 8040, 9050, 8060, 9060. // For cn, port name can be webserver, heartbeat, brpc, thrift, and their default container port is 8040, 9050, 8060, 9060. // For fe proxy, port name can be http-port, and its default container port is 8080. // +optional Name string `json:"name,omitempty"` // Port that will be exposed by this service. // +optional Port int32 `json:"port,omitempty"` // ContainerPort of the service port. // For fe, port name can be http, query, rpc, edit-log, and their default container port is 8030, 9030, 9020, 9010. // For be, port name can be webserver, heartbeat, brpc, be, and their default container port is 8040, 9050, 8060, 9060. // For cn, port name can be webserver, heartbeat, brpc, thrift, and their default container port is 8040, 9050, 8060, 9060. // For fe proxy, port name can be http-port, and its default container port is 8080. // +optional ContainerPort int32 `json:"containerPort,omitempty"` // NodePort is used to specify the port on each node on which the service is exposed. // The range of valid ports is 30000-32767 // +optional NodePort int32 `json:"nodePort,omitempty"` }
StarRocksServicePort defines the port that will be exposed by this service. To assign a specific port or nodePort to a service, you should specify them by the corresponding name or containerPort in the service configuration. If both containerPort and name are specified, containerPort takes precedence.
func (*StarRocksServicePort) DeepCopy ¶
func (in *StarRocksServicePort) DeepCopy() *StarRocksServicePort
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksServicePort.
func (*StarRocksServicePort) DeepCopyInto ¶
func (in *StarRocksServicePort) DeepCopyInto(out *StarRocksServicePort)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StarRocksWarehouse ¶ added in v1.9.0
type StarRocksWarehouse struct { metav1.TypeMeta `json:",inline"` // +k8s:openapi-gen=false metav1.ObjectMeta `json:"metadata,omitempty"` // Spec represents the specification of desired state of a starrocks warehouse. Spec StarRocksWarehouseSpec `json:"spec,omitempty"` // Status represents the recent observed status of the starrocks warehouse. Status StarRocksWarehouseStatus `json:"status,omitempty"` }
StarRocksWarehouse defines a starrocks warehouse. +kubebuilder:object:root=true +kubebuilder:metadata:annotations="version=v1.11.2" +kubebuilder:resource:shortName=warehouses +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:subresource:status +kubebuilder:subresource:scale:specpath=.spec.template.replicas,statuspath=.status.replicas,selectorpath=.status.selector +kubebuilder:printcolumn:name="status",type=string,JSONPath=`.status.phase` +kubebuilder:printcolumn:name="reason",type=string,JSONPath=`.status.reason` +kubebuilder:storageversion +k8s:openapi-gen=true +genclient
func (*StarRocksWarehouse) DeepCopy ¶ added in v1.9.0
func (in *StarRocksWarehouse) DeepCopy() *StarRocksWarehouse
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksWarehouse.
func (*StarRocksWarehouse) DeepCopyInto ¶ added in v1.9.0
func (in *StarRocksWarehouse) DeepCopyInto(out *StarRocksWarehouse)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*StarRocksWarehouse) DeepCopyObject ¶ added in v1.9.0
func (in *StarRocksWarehouse) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type StarRocksWarehouseList ¶ added in v1.9.0
type StarRocksWarehouseList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []StarRocksWarehouse `json:"items"` }
StarRocksWarehouseList contains a list of StarRocksWarehouse +kubebuilder:object:root=true +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +k8s:openapi-gen=true
func (*StarRocksWarehouseList) DeepCopy ¶ added in v1.9.0
func (in *StarRocksWarehouseList) DeepCopy() *StarRocksWarehouseList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksWarehouseList.
func (*StarRocksWarehouseList) DeepCopyInto ¶ added in v1.9.0
func (in *StarRocksWarehouseList) DeepCopyInto(out *StarRocksWarehouseList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*StarRocksWarehouseList) DeepCopyObject ¶ added in v1.9.0
func (in *StarRocksWarehouseList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type StarRocksWarehouseSpec ¶ added in v1.9.0
type StarRocksWarehouseSpec struct { // StarRocksCluster is the name of a StarRocksCluster which the warehouse belongs to. StarRocksCluster string `json:"starRocksCluster"` // Template define component configuration. Template *WarehouseComponentSpec `json:"template"` }
StarRocksWarehouseSpec defines the desired state of StarRocksWarehouse
func (*StarRocksWarehouseSpec) DeepCopy ¶ added in v1.9.0
func (in *StarRocksWarehouseSpec) DeepCopy() *StarRocksWarehouseSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksWarehouseSpec.
func (*StarRocksWarehouseSpec) DeepCopyInto ¶ added in v1.9.0
func (in *StarRocksWarehouseSpec) DeepCopyInto(out *StarRocksWarehouseSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StarRocksWarehouseStatus ¶ added in v1.9.0
type StarRocksWarehouseStatus struct {
*WarehouseComponentStatus `json:",inline"`
}
StarRocksWarehouseStatus defines the observed state of StarRocksWarehouse.
func (*StarRocksWarehouseStatus) DeepCopy ¶ added in v1.9.0
func (in *StarRocksWarehouseStatus) DeepCopy() *StarRocksWarehouseStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StarRocksWarehouseStatus.
func (*StarRocksWarehouseStatus) DeepCopyInto ¶ added in v1.9.0
func (in *StarRocksWarehouseStatus) DeepCopyInto(out *StarRocksWarehouseStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StorageVolume ¶
type StorageVolume struct { // name of a storage volume. // +kubebuilder:validation:Pattern=[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)* Name string `json:"name"` // storageClassName is the name of the StorageClass required by the claim. // If storageClassName is not set, the default StorageClass of kubernetes will be used. // there are some special storageClassName: emptyDir, hostPath. In this case, It will use emptyDir or hostPath, not PVC. // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1 // +optional StorageClassName *string `json:"storageClassName,omitempty"` // StorageSize is a valid memory size type based on powers-of-2, so 1Mi is 1024Ki. // Supported units:Mi, Gi, GiB, Ti, Ti, Pi, Ei, Ex: `512Mi`. // It will take effect only when storageClassName is real storage class, not emptyDir or hostPath. // +kubebuilder:validation:Pattern:="(^0|([0-9]*l[.])?[0-9]+((M|G|T|E|P)i))$" // +optional StorageSize string `json:"storageSize,omitempty"` // HostPath Represents a host path mapped into a pod. // If StorageClassName is hostPath, HostPath is required. // +optional HostPath *corev1.HostPathVolumeSource `json:"hostPath,omitempty"` // MountPath specify the path of volume mount. MountPath string `json:"mountPath"` // SubPath within the volume from which the container's volume should be mounted. // Defaults to "" (volume's root). SubPath string `json:"subPath,omitempty"` }
StorageVolume defines additional PVC template for StatefulSets and volumeMount for pods that mount this PVC.
func (*StorageVolume) DeepCopy ¶
func (in *StorageVolume) DeepCopy() *StorageVolume
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StorageVolume.
func (*StorageVolume) DeepCopyInto ¶
func (in *StorageVolume) DeepCopyInto(out *StorageVolume)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*StorageVolume) Validate ¶ added in v1.9.3
func (storageVolume *StorageVolume) Validate() error
type WarehouseComponentSpec ¶ added in v1.9.0
type WarehouseComponentSpec struct { StarRocksComponentSpec `json:",inline"` // +optional // envVars is a slice of environment variables that are added to the pods, the default is empty. EnvVars []corev1.EnvVar `json:"envVars,omitempty"` // AutoScalingPolicy defines auto scaling policy AutoScalingPolicy *AutoScalingPolicy `json:"autoScalingPolicy,omitempty"` }
WarehouseComponentSpec defines the desired state of component.
func (*WarehouseComponentSpec) DeepCopy ¶ added in v1.9.0
func (in *WarehouseComponentSpec) DeepCopy() *WarehouseComponentSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WarehouseComponentSpec.
func (*WarehouseComponentSpec) DeepCopyInto ¶ added in v1.9.0
func (in *WarehouseComponentSpec) DeepCopyInto(out *WarehouseComponentSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*WarehouseComponentSpec) ToCnSpec ¶ added in v1.9.0
func (componentSpec *WarehouseComponentSpec) ToCnSpec() *StarRocksCnSpec
type WarehouseComponentStatus ¶ added in v1.9.0
type WarehouseComponentStatus = StarRocksCnStatus
WarehouseComponentStatus represents the status of component. +kubebuilder:object:generate=false