Documentation ¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the druid v1alpha1 API group +kubebuilder:object:generate=true +groupName=druid.gardener.cloud
Index ¶
- Constants
- Variables
- func AreManagedResourcesProtected(etcdObjMeta metav1.ObjectMeta) bool
- func GetAllPodNames(etcdObjMeta metav1.ObjectMeta, replicas int32) []string
- func GetAsOwnerReference(etcdObjMeta metav1.ObjectMeta) metav1.OwnerReference
- func GetClientServiceName(etcdObjMeta metav1.ObjectMeta) string
- func GetCompactionJobName(etcdObjMeta metav1.ObjectMeta) string
- func GetConfigMapName(etcdObjMeta metav1.ObjectMeta) string
- func GetDefaultLabels(etcdObjMeta metav1.ObjectMeta) map[string]string
- func GetDeltaSnapshotLeaseName(etcdObjMeta metav1.ObjectMeta) string
- func GetFullSnapshotLeaseName(etcdObjMeta metav1.ObjectMeta) string
- func GetMemberLeaseNames(etcdObjMeta metav1.ObjectMeta, replicas int32) []string
- func GetNamespaceName(etcdObjMeta metav1.ObjectMeta) types.NamespacedName
- func GetOrdinalPodName(etcdObjMeta metav1.ObjectMeta, ordinal int) string
- func GetPeerServiceName(etcdObjMeta metav1.ObjectMeta) string
- func GetPodDisruptionBudgetName(etcdObjMeta metav1.ObjectMeta) string
- func GetRoleBindingName(etcdObjMeta metav1.ObjectMeta) string
- func GetRoleName(etcdObjMeta metav1.ObjectMeta) string
- func GetServiceAccountName(etcdObjMeta metav1.ObjectMeta) string
- func GetStatefulSetName(etcdObjMeta metav1.ObjectMeta) string
- func GetSuspendEtcdSpecReconcileAnnotationKey(etcdObjMeta metav1.ObjectMeta) *string
- func IsEtcdMarkedForDeletion(etcdObjMeta metav1.ObjectMeta) bool
- type BackupSpec
- type ClientService
- type CompactionMode
- type CompressionPolicy
- type CompressionSpec
- type Condition
- type ConditionStatus
- type ConditionType
- type CrossVersionObjectReference
- type ErrorCode
- type Etcd
- type EtcdConfig
- type EtcdCopyBackupsTask
- type EtcdCopyBackupsTaskList
- type EtcdCopyBackupsTaskSpec
- type EtcdCopyBackupsTaskStatus
- type EtcdList
- type EtcdMemberConditionStatus
- type EtcdMemberStatus
- type EtcdRole
- type EtcdSpec
- type EtcdStatus
- type GarbageCollectionPolicy
- type LastError
- type LastOperation
- type LastOperationState
- type LastOperationType
- type LeaderElectionSpec
- type MetricsLevel
- type SchedulingConstraints
- type SecretReference
- type SharedConfig
- type StorageProvider
- type StoreSpec
- type TLSConfig
- type WaitForFinalSnapshotSpec
Constants ¶
const ( // LabelAppNameKey is a label which sets the name of the resource provisioned for an etcd cluster. LabelAppNameKey = "app.kubernetes.io/name" // LabelManagedByKey is a key of a label which sets druid as a manager for resources provisioned for an etcd cluster. LabelManagedByKey = "app.kubernetes.io/managed-by" // LabelManagedByValue is the value for LabelManagedByKey. LabelManagedByValue = "etcd-druid" // LabelPartOfKey is a key of a label which establishes that a provisioned resource belongs to a parent etcd cluster. LabelPartOfKey = "app.kubernetes.io/part-of" // LabelComponentKey is a key for a label that sets the component type on resources provisioned for an etcd cluster. LabelComponentKey = "app.kubernetes.io/component" )
Common label keys to be placed on all druid-managed resources
const ( // IgnoreReconciliationAnnotation is an annotation set by an operator in order to stop reconciliation. // Deprecated: Please use SuspendEtcdSpecReconcileAnnotation instead IgnoreReconciliationAnnotation = "druid.gardener.cloud/ignore-reconciliation" // SuspendEtcdSpecReconcileAnnotation is an annotation set by an operator to temporarily suspend any etcd spec reconciliation. SuspendEtcdSpecReconcileAnnotation = "druid.gardener.cloud/suspend-etcd-spec-reconcile" // DisableEtcdComponentProtectionAnnotation is an annotation set by an operator to disable protection of components created for // an etcd cluster and managed by etcd-druid. DisableEtcdComponentProtectionAnnotation = "druid.gardener.cloud/disable-etcd-component-protection" )
Annotation keys that can be placed on an Etcd custom resource.
const ( // GarbageCollectionPolicyExponential defines the exponential policy for garbage collecting old backups GarbageCollectionPolicyExponential = "Exponential" // GarbageCollectionPolicyLimitBased defines the limit based policy for garbage collecting old backups GarbageCollectionPolicyLimitBased = "LimitBased" // Basic is a constant for metrics level basic. Basic MetricsLevel = "basic" // Extensive is a constant for metrics level extensive. Extensive MetricsLevel = "extensive" // GzipCompression is constant for gzip compression policy. GzipCompression CompressionPolicy = "gzip" // LzwCompression is constant for lzw compression policy. LzwCompression CompressionPolicy = "lzw" // ZlibCompression is constant for zlib compression policy. ZlibCompression CompressionPolicy = "zlib" // DefaultCompression is constant for default compression policy(only if compression is enabled). DefaultCompression = GzipCompression // DefaultCompressionEnabled is constant to define whether to compress the snapshots or not. DefaultCompressionEnabled = false // Periodic is a constant to set auto-compaction-mode 'periodic' for duration based retention. Periodic CompactionMode = "periodic" // Revision is a constant to set auto-compaction-mode 'revision' for revision number based retention. Revision CompactionMode = "revision" )
const GroupName = "druid.gardener.cloud"
GroupName is the name of the druid API group.
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"} // SchemeBuilder is used to add go types to the GroupVersionKind scheme SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) // AddToScheme adds the types in this group-version to the given scheme. AddToScheme = localSchemeBuilder.AddToScheme // SchemeGroupVersion is group version used to register these objects. SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"} )
nolint:gochecknoglobals
Functions ¶
func AreManagedResourcesProtected ¶ added in v0.23.0
func AreManagedResourcesProtected(etcdObjMeta metav1.ObjectMeta) bool
AreManagedResourcesProtected returns false if the Etcd resource has the `druid.gardener.cloud/disable-etcd-component-protection` annotation set, else returns true.
func GetAllPodNames ¶ added in v0.23.0
func GetAllPodNames(etcdObjMeta metav1.ObjectMeta, replicas int32) []string
GetAllPodNames returns the names of all pods for the Etcd.
func GetAsOwnerReference ¶ added in v0.23.0
func GetAsOwnerReference(etcdObjMeta metav1.ObjectMeta) metav1.OwnerReference
GetAsOwnerReference returns an OwnerReference object that represents the current Etcd instance.
func GetClientServiceName ¶ added in v0.23.0
func GetClientServiceName(etcdObjMeta metav1.ObjectMeta) string
GetClientServiceName returns the client service name for the Etcd cluster reachable by external clients.
func GetCompactionJobName ¶ added in v0.23.0
func GetCompactionJobName(etcdObjMeta metav1.ObjectMeta) string
GetCompactionJobName returns the compaction job name for the Etcd.
func GetConfigMapName ¶ added in v0.23.0
func GetConfigMapName(etcdObjMeta metav1.ObjectMeta) string
GetConfigMapName returns the name of the configmap for the Etcd.
func GetDefaultLabels ¶ added in v0.23.0
func GetDefaultLabels(etcdObjMeta metav1.ObjectMeta) map[string]string
GetDefaultLabels returns the default labels for etcd.
func GetDeltaSnapshotLeaseName ¶ added in v0.23.0
func GetDeltaSnapshotLeaseName(etcdObjMeta metav1.ObjectMeta) string
GetDeltaSnapshotLeaseName returns the name of the delta snapshot lease for the Etcd.
func GetFullSnapshotLeaseName ¶ added in v0.23.0
func GetFullSnapshotLeaseName(etcdObjMeta metav1.ObjectMeta) string
GetFullSnapshotLeaseName returns the name of the full snapshot lease for the Etcd.
func GetMemberLeaseNames ¶ added in v0.23.0
func GetMemberLeaseNames(etcdObjMeta metav1.ObjectMeta, replicas int32) []string
GetMemberLeaseNames returns the name of member leases for the Etcd.
func GetNamespaceName ¶ added in v0.23.0
func GetNamespaceName(etcdObjMeta metav1.ObjectMeta) types.NamespacedName
GetNamespaceName is a convenience function which creates a types.NamespacedName for an Etcd resource.
func GetOrdinalPodName ¶ added in v0.23.0
func GetOrdinalPodName(etcdObjMeta metav1.ObjectMeta, ordinal int) string
GetOrdinalPodName returns the Etcd pod name based on the ordinal.
func GetPeerServiceName ¶ added in v0.23.0
func GetPeerServiceName(etcdObjMeta metav1.ObjectMeta) string
GetPeerServiceName returns the peer service name for the Etcd cluster reachable by members within the Etcd cluster.
func GetPodDisruptionBudgetName ¶ added in v0.23.0
func GetPodDisruptionBudgetName(etcdObjMeta metav1.ObjectMeta) string
GetPodDisruptionBudgetName returns the name of the pod disruption budget for the Etcd.
func GetRoleBindingName ¶ added in v0.23.0
func GetRoleBindingName(etcdObjMeta metav1.ObjectMeta) string
GetRoleBindingName returns the role binding name for the Etcd.
func GetRoleName ¶ added in v0.23.0
func GetRoleName(etcdObjMeta metav1.ObjectMeta) string
GetRoleName returns the role name for the Etcd.
func GetServiceAccountName ¶ added in v0.23.0
func GetServiceAccountName(etcdObjMeta metav1.ObjectMeta) string
GetServiceAccountName returns the service account name for the Etcd.
func GetStatefulSetName ¶ added in v0.23.0
func GetStatefulSetName(etcdObjMeta metav1.ObjectMeta) string
GetStatefulSetName returns the name of the StatefulSet for the Etcd.
func GetSuspendEtcdSpecReconcileAnnotationKey ¶ added in v0.23.0
func GetSuspendEtcdSpecReconcileAnnotationKey(etcdObjMeta metav1.ObjectMeta) *string
GetSuspendEtcdSpecReconcileAnnotationKey gets the annotation key set on an Etcd resource signalling the intent to suspend spec reconciliation for this Etcd resource. If no annotation is set then it will return nil.
func IsEtcdMarkedForDeletion ¶ added in v0.23.0
func IsEtcdMarkedForDeletion(etcdObjMeta metav1.ObjectMeta) bool
IsEtcdMarkedForDeletion returns true if the Etcd object is marked for deletion and false otherwise.
Types ¶
type BackupSpec ¶
type BackupSpec struct { // Port define the port on which etcd-backup-restore server will be exposed. // +optional Port *int32 `json:"port,omitempty"` // +optional TLS *TLSConfig `json:"tls,omitempty"` // Image defines the etcd container image and tag // +optional Image *string `json:"image,omitempty"` // Store defines the specification of object store provider for storing backups. // +optional Store *StoreSpec `json:"store,omitempty"` // Resources defines compute Resources required by backup-restore container. // More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ // +optional Resources *corev1.ResourceRequirements `json:"resources,omitempty"` // CompactionResources defines compute Resources required by compaction job. // More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ // +optional CompactionResources *corev1.ResourceRequirements `json:"compactionResources,omitempty"` // FullSnapshotSchedule defines the cron standard schedule for full snapshots. // +optional FullSnapshotSchedule *string `json:"fullSnapshotSchedule,omitempty"` // GarbageCollectionPolicy defines the policy for garbage collecting old backups // +optional GarbageCollectionPolicy *GarbageCollectionPolicy `json:"garbageCollectionPolicy,omitempty"` // MaxBackupsLimitBasedGC defines the maximum number of Full snapshots to retain in Limit Based GarbageCollectionPolicy // All full snapshots beyond this limit will be garbage collected. // +optional MaxBackupsLimitBasedGC *int32 `json:"maxBackupsLimitBasedGC,omitempty"` // GarbageCollectionPeriod defines the period for garbage collecting old backups // +optional GarbageCollectionPeriod *metav1.Duration `json:"garbageCollectionPeriod,omitempty"` // DeltaSnapshotPeriod defines the period after which delta snapshots will be taken // +optional DeltaSnapshotPeriod *metav1.Duration `json:"deltaSnapshotPeriod,omitempty"` // DeltaSnapshotMemoryLimit defines the memory limit after which delta snapshots will be taken // +optional DeltaSnapshotMemoryLimit *resource.Quantity `json:"deltaSnapshotMemoryLimit,omitempty"` // DeltaSnapshotRetentionPeriod defines the duration for which delta snapshots will be retained, excluding the latest snapshot set. // The value should be a string formatted as a duration (e.g., '1s', '2m', '3h', '4d') // +kubebuilder:validation:Type=string // +kubebuilder:validation:Pattern="^([0-9][0-9]*([.][0-9]+)?(s|m|h|d))+$" // +optional DeltaSnapshotRetentionPeriod *metav1.Duration `json:"deltaSnapshotRetentionPeriod,omitempty"` // SnapshotCompression defines the specification for compression of Snapshots. // +optional SnapshotCompression *CompressionSpec `json:"compression,omitempty"` // EnableProfiling defines if profiling should be enabled for the etcd-backup-restore-sidecar // +optional EnableProfiling *bool `json:"enableProfiling,omitempty"` // EtcdSnapshotTimeout defines the timeout duration for etcd FullSnapshot operation // +optional EtcdSnapshotTimeout *metav1.Duration `json:"etcdSnapshotTimeout,omitempty"` // LeaderElection defines parameters related to the LeaderElection configuration. // +optional LeaderElection *LeaderElectionSpec `json:"leaderElection,omitempty"` }
BackupSpec defines parameters associated with the full and delta snapshots of etcd.
func (*BackupSpec) DeepCopy ¶
func (in *BackupSpec) DeepCopy() *BackupSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BackupSpec.
func (*BackupSpec) DeepCopyInto ¶
func (in *BackupSpec) DeepCopyInto(out *BackupSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ClientService ¶ added in v0.14.0
type ClientService struct { // Annotations specify the annotations that should be added to the client service // +optional Annotations map[string]string `json:"annotations,omitempty"` // Labels specify the labels that should be added to the client service // +optional Labels map[string]string `json:"labels,omitempty"` }
ClientService defines the parameters of the client service that a user can specify
func (*ClientService) DeepCopy ¶ added in v0.14.0
func (in *ClientService) DeepCopy() *ClientService
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClientService.
func (*ClientService) DeepCopyInto ¶ added in v0.14.0
func (in *ClientService) DeepCopyInto(out *ClientService)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type CompactionMode ¶ added in v0.5.0
type CompactionMode string
CompactionMode defines the auto-compaction-mode: 'periodic' or 'revision'. 'periodic' for duration based retention and 'revision' for revision number based retention. +kubebuilder:validation:Enum=periodic;revision
type CompressionPolicy ¶ added in v0.5.0
type CompressionPolicy string
CompressionPolicy defines the type of policy for compression of snapshots. +kubebuilder:validation:Enum=gzip;lzw;zlib
type CompressionSpec ¶ added in v0.5.0
type CompressionSpec struct { // +optional Enabled *bool `json:"enabled,omitempty"` // +optional Policy *CompressionPolicy `json:"policy,omitempty"` }
CompressionSpec defines parameters related to compression of Snapshots(full as well as delta).
func (*CompressionSpec) DeepCopy ¶ added in v0.5.1
func (in *CompressionSpec) DeepCopy() *CompressionSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CompressionSpec.
func (*CompressionSpec) DeepCopyInto ¶ added in v0.5.1
func (in *CompressionSpec) DeepCopyInto(out *CompressionSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Condition ¶
type Condition struct { // Type of the Etcd condition. Type ConditionType `json:"type"` // Status of the condition, one of True, False, Unknown. Status ConditionStatus `json:"status"` // Last time the condition transitioned from one status to another. LastTransitionTime metav1.Time `json:"lastTransitionTime"` // Last time the condition was updated. LastUpdateTime metav1.Time `json:"lastUpdateTime"` // The reason for the condition's last transition. Reason string `json:"reason"` // A human-readable message indicating details about the transition. Message string `json:"message"` }
Condition holds the information about the state of a resource.
func (*Condition) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Condition.
func (*Condition) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ConditionStatus ¶
type ConditionStatus string
ConditionStatus is the status of a condition.
const ( // ConditionTrue means a resource is in the condition. ConditionTrue ConditionStatus = "True" // ConditionFalse means a resource is not in the condition. ConditionFalse ConditionStatus = "False" // ConditionUnknown means Gardener can't decide if a resource is in the condition or not. ConditionUnknown ConditionStatus = "Unknown" // ConditionProgressing means the condition was seen true, failed but stayed within a predefined failure threshold. // In the future, we could add other intermediate conditions, e.g. ConditionDegraded. ConditionProgressing ConditionStatus = "Progressing" // ConditionCheckError is a constant for a reason in condition. ConditionCheckError ConditionStatus = "ConditionCheckError" )
type ConditionType ¶
type ConditionType string
ConditionType is the type of condition.
const ( // ConditionTypeReady is a constant for a condition type indicating that the etcd cluster is ready. ConditionTypeReady ConditionType = "Ready" // ConditionTypeAllMembersReady is a constant for a condition type indicating that all members of the etcd cluster are ready. ConditionTypeAllMembersReady ConditionType = "AllMembersReady" // ConditionTypeBackupReady is a constant for a condition type indicating that the etcd backup is ready. ConditionTypeBackupReady ConditionType = "BackupReady" // ConditionTypeDataVolumesReady is a constant for a condition type indicating that the etcd data volumes are ready. ConditionTypeDataVolumesReady ConditionType = "DataVolumesReady" )
const ( // EtcdCopyBackupsTaskSucceeded is a condition type indicating that a EtcdCopyBackupsTask has succeeded. EtcdCopyBackupsTaskSucceeded ConditionType = "Succeeded" // EtcdCopyBackupsTaskFailed is a condition type indicating that a EtcdCopyBackupsTask has failed. EtcdCopyBackupsTaskFailed ConditionType = "Failed" )
type CrossVersionObjectReference ¶
type CrossVersionObjectReference struct { // Kind of the referent // +required Kind string `json:"kind,omitempty"` // Name of the referent // +required Name string `json:"name,omitempty"` // API version of the referent // +optional APIVersion string `json:"apiVersion,omitempty"` }
CrossVersionObjectReference contains enough information to let you identify the referred resource.
func (*CrossVersionObjectReference) DeepCopy ¶
func (in *CrossVersionObjectReference) DeepCopy() *CrossVersionObjectReference
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CrossVersionObjectReference.
func (*CrossVersionObjectReference) DeepCopyInto ¶
func (in *CrossVersionObjectReference) DeepCopyInto(out *CrossVersionObjectReference)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ErrorCode ¶ added in v0.23.0
type ErrorCode string
ErrorCode is a string alias representing an error code that identifies an error.
type Etcd ¶
type Etcd struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec EtcdSpec `json:"spec,omitempty"` Status EtcdStatus `json:"status,omitempty"` }
Etcd is the Schema for the etcds API
func (*Etcd) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Etcd.
func (*Etcd) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Etcd) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*Etcd) IsBackupStoreEnabled ¶ added in v0.23.0
IsBackupStoreEnabled returns true if backup store has been enabled for the Etcd resource, else returns false.
func (*Etcd) IsDeletionInProgress ¶ added in v0.23.0
IsDeletionInProgress returns true if the Etcd resource is currently being reconciled, else returns false.
func (*Etcd) IsReconciliationInProgress ¶ added in v0.23.0
IsReconciliationInProgress returns true if the Etcd resource is currently being reconciled, else returns false.
type EtcdConfig ¶
type EtcdConfig struct { // Quota defines the etcd DB quota. // +optional Quota *resource.Quantity `json:"quota,omitempty"` // DefragmentationSchedule defines the cron standard schedule for defragmentation of etcd. // +optional DefragmentationSchedule *string `json:"defragmentationSchedule,omitempty"` // +optional ServerPort *int32 `json:"serverPort,omitempty"` // +optional ClientPort *int32 `json:"clientPort,omitempty"` // Image defines the etcd container image and tag // +optional Image *string `json:"image,omitempty"` // +optional AuthSecretRef *corev1.SecretReference `json:"authSecretRef,omitempty"` // Metrics defines the level of detail for exported metrics of etcd, specify 'extensive' to include histogram metrics. // +optional Metrics *MetricsLevel `json:"metrics,omitempty"` // Resources defines the compute Resources required by etcd container. // More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ // +optional Resources *corev1.ResourceRequirements `json:"resources,omitempty"` // ClientUrlTLS contains the ca, server TLS and client TLS secrets for client communication to ETCD cluster // +optional ClientUrlTLS *TLSConfig `json:"clientUrlTls,omitempty"` // PeerUrlTLS contains the ca and server TLS secrets for peer communication within ETCD cluster // Currently, PeerUrlTLS does not require client TLS secrets for gardener implementation of ETCD cluster. // +optional PeerUrlTLS *TLSConfig `json:"peerUrlTls,omitempty"` // EtcdDefragTimeout defines the timeout duration for etcd defrag call // +optional EtcdDefragTimeout *metav1.Duration `json:"etcdDefragTimeout,omitempty"` // HeartbeatDuration defines the duration for members to send heartbeats. The default value is 10s. // +optional HeartbeatDuration *metav1.Duration `json:"heartbeatDuration,omitempty"` // ClientService defines the parameters of the client service that a user can specify // +optional ClientService *ClientService `json:"clientService,omitempty"` }
EtcdConfig defines the configuration for the etcd cluster to be deployed.
func (*EtcdConfig) DeepCopy ¶
func (in *EtcdConfig) DeepCopy() *EtcdConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EtcdConfig.
func (*EtcdConfig) DeepCopyInto ¶
func (in *EtcdConfig) DeepCopyInto(out *EtcdConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type EtcdCopyBackupsTask ¶ added in v0.7.0
type EtcdCopyBackupsTask struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec EtcdCopyBackupsTaskSpec `json:"spec,omitempty"` Status EtcdCopyBackupsTaskStatus `json:"status,omitempty"` }
EtcdCopyBackupsTask is a task for copying etcd backups from a source to a target store.
func (*EtcdCopyBackupsTask) DeepCopy ¶ added in v0.7.0
func (in *EtcdCopyBackupsTask) DeepCopy() *EtcdCopyBackupsTask
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EtcdCopyBackupsTask.
func (*EtcdCopyBackupsTask) DeepCopyInto ¶ added in v0.7.0
func (in *EtcdCopyBackupsTask) DeepCopyInto(out *EtcdCopyBackupsTask)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*EtcdCopyBackupsTask) DeepCopyObject ¶ added in v0.7.0
func (in *EtcdCopyBackupsTask) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*EtcdCopyBackupsTask) GetJobName ¶ added in v0.17.0
func (e *EtcdCopyBackupsTask) GetJobName() string
GetJobName returns the name of the CopyBackups Job.
type EtcdCopyBackupsTaskList ¶ added in v0.7.0
type EtcdCopyBackupsTaskList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []EtcdCopyBackupsTask `json:"items"` }
EtcdCopyBackupsTaskList contains a list of EtcdCopyBackupsTask objects.
func (*EtcdCopyBackupsTaskList) DeepCopy ¶ added in v0.7.0
func (in *EtcdCopyBackupsTaskList) DeepCopy() *EtcdCopyBackupsTaskList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EtcdCopyBackupsTaskList.
func (*EtcdCopyBackupsTaskList) DeepCopyInto ¶ added in v0.7.0
func (in *EtcdCopyBackupsTaskList) DeepCopyInto(out *EtcdCopyBackupsTaskList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*EtcdCopyBackupsTaskList) DeepCopyObject ¶ added in v0.7.0
func (in *EtcdCopyBackupsTaskList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type EtcdCopyBackupsTaskSpec ¶ added in v0.7.0
type EtcdCopyBackupsTaskSpec struct { // SourceStore defines the specification of the source object store provider for storing backups. SourceStore StoreSpec `json:"sourceStore"` // TargetStore defines the specification of the target object store provider for storing backups. TargetStore StoreSpec `json:"targetStore"` // MaxBackupAge is the maximum age in days that a backup must have in order to be copied. // By default all backups will be copied. // +optional MaxBackupAge *uint32 `json:"maxBackupAge,omitempty"` // MaxBackups is the maximum number of backups that will be copied starting with the most recent ones. // +optional MaxBackups *uint32 `json:"maxBackups,omitempty"` // WaitForFinalSnapshot defines the parameters for waiting for a final full snapshot before copying backups. // +optional WaitForFinalSnapshot *WaitForFinalSnapshotSpec `json:"waitForFinalSnapshot,omitempty"` }
EtcdCopyBackupsTaskSpec defines the parameters for the copy backups task.
func (*EtcdCopyBackupsTaskSpec) DeepCopy ¶ added in v0.7.0
func (in *EtcdCopyBackupsTaskSpec) DeepCopy() *EtcdCopyBackupsTaskSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EtcdCopyBackupsTaskSpec.
func (*EtcdCopyBackupsTaskSpec) DeepCopyInto ¶ added in v0.7.0
func (in *EtcdCopyBackupsTaskSpec) DeepCopyInto(out *EtcdCopyBackupsTaskSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type EtcdCopyBackupsTaskStatus ¶ added in v0.7.0
type EtcdCopyBackupsTaskStatus struct { // Conditions represents the latest available observations of an object's current state. // +patchMergeKey=type // +patchStrategy=merge // +optional Conditions []Condition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type"` // ObservedGeneration is the most recent generation observed for this resource. // +optional ObservedGeneration *int64 `json:"observedGeneration,omitempty"` // LastError represents the last occurred error. // +optional LastError *string `json:"lastError,omitempty"` }
EtcdCopyBackupsTaskStatus defines the observed state of the copy backups task.
func (*EtcdCopyBackupsTaskStatus) DeepCopy ¶ added in v0.7.0
func (in *EtcdCopyBackupsTaskStatus) DeepCopy() *EtcdCopyBackupsTaskStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EtcdCopyBackupsTaskStatus.
func (*EtcdCopyBackupsTaskStatus) DeepCopyInto ¶ added in v0.7.0
func (in *EtcdCopyBackupsTaskStatus) DeepCopyInto(out *EtcdCopyBackupsTaskStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type EtcdList ¶
type EtcdList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []Etcd `json:"items"` }
EtcdList contains a list of Etcd
func (*EtcdList) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EtcdList.
func (*EtcdList) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*EtcdList) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type EtcdMemberConditionStatus ¶ added in v0.7.0
type EtcdMemberConditionStatus string
EtcdMemberConditionStatus is the status of an etcd cluster member.
const ( // EtcdMemberStatusReady indicates that the etcd member is ready. EtcdMemberStatusReady EtcdMemberConditionStatus = "Ready" // EtcdMemberStatusNotReady indicates that the etcd member is not ready. EtcdMemberStatusNotReady EtcdMemberConditionStatus = "NotReady" // EtcdMemberStatusUnknown indicates that the status of the etcd member is unknown. EtcdMemberStatusUnknown EtcdMemberConditionStatus = "Unknown" )
type EtcdMemberStatus ¶ added in v0.7.0
type EtcdMemberStatus struct { // Name is the name of the etcd member. It is the name of the backing `Pod`. Name string `json:"name"` // ID is the ID of the etcd member. // +optional ID *string `json:"id,omitempty"` // Role is the role in the etcd cluster, either `Leader` or `Member`. // +optional Role *EtcdRole `json:"role,omitempty"` // Status of the condition, one of True, False, Unknown. Status EtcdMemberConditionStatus `json:"status"` // The reason for the condition's last transition. Reason string `json:"reason"` // LastTransitionTime is the last time the condition's status changed. LastTransitionTime metav1.Time `json:"lastTransitionTime"` }
EtcdMemberStatus holds information about etcd cluster membership.
func (*EtcdMemberStatus) DeepCopy ¶ added in v0.7.0
func (in *EtcdMemberStatus) DeepCopy() *EtcdMemberStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EtcdMemberStatus.
func (*EtcdMemberStatus) DeepCopyInto ¶ added in v0.7.0
func (in *EtcdMemberStatus) DeepCopyInto(out *EtcdMemberStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type EtcdRole ¶ added in v0.7.0
type EtcdRole string
EtcdRole is the role of an etcd cluster member.
type EtcdSpec ¶
type EtcdSpec struct { // selector is a label query over pods that should match the replica count. // It must match the pod template's labels. // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors Selector *metav1.LabelSelector `json:"selector"` // +required Labels map[string]string `json:"labels"` // +optional Annotations map[string]string `json:"annotations,omitempty"` // +required Etcd EtcdConfig `json:"etcd"` // +required Backup BackupSpec `json:"backup"` // +optional Common SharedConfig `json:"sharedConfig,omitempty"` // +optional SchedulingConstraints SchedulingConstraints `json:"schedulingConstraints,omitempty"` // +required Replicas int32 `json:"replicas"` // PriorityClassName is the name of a priority class that shall be used for the etcd pods. // +optional PriorityClassName *string `json:"priorityClassName,omitempty"` // StorageClass defines the name of the StorageClass required by the claim. // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1 // +optional StorageClass *string `json:"storageClass,omitempty"` // StorageCapacity defines the size of persistent volume. // +optional StorageCapacity *resource.Quantity `json:"storageCapacity,omitempty"` // VolumeClaimTemplate defines the volume claim template to be created // +optional VolumeClaimTemplate *string `json:"volumeClaimTemplate,omitempty"` }
EtcdSpec defines the desired state of Etcd
func (*EtcdSpec) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EtcdSpec.
func (*EtcdSpec) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type EtcdStatus ¶
type EtcdStatus struct { // ObservedGeneration is the most recent generation observed for this resource. // +optional ObservedGeneration *int64 `json:"observedGeneration,omitempty"` // +optional Etcd *CrossVersionObjectReference `json:"etcd,omitempty"` // Conditions represents the latest available observations of an etcd's current state. // +optional Conditions []Condition `json:"conditions,omitempty"` // ServiceName is the name of the etcd service. // Deprecated: this field will be removed in the future. // +optional ServiceName *string `json:"serviceName,omitempty"` // LastError represents the last occurred error. // Deprecated: Use LastErrors instead. // +optional LastError *string `json:"lastError,omitempty"` // LastErrors captures errors that occurred during the last operation. // +optional LastErrors []LastError `json:"lastErrors,omitempty"` // LastOperation indicates the last operation performed on this resource. // +optional LastOperation *LastOperation `json:"lastOperation,omitempty"` // Cluster size is the current size of the etcd cluster. // Deprecated: this field will not be populated with any value and will be removed in the future. // +optional ClusterSize *int32 `json:"clusterSize,omitempty"` // CurrentReplicas is the current replica count for the etcd cluster. // +optional CurrentReplicas int32 `json:"currentReplicas,omitempty"` // Replicas is the replica count of the etcd cluster. // +optional Replicas int32 `json:"replicas,omitempty"` // ReadyReplicas is the count of replicas being ready in the etcd cluster. // +optional ReadyReplicas int32 `json:"readyReplicas,omitempty"` // Ready is `true` if all etcd replicas are ready. // +optional Ready *bool `json:"ready,omitempty"` // UpdatedReplicas is the count of updated replicas in the etcd cluster. // Deprecated: this field will be removed in the future. // +optional UpdatedReplicas int32 `json:"updatedReplicas,omitempty"` // LabelSelector is a label query over pods that should match the replica count. // It must match the pod template's labels. // Deprecated: this field will be removed in the future. // +optional LabelSelector *metav1.LabelSelector `json:"labelSelector,omitempty"` // Members represents the members of the etcd cluster // +optional Members []EtcdMemberStatus `json:"members,omitempty"` // PeerUrlTLSEnabled captures the state of peer url TLS being enabled for the etcd member(s) // +optional PeerUrlTLSEnabled *bool `json:"peerUrlTLSEnabled,omitempty"` }
EtcdStatus defines the observed state of Etcd.
func (*EtcdStatus) DeepCopy ¶
func (in *EtcdStatus) DeepCopy() *EtcdStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EtcdStatus.
func (*EtcdStatus) DeepCopyInto ¶
func (in *EtcdStatus) DeepCopyInto(out *EtcdStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type GarbageCollectionPolicy ¶
type GarbageCollectionPolicy string
GarbageCollectionPolicy defines the type of policy for snapshot garbage collection. +kubebuilder:validation:Enum=Exponential;LimitBased
type LastError ¶ added in v0.23.0
type LastError struct { // Code is an error code that uniquely identifies an error. Code ErrorCode `json:"code"` // Description is a human-readable message indicating details of the error. Description string `json:"description"` // ObservedAt is the time the error was observed. ObservedAt metav1.Time `json:"observedAt"` }
LastError stores details of the most recent error encountered for a resource.
func (*LastError) DeepCopy ¶ added in v0.23.0
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LastError.
func (*LastError) DeepCopyInto ¶ added in v0.23.0
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LastOperation ¶
type LastOperation struct { // Type is the type of last operation. Type LastOperationType `json:"type"` // State is the state of the last operation. State LastOperationState `json:"state"` // Description describes the last operation. Description string `json:"description"` // RunID correlates an operation with a reconciliation run. // Every time an Etcd resource is reconciled (barring status reconciliation which is periodic), a unique ID is // generated which can be used to correlate all actions done as part of a single reconcile run. Capturing this // as part of LastOperation aids in establishing this correlation. This further helps in also easily filtering // reconcile logs as all structured logs in a reconciliation run should have the `runID` referenced. RunID string `json:"runID"` // LastUpdateTime is the time at which the operation was last updated. LastUpdateTime metav1.Time `json:"lastUpdateTime"` }
LastOperation holds the information on the last operation done on the Etcd resource.
func (*LastOperation) DeepCopy ¶
func (in *LastOperation) DeepCopy() *LastOperation
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LastOperation.
func (*LastOperation) DeepCopyInto ¶
func (in *LastOperation) DeepCopyInto(out *LastOperation)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LastOperationState ¶
type LastOperationState string
LastOperationState is a string alias representing the state of the last operation.
const ( // LastOperationStateProcessing indicates that an operation is in progress. LastOperationStateProcessing LastOperationState = "Processing" // LastOperationStateSucceeded indicates that an operation has completed successfully. LastOperationStateSucceeded LastOperationState = "Succeeded" // LastOperationStateError indicates that an operation is completed with errors and will be retried. LastOperationStateError LastOperationState = "Error" // LastOperationStateRequeue indicates that an operation is not completed and either due to an error or unfulfilled conditions will be retried. LastOperationStateRequeue LastOperationState = "Requeue" )
type LastOperationType ¶
type LastOperationType string
LastOperationType is a string alias representing type of the last operation.
const ( // LastOperationTypeCreate indicates that the last operation was a creation of a new Etcd resource. LastOperationTypeCreate LastOperationType = "Create" // LastOperationTypeReconcile indicates that the last operation was a reconciliation of the spec of an Etcd resource. LastOperationTypeReconcile LastOperationType = "Reconcile" // LastOperationTypeDelete indicates that the last operation was a deletion of an existing Etcd resource. LastOperationTypeDelete LastOperationType = "Delete" )
type LeaderElectionSpec ¶ added in v0.8.0
type LeaderElectionSpec struct { // ReelectionPeriod defines the Period after which leadership status of corresponding etcd is checked. // +optional ReelectionPeriod *metav1.Duration `json:"reelectionPeriod,omitempty"` // EtcdConnectionTimeout defines the timeout duration for etcd client connection during leader election. // +optional EtcdConnectionTimeout *metav1.Duration `json:"etcdConnectionTimeout,omitempty"` }
LeaderElectionSpec defines parameters related to the LeaderElection configuration.
func (*LeaderElectionSpec) DeepCopy ¶ added in v0.8.0
func (in *LeaderElectionSpec) DeepCopy() *LeaderElectionSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LeaderElectionSpec.
func (*LeaderElectionSpec) DeepCopyInto ¶ added in v0.8.0
func (in *LeaderElectionSpec) DeepCopyInto(out *LeaderElectionSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type MetricsLevel ¶
type MetricsLevel string
MetricsLevel defines the level 'basic' or 'extensive'. +kubebuilder:validation:Enum=basic;extensive
type SchedulingConstraints ¶ added in v0.9.0
type SchedulingConstraints struct { // Affinity defines the various affinity and anti-affinity rules for a pod // that are honoured by the kube-scheduler. // +optional Affinity *corev1.Affinity `json:"affinity,omitempty"` // TopologySpreadConstraints describes how a group of pods ought to spread across topology domains, // that are honoured by the kube-scheduler. // +optional TopologySpreadConstraints []corev1.TopologySpreadConstraint `json:"topologySpreadConstraints,omitempty"` }
SchedulingConstraints defines the different scheduling constraints that must be applied to the pod spec in the etcd statefulset. Currently supported constraints are Affinity and TopologySpreadConstraints.
func (*SchedulingConstraints) DeepCopy ¶ added in v0.9.0
func (in *SchedulingConstraints) DeepCopy() *SchedulingConstraints
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SchedulingConstraints.
func (*SchedulingConstraints) DeepCopyInto ¶ added in v0.9.0
func (in *SchedulingConstraints) DeepCopyInto(out *SchedulingConstraints)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SecretReference ¶ added in v0.8.0
type SecretReference struct { corev1.SecretReference `json:",inline"` // DataKey is the name of the key in the data map containing the credentials. // +optional DataKey *string `json:"dataKey,omitempty"` }
SecretReference defines a reference to a secret.
func (*SecretReference) DeepCopy ¶ added in v0.8.0
func (in *SecretReference) DeepCopy() *SecretReference
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecretReference.
func (*SecretReference) DeepCopyInto ¶ added in v0.8.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 SharedConfig ¶ added in v0.5.0
type SharedConfig struct { // +optional AutoCompactionMode *CompactionMode `json:"autoCompactionMode,omitempty"` // +optional AutoCompactionRetention *string `json:"autoCompactionRetention,omitempty"` }
SharedConfig defines parameters shared and used by Etcd as well as backup-restore sidecar.
func (*SharedConfig) DeepCopy ¶ added in v0.5.1
func (in *SharedConfig) DeepCopy() *SharedConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SharedConfig.
func (*SharedConfig) DeepCopyInto ¶ added in v0.5.1
func (in *SharedConfig) DeepCopyInto(out *SharedConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type StorageProvider ¶
type StorageProvider string
StorageProvider defines the type of object store provider for storing backups.
type StoreSpec ¶
type StoreSpec struct { // Container is the name of the container the backup is stored at. // +optional Container *string `json:"container,omitempty"` // Prefix is the prefix used for the store. // +required Prefix string `json:"prefix"` // Provider is the name of the backup provider. // +optional Provider *StorageProvider `json:"provider,omitempty"` // SecretRef is the reference to the secret which used to connect to the backup store. // +optional SecretRef *corev1.SecretReference `json:"secretRef,omitempty"` }
StoreSpec defines parameters related to ObjectStore persisting backups
func (*StoreSpec) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StoreSpec.
func (*StoreSpec) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type TLSConfig ¶
type TLSConfig struct { // +required TLSCASecretRef SecretReference `json:"tlsCASecretRef"` // +required ServerTLSSecretRef corev1.SecretReference `json:"serverTLSSecretRef"` // +optional ClientTLSSecretRef corev1.SecretReference `json:"clientTLSSecretRef"` }
TLSConfig hold the TLS configuration details.
func (*TLSConfig) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TLSConfig.
func (*TLSConfig) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type WaitForFinalSnapshotSpec ¶ added in v0.7.0
type WaitForFinalSnapshotSpec struct { // Enabled specifies whether to wait for a final full snapshot before copying backups. Enabled bool `json:"enabled"` // Timeout is the timeout for waiting for a final full snapshot. When this timeout expires, the copying of backups // will be performed anyway. No timeout or 0 means wait forever. // +optional Timeout *metav1.Duration `json:"timeout,omitempty"` }
WaitForFinalSnapshotSpec defines the parameters for waiting for a final full snapshot before copying backups.
func (*WaitForFinalSnapshotSpec) DeepCopy ¶ added in v0.7.0
func (in *WaitForFinalSnapshotSpec) DeepCopy() *WaitForFinalSnapshotSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WaitForFinalSnapshotSpec.
func (*WaitForFinalSnapshotSpec) DeepCopyInto ¶ added in v0.7.0
func (in *WaitForFinalSnapshotSpec) DeepCopyInto(out *WaitForFinalSnapshotSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.