mongo

package
v0.2.23 Latest Latest
Warning

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

Go to latest
Published: May 14, 2021 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HandleBackupDelete added in v0.2.23

func HandleBackupDelete(backupName string, downloader archive.Downloader, purger archive.Purger, dryRun bool) error

HandleBackupDelete deletes backup.

func HandleBackupFetch added in v0.2.23

func HandleBackupFetch(ctx context.Context, folder storage.Folder, backupName string, restoreCmd *exec.Cmd) error

func HandleBackupPush added in v0.2.23

func HandleBackupPush(uploader archive.Uploader,
	metaConstructor internal.MetaConstructor,
	backupCmd *exec.Cmd) error

HandleBackupPush starts backup procedure.

func HandleBackupShow added in v0.2.23

func HandleBackupShow(downloader archive.Downloader,
	backup string,
	marshaller archive.BackupInfoMarshalFunc,
	output io.Writer) error

HandleBackupPush prints sentinel contents.

func HandleBackupsList added in v0.2.23

func HandleBackupsList(downloader archive.Downloader,
	listing archive.BackupListing,
	output io.Writer,
	verbose bool) error

HandleBackupsList prints current backups.

func HandleBackupsPurge added in v0.2.23

func HandleBackupsPurge(backupTimes []internal.BackupTime,
	downloader archive.Downloader,
	purger archive.Purger,
	opts PurgeSettings) (purge, retain []models.Backup, err error)

HandleBackupsPurge delete backups according to settings

func HandleOplogPurge added in v0.2.23

func HandleOplogPurge(downloader archive.Downloader, purger archive.Purger, retainAfter *time.Time, dryRun bool) error

HandleOplogPurge delete oplog archives according to settings

func HandleOplogPush

func HandleOplogPush(ctx context.Context, fetcher stages.Fetcher, applier stages.Applier) error

HandleOplogPush starts oplog archiving process: fetch, validate, upload to storage.

func HandleOplogReplay added in v0.2.23

func HandleOplogReplay(ctx context.Context,
	since,
	until models.Timestamp,
	fetcher stages.BetweenFetcher,
	applier stages.Applier) error

HandleOplogReplay starts oplog replay process: download from storage and apply to mongodb

func HandlePurge added in v0.2.23

func HandlePurge(downloader archive.Downloader, purger archive.Purger, setters ...PurgeOption) error

HandlePurge delete backups and oplog archives according to settings

func LoadBackups added in v0.2.23

func LoadBackups(downloader archive.Downloader) ([]models.Backup, error)

Types

type PurgeOption added in v0.2.23

type PurgeOption func(*PurgeSettings)

func PurgeDryRun added in v0.2.23

func PurgeDryRun(dryRun bool) PurgeOption

PurgeDryRun ...

func PurgeGarbage added in v0.2.23

func PurgeGarbage(purgeGarbage bool) PurgeOption

PurgeGarbage ...

func PurgeOplog added in v0.2.23

func PurgeOplog(purgeOplog bool) PurgeOption

PurgeOplog ...

func PurgeRetainAfter added in v0.2.23

func PurgeRetainAfter(retainAfter time.Time) PurgeOption

PurgeRetainAfter ...

func PurgeRetainCount added in v0.2.23

func PurgeRetainCount(retainCount int) PurgeOption

PurgeRetainCount ...

type PurgeSettings added in v0.2.23

type PurgeSettings struct {
	// contains filtered or unexported fields
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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