Documentation ¶
Index ¶
- func BuiltInCustomFunctions(c *configTemplateBuilder, component *component.SynthesizedComponent, ...) *gotemplate.BuiltInObjectsFunc
- func CheckTLSSecretRef(ctx context.Context, cli client2.ReadonlyClient, namespace string, ...) error
- func ComposeTLSSecret(namespace, clusterName, componentName string) (*v1.Secret, error)
- func DoPITR(ctx context.Context, cli client.Client, cluster *appsv1alpha1.Cluster, ...) error
- func DoRestore(ctx context.Context, cli client.Client, cluster *appsv1alpha1.Cluster, ...) error
- func GenerateTLSSecretName(clusterName, componentName string) string
- func GetTLSKeyWord(cType string) string
- func RenderConfigNScriptFiles(clusterVersion *appsv1alpha1.ClusterVersion, cluster *appsv1alpha1.Cluster, ...) ([]client.Object, error)
- type ResourceDefinition
- type RestoreManager
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuiltInCustomFunctions ¶
func BuiltInCustomFunctions(c *configTemplateBuilder, component *component.SynthesizedComponent, localObjs []client.Object) *gotemplate.BuiltInObjectsFunc
BuiltInCustomFunctions builds a map of customized functions for KubeBlocks
func CheckTLSSecretRef ¶
func CheckTLSSecretRef(ctx context.Context, cli client2.ReadonlyClient, namespace string, secretRef *dbaasv1alpha1.TLSSecretRef) error
func ComposeTLSSecret ¶
ComposeTLSSecret composes a TSL secret object. REVIEW/TODO:
- missing public function doc
- should avoid using Go template to call a function, this is too hacky & costly, should just call underlying registered Go template function.
func DoPITR ¶ added in v0.6.0
func DoPITR(ctx context.Context, cli client.Client, cluster *appsv1alpha1.Cluster, component *component.SynthesizedComponent, schema *k8sruntime.Scheme) error
DoPITR prepares PITR jobs
func DoRestore ¶ added in v0.6.0
func DoRestore(ctx context.Context, cli client.Client, cluster *appsv1alpha1.Cluster, component *component.SynthesizedComponent, schema *k8sruntime.Scheme) error
DoRestore prepares restore jobs
func GenerateTLSSecretName ¶
func GetTLSKeyWord ¶
func RenderConfigNScriptFiles ¶ added in v0.6.0
func RenderConfigNScriptFiles(clusterVersion *appsv1alpha1.ClusterVersion, cluster *appsv1alpha1.Cluster, component *component.SynthesizedComponent, obj client.Object, podSpec *corev1.PodSpec, localObjs []client.Object, ctx context.Context, cli client.Client) ([]client.Object, error)
RenderConfigNScriptFiles generates volumes for PodTemplate, volumeMount for container, rendered configTemplate and scriptTemplate, and generates configManager sidecar for the reconfigure operation. TODO rename this function, this function name is not very reasonable, but there is no suitable name.
Types ¶
type ResourceDefinition ¶
type RestoreManager ¶ added in v0.6.0
type RestoreManager struct { client.Client Ctx context.Context Cluster *appsv1alpha1.Cluster Scheme *k8sruntime.Scheme // contains filtered or unexported fields }
RestoreManager restores manager functions 1. support datafile/snapshot restore 2. support point in time recovery (PITR)
Click to show internal directories.
Click to hide internal directories.