Documentation ¶
Index ¶
Constants ¶
View Source
const (
// ScaleToMultiNodeAnnotationKey is used to represent scale-up annotation.
ScaleToMultiNodeAnnotationKey = "gardener.cloud/scaled-to-multi-node"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Interface ¶
type Interface interface { gardenercomponent.DeployWaiter // Get gets the etcd StatefulSet. Get(context.Context) (*appsv1.StatefulSet, error) // PreDeploy performs operations prior to the deployment of the StatefulSet component. PreDeploy(ctx context.Context, etcd *druidv1alpha1.Etcd) error }
Interface contains functions for a StatefulSet deployer.
type Values ¶
type Values struct { // Name is the name of the StatefulSet. Name string // Namespace is the namespace of StatefulSet. Namespace string // OwnerReference is the OwnerReference for the StatefulSet. OwnerReference metav1.OwnerReference // Replicas is the number of ETCD instance that the ETCD cluster will have. Replicas int32 // StatusReplicas is the number of replicas maintained in ETCD status. StatusReplicas int32 // Annotations is the annotation provided in ETCD spec. Annotations map[string]string // Labels defines the labels used for the statefulset. Labels map[string]string // SelectorLabels defines the selector's matchLabels for the statefulset. SelectorLabels map[string]string // PodLabels represents the labels to be applied to the statefulset pods. PodLabels map[string]string // AdditionalPodLabels represents additional labels to be applied to the StatefulSet pods. AdditionalPodLabels map[string]string // BackupImage is the backup restore image. BackupImage string // EtcdImage is the etcd custom image. EtcdImage string // InitContainerImage is the image used in the init container in the etcd pod InitContainerImage string // PriorityClassName is the Priority Class name. PriorityClassName *string // ServiceAccountName is the service account name. ServiceAccountName string Affinity *corev1.Affinity TopologySpreadConstraints []corev1.TopologySpreadConstraint EtcdResourceRequirements *corev1.ResourceRequirements BackupResourceRequirements *corev1.ResourceRequirements EtcdCommandArgs []string ReadinessProbeCommand []string EtcdBackupRestoreCommandArgs []string EnableClientTLS string EnablePeerTLS string FailBelowRevision string VolumeClaimTemplateName string FullSnapLeaseName string DeltaSnapLeaseName string StorageCapacity *resource.Quantity StorageClass *string DefragmentationSchedule *string FullSnapshotSchedule *string EtcdSnapshotTimeout *metav1.Duration EtcdDefragTimeout *metav1.Duration DeltaSnapshotMemoryLimit *resource.Quantity GarbageCollectionPolicy *druidv1alpha1.GarbageCollectionPolicy GarbageCollectionPeriod *metav1.Duration LeaderElection *druidv1alpha1.LeaderElectionSpec BackupStore *druidv1alpha1.StoreSpec EnableProfiling *bool DeltaSnapshotPeriod *metav1.Duration DeltaSnapshotRetentionPeriod *metav1.Duration SnapshotCompression *druidv1alpha1.CompressionSpec HeartbeatDuration *metav1.Duration // MetricsLevel defines the level of detail for exported metrics of etcd, specify 'extensive' to include histogram metrics. MetricsLevel *druidv1alpha1.MetricsLevel // Quota defines the etcd DB quota. Quota *resource.Quantity // ClientUrlTLS holds the TLS configuration details for client communication. ClientUrlTLS *druidv1alpha1.TLSConfig // PeerUrlTLS hold the TLS configuration details for peer communication. PeerUrlTLS *druidv1alpha1.TLSConfig // BackupTLS hold the TLS configuration for communication with Backup server. BackupTLS *druidv1alpha1.TLSConfig //ClientServiceName is name of the etcd client service. ClientServiceName string // ClientPort holds the client port. ClientPort *int32 //PeerServiceName is name of the etcd peer service. PeerServiceName string // ServerPort is the peer port. ServerPort *int32 // BackupPort is the backup-restore side-car port. BackupPort *int32 // WrapperPort is the port where etcd-wrapper registers and exposes it's ready endpoint WrapperPort *int32 // AutoCompactionMode defines the auto-compaction-mode: 'periodic' or 'revision'. AutoCompactionMode *druidv1alpha1.CompactionMode //AutoCompactionRetention defines the auto-compaction-retention length for etcd as well as for embedded-Etcd of backup-restore sidecar. AutoCompactionRetention *string // ConfigMapName is the name of the configmap that holds the ETCD config. ConfigMapName string PeerTLSChangedToEnabled bool // UseEtcdWrapper enables the use of etcd-wrapper image and a compatible version of etcd-backup-restore UseEtcdWrapper bool }
Values contains the values necessary for creating ETCD statefulset.
func GeneratePreDeployValues ¶ added in v0.22.1
func GeneratePreDeployValues(etcd *druidv1alpha1.Etcd) *Values
GeneratePreDeployValues generates `statefulset.Values` for the statefulset component with the given parameters, used specifically for the PreDeploy method.
func GenerateValues ¶
func GenerateValues( etcd *druidv1alpha1.Etcd, clientPort, serverPort, backupPort *int32, etcdImage, backupImage, initContainerImage string, checksumAnnotations map[string]string, peerTLSChangedToEnabled, useEtcdWrapper bool) (*Values, error)
GenerateValues generates `statefulset.Values` for the statefulset component with the given parameters.
Click to show internal directories.
Click to hide internal directories.