Documentation
¶
Index ¶
- func GenName63(cr *api.PerconaXtraDBClusterBackup) string
- func NewPVC(cr *api.PerconaXtraDBClusterBackup) *corev1.PersistentVolumeClaim
- func PVCRestoreJob(cr *api.PerconaXtraDBClusterRestore, cluster api.PerconaXtraDBClusterSpec) (*batchv1.Job, error)
- func PVCRestorePod(cr *api.PerconaXtraDBClusterRestore, bcpStorageName, pvcName string, ...) (*corev1.Pod, error)
- func PVCRestoreService(cr *api.PerconaXtraDBClusterRestore) *corev1.Service
- func S3RestoreJob(cr *api.PerconaXtraDBClusterRestore, bcp *api.PerconaXtraDBClusterBackup, ...) (*batchv1.Job, error)
- type Backup
- func (*Backup) Job(cr *api.PerconaXtraDBClusterBackup, cluster *api.PerconaXtraDBCluster) *batchv1.Job
- func (bcp *Backup) JobSpec(spec api.PXCBackupSpec, cluster api.PerconaXtraDBClusterSpec, job *batchv1.Job) (batchv1.JobSpec, error)
- func (Backup) SetStoragePVC(job *batchv1.JobSpec, cr *api.PerconaXtraDBCluster, volName string) error
- func (Backup) SetStorageS3(job *batchv1.JobSpec, cr *api.PerconaXtraDBCluster, s3 api.BackupStorageS3Spec, ...) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenName63 ¶ added in v1.8.0
func GenName63(cr *api.PerconaXtraDBClusterBackup) string
GenName63 generates legit name for backup resources. k8s sets the `job-name` label for the created by job pod. So we have to be sure that job name won't be longer than 63 symbols. Yet the job name has to have some meaningful name which won't be conflicting with other jobs' names.
func NewPVC ¶
func NewPVC(cr *api.PerconaXtraDBClusterBackup) *corev1.PersistentVolumeClaim
NewPVC returns the list of PersistentVolumeClaims for the backups
func PVCRestoreJob ¶ added in v1.0.0
func PVCRestoreJob(cr *api.PerconaXtraDBClusterRestore, cluster api.PerconaXtraDBClusterSpec) (*batchv1.Job, error)
func PVCRestorePod ¶ added in v1.0.0
func PVCRestorePod(cr *api.PerconaXtraDBClusterRestore, bcpStorageName, pvcName string, cluster api.PerconaXtraDBClusterSpec) (*corev1.Pod, error)
func PVCRestoreService ¶ added in v1.0.0
func PVCRestoreService(cr *api.PerconaXtraDBClusterRestore) *corev1.Service
func S3RestoreJob ¶ added in v1.0.0
func S3RestoreJob(cr *api.PerconaXtraDBClusterRestore, bcp *api.PerconaXtraDBClusterBackup, s3dest string, cluster api.PerconaXtraDBClusterSpec, pitr bool) (*batchv1.Job, error)
S3RestoreJob returns restore job object for s3
Types ¶
type Backup ¶
type Backup struct {
// contains filtered or unexported fields
}
func New ¶
func New(cr *api.PerconaXtraDBCluster) *Backup
func (*Backup) Job ¶
func (*Backup) Job(cr *api.PerconaXtraDBClusterBackup, cluster *api.PerconaXtraDBCluster) *batchv1.Job
func (*Backup) JobSpec ¶
func (bcp *Backup) JobSpec(spec api.PXCBackupSpec, cluster api.PerconaXtraDBClusterSpec, job *batchv1.Job) (batchv1.JobSpec, error)
func (Backup) SetStoragePVC ¶ added in v0.3.0
func (Backup) SetStorageS3 ¶ added in v0.3.0
func (Backup) SetStorageS3(job *batchv1.JobSpec, cr *api.PerconaXtraDBCluster, s3 api.BackupStorageS3Spec, destination string) error
Click to show internal directories.
Click to hide internal directories.