backup

package
v1.4.0 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2020 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AgentContainer

func AgentContainer(cr *api.PerconaServerMongoDB, replsetName string, replsetSize int32) (corev1.Container, error)

AgentContainer creates the container object for a backup agent

func BackupCronJob

func BackupCronJob(backup *api.BackupTaskSpec, crName, namespace string, backupSpec api.BackupSpec, imagePullSecrets []corev1.LocalObjectReference) *batchv1b.CronJob

func HasActiveJobs added in v1.4.0

func HasActiveJobs(cl client.Client, cluster, namespace string, current Job) (bool, error)

HasActiveJobs returns true if there are running backups or restores in given cluster and namestpace

func NewBackupCronJobLabels added in v1.2.0

func NewBackupCronJobLabels(crName string) map[string]string

Types

type Job added in v1.4.0

type Job struct {
	Name string
	Type JobType
}

type JobType added in v1.4.0

type JobType int
const (
	TypeBackup JobType = iota
	TypeRestore
)

type PBM added in v1.4.0

type PBM struct {
	C *pbm.PBM
	// contains filtered or unexported fields
}

func NewPBM added in v1.4.0

func NewPBM(c client.Client, cluster *api.PerconaServerMongoDB) (*PBM, error)

NewPBM creates a new connection to PBM. It should be closed after the last use with.

func (*PBM) Close added in v1.4.0

func (b *PBM) Close() error

Close close the PBM connection

func (*PBM) SetConfig added in v1.4.0

func (b *PBM) SetConfig(stg api.BackupStorageSpec) error

SetConfig sets the pbm config with storage defined in the cluster CR by given storageName

Jump to

Keyboard shortcuts

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