v1alpha1

package
v0.0.0-...-009d52b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 18, 2024 License: BSD-3-Clause, Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package v1alpha1 defines the types for the MySQL Operator v1alpha1 API.

Index

Constants

View Source
const (
	// DefaultVersion is the MySQL version to use if not specified explicitly by user
	DefaultVersion = "8.0.12"

	// MysqlServer is the image to use if no image is specified explicitly by the user.
	MysqlServer = "mysql/mysql-server"
)
View Source
const (
	// MaxInnoDBClusterMembers is the maximum number of members supported by InnoDB
	// group replication.
	MaxInnoDBClusterMembers = 9

	// ClusterNameMaxLen is the maximum supported length of a
	// Cluster name.
	// See: https://bugs.mysql.com/bug.php?id=90601
	ClusterNameMaxLen = 28
)
View Source
const (
	// ClusterCRDResourceKind is the Kind of a Cluster.
	ClusterCRDResourceKind = "Cluster"
	// BackupCRDResourceKind is the Kind of a Backup.
	BackupCRDResourceKind = "Backup"
	// RestoreCRDResourceKind is the Kind of a Restore.
	RestoreCRDResourceKind = "Restore"
	// BackupScheduleCRDResourceKind is the Kind of a BackupSchedule.
	BackupScheduleCRDResourceKind = "BackupSchedule"
)
View Source
const GroupName = "mysql.oracle.com"

GroupName is the group name for the MySQL Operator API.

View Source
const MinimumMySQLVersion = "8.0.11"

MinimumMySQLVersion is the minimum version of MySQL server supported by the MySQL Operator.

Variables

View Source
var (
	// SchemeBuilder collects the scheme builder functions for the MySQL
	// Operator API.
	SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)

	// AddToScheme applies the SchemeBuilder functions to a specified scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)
View Source
var ExecutorProviders = []string{"mysqldump"}

ExecutorProviders denotes the list of valid backup executor providers.

View Source
var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"}

SchemeGroupVersion is the GroupVersion for the MySQL Operator API.

Functions

func Resource

func Resource(resource string) schema.GroupResource

Resource gets a MySQL Operator GroupResource for a specified resource.

Types

type Backup

type Backup struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata"`

	Spec   BackupSpec   `json:"spec"`
	Status BackupStatus `json:"status"`
}

Backup is a backup of a Cluster.

func (*Backup) DeepCopy

func (in *Backup) DeepCopy() *Backup

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Backup.

func (*Backup) DeepCopyInto

func (in *Backup) DeepCopyInto(out *Backup)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Backup) DeepCopyObject

func (in *Backup) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (Backup) EnsureDefaults

func (b Backup) EnsureDefaults() *Backup

EnsureDefaults can be invoked to ensure the default values are present.

func (Backup) Validate

func (b Backup) Validate() error

Validate checks if the resource spec is valid.

type BackupCondition

type BackupCondition struct {
	Type   BackupConditionType
	Status corev1.ConditionStatus
	// +optional
	LastTransitionTime metav1.Time
	// +optional
	Reason string
	// +optional
	Message string
}

BackupCondition describes the observed state of a Backup at a certain point.

func (*BackupCondition) DeepCopy

func (in *BackupCondition) DeepCopy() *BackupCondition

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BackupCondition.

func (*BackupCondition) DeepCopyInto

func (in *BackupCondition) DeepCopyInto(out *BackupCondition)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type BackupConditionType

type BackupConditionType string

BackupConditionType represents a valid condition of a Backup.

const (
	// BackupScheduled means the Backup has been assigned to a Cluster
	// member for execution.
	BackupScheduled BackupConditionType = "Scheduled"
	// BackupRunning means the Backup is currently being executed by a
	// Cluster member's mysql-agent side-car.
	BackupRunning BackupConditionType = "Running"
	// BackupComplete means the Backup has successfully executed and the
	// resulting artifact has been stored in object storage.
	BackupComplete BackupConditionType = "Complete"
	// BackupFailed means the Backup has failed.
	BackupFailed BackupConditionType = "Failed"
)

type BackupExecutor

type BackupExecutor struct {
	MySQLDump *MySQLDumpBackupExecutor `json:"mysqldump"`
}

BackupExecutor represents the configuration of the tool performing the backup. This includes the tool to use, and, what database and tables should be backed up. The storage of the backup is configured in the relevant Storage configuration.

func (*BackupExecutor) DeepCopy

func (in *BackupExecutor) DeepCopy() *BackupExecutor

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BackupExecutor.

func (*BackupExecutor) DeepCopyInto

func (in *BackupExecutor) DeepCopyInto(out *BackupExecutor)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type BackupList

type BackupList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []Backup `json:"items"`
}

BackupList is a list of Backups.

func (*BackupList) DeepCopy

func (in *BackupList) DeepCopy() *BackupList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BackupList.

func (*BackupList) DeepCopyInto

func (in *BackupList) DeepCopyInto(out *BackupList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*BackupList) DeepCopyObject

func (in *BackupList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type BackupOutcome

type BackupOutcome struct {
	// Location is the Object Storage network location of the Backup.
	Location string `json:"location"`
}

BackupOutcome describes the location of a Backup

func (*BackupOutcome) DeepCopy

func (in *BackupOutcome) DeepCopy() *BackupOutcome

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BackupOutcome.

func (*BackupOutcome) DeepCopyInto

func (in *BackupOutcome) DeepCopyInto(out *BackupOutcome)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type BackupSchedule

type BackupSchedule struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata"`

	Spec   BackupScheduleSpec `json:"spec"`
	Status ScheduleStatus     `json:"status,omitempty"`
}

BackupSchedule is a backup schedule for a Cluster.

func (*BackupSchedule) DeepCopy

func (in *BackupSchedule) DeepCopy() *BackupSchedule

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BackupSchedule.

func (*BackupSchedule) DeepCopyInto

func (in *BackupSchedule) DeepCopyInto(out *BackupSchedule)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*BackupSchedule) DeepCopyObject

func (in *BackupSchedule) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (BackupSchedule) EnsureDefaults

func (b BackupSchedule) EnsureDefaults() *BackupSchedule

EnsureDefaults can be invoked to ensure the default values are present.

func (BackupSchedule) Validate

func (b BackupSchedule) Validate() error

Validate checks if the resource spec is valid.

type BackupScheduleList

type BackupScheduleList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []BackupSchedule `json:"items"`
}

BackupScheduleList is a list of BackupSchedules.

func (*BackupScheduleList) DeepCopy

func (in *BackupScheduleList) DeepCopy() *BackupScheduleList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BackupScheduleList.

func (*BackupScheduleList) DeepCopyInto

func (in *BackupScheduleList) DeepCopyInto(out *BackupScheduleList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*BackupScheduleList) DeepCopyObject

func (in *BackupScheduleList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type BackupScheduleSpec

type BackupScheduleSpec struct {
	// Schedule specifies the cron string used for backup scheduling.
	Schedule string `json:"schedule"`

	// BackupTemplate is the specification of the backup structure
	// to get scheduled.
	BackupTemplate BackupSpec `json:"backupTemplate"`
}

BackupScheduleSpec defines the specification for a MySQL backup schedule.

func (*BackupScheduleSpec) DeepCopy

func (in *BackupScheduleSpec) DeepCopy() *BackupScheduleSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BackupScheduleSpec.

func (*BackupScheduleSpec) DeepCopyInto

func (in *BackupScheduleSpec) DeepCopyInto(out *BackupScheduleSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type BackupSpec

type BackupSpec struct {
	// Executor is the configuration of the tool that will produce the backup, and a definition of
	// what databases and tables to backup.
	Executor BackupExecutor `json:"executor"`
	// StorageProvider configures where and how backups should be stored.
	StorageProvider StorageProvider `json:"storageProvider"`
	// Cluster is the Cluster to backup.
	Cluster *corev1.LocalObjectReference `json:"cluster"`
	// ScheduledMember is the Pod name of the Cluster member on which the
	// Backup will be executed.
	ScheduledMember string `json:"scheduledMember"`
}

BackupSpec defines the specification for a MySQL backup. This includes what should be backed up, what tool should perform the backup, and, where the backup should be stored.

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 BackupStatus

type BackupStatus struct {
	// Outcome holds the results of a successful backup.
	// +optional
	Outcome BackupOutcome `json:"outcome"`
	// TimeStarted is the time at which the backup was started.
	// +optional
	TimeStarted metav1.Time `json:"timeStarted"`
	// TimeCompleted is the time at which the backup completed.
	// +optional
	TimeCompleted metav1.Time `json:"timeCompleted"`
	// +optional
	Conditions []BackupCondition
}

BackupStatus captures the current status of a Backup.

func (*BackupStatus) DeepCopy

func (in *BackupStatus) DeepCopy() *BackupStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BackupStatus.

func (*BackupStatus) DeepCopyInto

func (in *BackupStatus) DeepCopyInto(out *BackupStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Cluster

type Cluster struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata"`

	Spec   ClusterSpec   `json:"spec"`
	Status ClusterStatus `json:"status"`
}

Cluster represents a cluster spec and associated metadata

func (*Cluster) DeepCopy

func (in *Cluster) DeepCopy() *Cluster

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Cluster.

func (*Cluster) DeepCopyInto

func (in *Cluster) DeepCopyInto(out *Cluster)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Cluster) DeepCopyObject

func (in *Cluster) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*Cluster) EnsureDefaults

func (c *Cluster) EnsureDefaults() *Cluster

EnsureDefaults will ensure that if a user omits any fields in the spec that are required, we set some sensible defaults. For example a user can choose to omit the version and number of members.

func (*Cluster) RequiresConfigMount

func (c *Cluster) RequiresConfigMount() bool

RequiresConfigMount will return true if a user has specified a config map for configuring the cluster else false

func (*Cluster) RequiresCustomSSLSetup

func (c *Cluster) RequiresCustomSSLSetup() bool

RequiresCustomSSLSetup returns true is the user has provided a secret that contains CA cert, server cert and server key for group replication SSL support

func (*Cluster) RequiresSecret

func (c *Cluster) RequiresSecret() bool

RequiresSecret returns true if a secret should be generated for a MySQL cluster else false

func (*Cluster) Validate

func (c *Cluster) Validate() error

Validate returns an error if a cluster is invalid

type ClusterCondition

type ClusterCondition struct {
	Type   ClusterConditionType
	Status corev1.ConditionStatus
	// +optional
	LastTransitionTime metav1.Time
	// +optional
	Reason string
	// +optional
	Message string
}

ClusterCondition describes the observed state of a Cluster at a certain point.

func (*ClusterCondition) DeepCopy

func (in *ClusterCondition) DeepCopy() *ClusterCondition

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterCondition.

func (*ClusterCondition) DeepCopyInto

func (in *ClusterCondition) DeepCopyInto(out *ClusterCondition)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ClusterConditionType

type ClusterConditionType string

ClusterConditionType represents a valid condition of a Cluster.

const (
	// ClusterReady means the Cluster is able to service requests.
	ClusterReady ClusterConditionType = "Ready"
)

type ClusterList

type ClusterList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []Cluster `json:"items"`
}

ClusterList is a placeholder type for a list of MySQL clusters

func (*ClusterList) DeepCopy

func (in *ClusterList) DeepCopy() *ClusterList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterList.

func (*ClusterList) DeepCopyInto

func (in *ClusterList) DeepCopyInto(out *ClusterList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ClusterList) DeepCopyObject

func (in *ClusterList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ClusterSpec

type ClusterSpec struct {
	// Version defines the MySQL Docker image version.
	Version string `json:"version"`
	// Repository defines the image repository from which to pull the MySQL server image.
	Repository string `json:"repository"`
	// ImagePullSecret defines the name of the secret that contains the
	// required credentials for pulling from the specified Repository.
	ImagePullSecrets []corev1.LocalObjectReference `json:"imagePullSecret"`
	// Members defines the number of MySQL instances in a cluster
	Members int32 `json:"members,omitempty"`
	// BaseServerID defines the base number used to create unique server_id
	// for MySQL instances in the cluster. Valid range 1 to 4294967286.
	// If omitted in the manifest file (or set to 0) defaultBaseServerID
	// value will be used.
	BaseServerID uint32 `json:"baseServerId,omitempty"`
	// MultiMaster defines the mode of the MySQL cluster. If set to true,
	// all instances will be R/W. If false (the default), only a single instance
	// will be R/W and the rest will be R/O.
	MultiMaster bool `json:"multiMaster,omitempty"`
	// NodeSelector is a selector which must be true for the pod to fit on a node.
	// Selector which must match a node's labels for the pod to be scheduled on that node.
	// More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/
	// +optional
	NodeSelector map[string]string `json:"nodeSelector,omitempty"`
	// If specified, affinity will define the pod's scheduling constraints
	// +optional
	Affinity *corev1.Affinity `json:"affinity,omitempty"`
	// VolumeClaimTemplate allows a user to specify how volumes inside a MySQL cluster
	// +optional
	VolumeClaimTemplate *corev1.PersistentVolumeClaim `json:"volumeClaimTemplate,omitempty"`
	// BackupVolumeClaimTemplate allows a user to specify a volume to temporarily store the
	// data for a backup prior to it being shipped to object storage.
	// +optional
	BackupVolumeClaimTemplate *corev1.PersistentVolumeClaim `json:"backupVolumeClaimTemplate,omitempty"`
	// If defined, we use this secret for configuring the MYSQL_ROOT_PASSWORD
	// If it is not set we generate a secret dynamically
	// +optional
	RootPasswordSecret *corev1.LocalObjectReference `json:"rootPasswordSecret,omitempty"`
	// Config allows a user to specify a custom configuration file for MySQL.
	// +optional
	Config *corev1.LocalObjectReference `json:"config,omitempty"`
	// SSLSecret allows a user to specify custom CA certificate, server certificate
	// and server key for group replication SSL.
	// +optional
	SSLSecret *corev1.LocalObjectReference `json:"sslSecret,omitempty"`
	// SecurityContext holds Pod-level security attributes and common Container settings.
	SecurityContext *corev1.PodSecurityContext `json:"securityContext,omitempty"`
	// Tolerations allows specifying a list of tolerations for controlling which
	// set of Nodes a Pod can be scheduled on
	Tolerations *[]corev1.Toleration `json:"tolerations,omitempty"`
	// Resources holds ResourceRequirements for the MySQL Agent & Server Containers
	Resources *Resources `json:"resources,omitempty"`
}

ClusterSpec defines the attributes a user can specify when creating a cluster

func (*ClusterSpec) DeepCopy

func (in *ClusterSpec) DeepCopy() *ClusterSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterSpec.

func (*ClusterSpec) DeepCopyInto

func (in *ClusterSpec) DeepCopyInto(out *ClusterSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ClusterStatus

type ClusterStatus struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata"`

	// +optional
	Conditions []ClusterCondition
}

ClusterStatus defines the current status of a MySQL cluster propagating useful information back to the cluster admin

func (*ClusterStatus) DeepCopy

func (in *ClusterStatus) DeepCopy() *ClusterStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterStatus.

func (*ClusterStatus) DeepCopyInto

func (in *ClusterStatus) DeepCopyInto(out *ClusterStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Database

type Database struct {
	Name string `json:"name"`
}

Database represents a database to backup.

func (*Database) DeepCopy

func (in *Database) DeepCopy() *Database

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Database.

func (*Database) DeepCopyInto

func (in *Database) DeepCopyInto(out *Database)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MySQLDumpBackupExecutor

type MySQLDumpBackupExecutor struct {
	Databases []Database `json:"databases"`
}

MySQLDumpBackupExecutor executes backups using mysqldump.

func (*MySQLDumpBackupExecutor) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MySQLDumpBackupExecutor.

func (*MySQLDumpBackupExecutor) DeepCopyInto

func (in *MySQLDumpBackupExecutor) DeepCopyInto(out *MySQLDumpBackupExecutor)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Resources

type Resources struct {
	Agent  *corev1.ResourceRequirements `json:"agent,omitempty"`
	Server *corev1.ResourceRequirements `json:"server,omitempty"`
}

Resources holds ResourceRequirements for the MySQL Agent & Server Containers

func (*Resources) DeepCopy

func (in *Resources) DeepCopy() *Resources

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Resources.

func (*Resources) DeepCopyInto

func (in *Resources) DeepCopyInto(out *Resources)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Restore

type Restore struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata"`

	Spec   RestoreSpec   `json:"spec"`
	Status RestoreStatus `json:"status"`
}

Restore is a MySQL Operator resource that represents the restoration of backup of a MySQL cluster.

func (*Restore) DeepCopy

func (in *Restore) DeepCopy() *Restore

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Restore.

func (*Restore) DeepCopyInto

func (in *Restore) DeepCopyInto(out *Restore)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Restore) DeepCopyObject

func (in *Restore) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (Restore) EnsureDefaults

func (r Restore) EnsureDefaults() *Restore

EnsureDefaults can be invoked to ensure the default values are present.

func (Restore) Validate

func (r Restore) Validate() error

Validate checks if the resource spec is valid.

type RestoreCondition

type RestoreCondition struct {
	Type   RestoreConditionType
	Status corev1.ConditionStatus
	// +optional
	LastTransitionTime metav1.Time
	// +optional
	Reason string
	// +optional
	Message string
}

RestoreCondition describes the observed state of a Restore at a certain point.

func (*RestoreCondition) DeepCopy

func (in *RestoreCondition) DeepCopy() *RestoreCondition

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RestoreCondition.

func (*RestoreCondition) DeepCopyInto

func (in *RestoreCondition) DeepCopyInto(out *RestoreCondition)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RestoreConditionType

type RestoreConditionType string

RestoreConditionType represents a valid condition of a Restore.

const (
	// RestoreScheduled means the Restore has been assigned to a Cluster
	// member for execution.
	RestoreScheduled RestoreConditionType = "Scheduled"
	// RestoreRunning means the Restore is currently being executed by a
	// Cluster member's mysql-agent side-car.
	RestoreRunning RestoreConditionType = "Running"
	// RestoreComplete means the Restore has successfully executed and the
	// resulting artifact has been stored in object storage.
	RestoreComplete RestoreConditionType = "Complete"
	// RestoreFailed means the Restore has failed.
	RestoreFailed RestoreConditionType = "Failed"
)

type RestoreList

type RestoreList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []Restore `json:"items"`
}

RestoreList is a list of Restores.

func (*RestoreList) DeepCopy

func (in *RestoreList) DeepCopy() *RestoreList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RestoreList.

func (*RestoreList) DeepCopyInto

func (in *RestoreList) DeepCopyInto(out *RestoreList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*RestoreList) DeepCopyObject

func (in *RestoreList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type RestoreSpec

type RestoreSpec struct {
	// Cluster is a refeference to the Cluster to which the Restore
	// belongs.
	Cluster *corev1.LocalObjectReference `json:"cluster"`
	// Backup is a reference to the Backup object to be restored.
	Backup *corev1.LocalObjectReference `json:"backup"`
	// ScheduledMember is the Pod name of the Cluster member on which the
	// Restore will be executed.
	ScheduledMember string `json:"scheduledMember"`
}

RestoreSpec defines the specification for a restore of a MySQL backup.

func (*RestoreSpec) DeepCopy

func (in *RestoreSpec) DeepCopy() *RestoreSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RestoreSpec.

func (*RestoreSpec) DeepCopyInto

func (in *RestoreSpec) DeepCopyInto(out *RestoreSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RestoreStatus

type RestoreStatus struct {
	// TimeStarted is the time at which the restore was started.
	// +optional
	TimeStarted metav1.Time `json:"timeStarted"`
	// TimeCompleted is the time at which the restore completed.
	// +optional
	TimeCompleted metav1.Time `json:"timeCompleted"`
	// +optional
	Conditions []RestoreCondition
}

RestoreStatus captures the current status of a MySQL restore.

func (*RestoreStatus) DeepCopy

func (in *RestoreStatus) DeepCopy() *RestoreStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RestoreStatus.

func (*RestoreStatus) DeepCopyInto

func (in *RestoreStatus) DeepCopyInto(out *RestoreStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type S3StorageProvider

type S3StorageProvider struct {
	// Region in which the S3 compatible bucket is located.
	Region string `json:"region"`
	// Endpoint (hostname only or fully qualified URI) of S3 compatible
	// storage service.
	Endpoint string `json:"endpoint"`
	// Bucket in which to store the Backup.
	Bucket string `json:"bucket"`
	// ForcePathStyle when set to true forces the request to use path-style
	// addressing, i.e., `http://s3.amazonaws.com/BUCKET/KEY`. By default,
	// the S3 client will use virtual hosted bucket addressing when possible
	// (`http://BUCKET.s3.amazonaws.com/KEY`).
	ForcePathStyle bool `json:"forcePathStyle"`
	// CredentialsSecret is a reference to the Secret containing the
	// credentials authenticating with the S3 compatible storage service.
	CredentialsSecret *corev1.LocalObjectReference `json:"credentialsSecret"`
}

S3StorageProvider represents an S3 compatible bucket for storing Backups.

func (*S3StorageProvider) DeepCopy

func (in *S3StorageProvider) DeepCopy() *S3StorageProvider

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new S3StorageProvider.

func (*S3StorageProvider) DeepCopyInto

func (in *S3StorageProvider) DeepCopyInto(out *S3StorageProvider)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ScheduleStatus

type ScheduleStatus struct {
	// LastBackup is the last time a Backup was run for this
	// backup schedule.
	// +optional
	LastBackup metav1.Time `json:"lastBackup"`
}

ScheduleStatus captures the current state of a MySQL backup schedule.

func (*ScheduleStatus) DeepCopy

func (in *ScheduleStatus) DeepCopy() *ScheduleStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ScheduleStatus.

func (*ScheduleStatus) DeepCopyInto

func (in *ScheduleStatus) DeepCopyInto(out *ScheduleStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type StorageProvider

type StorageProvider struct {
	S3 *S3StorageProvider `json:"s3"`
}

StorageProvider defines the configuration for storing a Backup in a storage service.

func (*StorageProvider) DeepCopy

func (in *StorageProvider) DeepCopy() *StorageProvider

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StorageProvider.

func (*StorageProvider) DeepCopyInto

func (in *StorageProvider) DeepCopyInto(out *StorageProvider)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL