backup

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Mar 9, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package backup implements the functionality of Backup methods. Package implements getFileBackupList, getMysqlBackupList, getFileList, getMysqlList, restoreFile, restoreMysql, downloadFile, downloadMysql, getLog methods. To create the appropriate methods, you need to call either CallGetFileBackupList, CallGetMysqlBackupList, CallGetFileList, CallGetMysqlList, CallRestoreFile, CallRestoreMysql, CallDownloadFile, CallDownloadMysql or CallGetLog.

Index

Constants

View Source
const (
	GetFileBackupListMethodName = "GetFileBackupList"
	GetFileBackupListMethodPath = "backup/getFileBackupList"

	GetMysqlBackupListMethodName = "GetMysqlBackupList"
	GetMysqlBackupListMethodPath = "backup/getMysqlBackupList"

	GetFileListMethodName = "GetFileList"
	GetFileListMethodPath = "backup/getFileList"

	GetMysqlListMethodName = "GetMysqlList"
	GetMysqlListMethodPath = "backup/getMysqlList"

	RestoreFileMethodName = "RestoreFile"
	RestoreFileMethodPath = "backup/restoreFile"

	RestoreMysqlMethodName = "RestoreMysql"
	RestoreMysqlMethodPath = "backup/restoreMysql"

	DownloadFileMethodName = "DownloadFile"
	DownloadFileMethodPath = "backup/downloadFile"

	DownloadMysqlMethodName = "DownloadMysql"
	DownloadMysqlMethodPath = "backup/downloadMysql"

	GetLogMethodName = "GetLog"
	GetLogMethodPath = "backup/getLog"
)

Constants used to implement the getFileBackupList, getMysqlBackupList, getFileList, getMysqlList, restoreFile, restoreMysql, downloadFile, downloadMysql, getLog methods.

Variables

This section is empty.

Functions

func CallDownloadFile

func CallDownloadFile(backupID *result.ID, paths []string) core.APIMethod[result.BoolResult]

CallDownloadFile is a creation function that returns a core.APIMethod corresponding to the method downloadFile. The function expects the backup ID from which files need to be downloaded and a list of paths from which files are downloaded. If the backup ID is a nil, the databases will be searched in the current copy.

func CallDownloadMysql

func CallDownloadMysql(backupID *result.ID, bases []result.DatabaseName) core.APIMethod[result.BoolResult]

CallDownloadMysql is a creation function that returns a core.APIMethod corresponding to the method downloadMysql. The function expects the backup ID from which data needs to be downloaded, and a list of databases whose data is being downloaded. If the backup ID is a nil, the databases will be searched in the current copy.

func CallGetFileBackupList

func CallGetFileBackupList() core.APIMethod[result.FileBackupList]

CallGetFileBackupList is a creation function that returns a core.APIMethod corresponding to the method getFileBackupList.

func CallGetFileList

func CallGetFileList(backupID *result.ID, path string) core.APIMethod[result.FileList]

CallGetFileList is a creation function that returns a core.APIMethod corresponding to the method getFileList. The function expects the backup ID, for which it is necessary to get a list of files and the path to the directory whose contents are being requested. If the backup ID is a nil, the directory will be searched in the current copy.

func CallGetLog

func CallGetLog() core.APIMethod[result.Log]

CallGetLog is a creation function that returns a core.APIMethod corresponding to the method getLog.

func CallGetMysqlBackupList

func CallGetMysqlBackupList() core.APIMethod[result.MYSQLBackupList]

CallGetMysqlBackupList is a creation function that returns a core.APIMethod corresponding to the method getMysqlBackupList.

func CallGetMysqlList

func CallGetMysqlList(backupID *result.ID) core.APIMethod[result.MYSQLList]

CallGetMysqlList is a creation function that returns a core.APIMethod corresponding to the method getMysqlList. The function expects the backup ID, for which it is necessary to get a list of databases. If the backup ID is a nil, the databases will be searched in the current copy.

func CallRestoreFile

func CallRestoreFile(backupID result.ID, paths []string) core.APIMethod[result.BoolResult]

CallRestoreFile is a creation function that returns a core.APIMethod corresponding to the method restoreFile. The function expects the backup ID from which files need to be restored and a list of paths from which files are restored.

func CallRestoreMysql

func CallRestoreMysql(backupID result.ID, bases []result.DatabaseName) core.APIMethod[result.BoolResult]

CallRestoreMysql is a creation function that returns a core.APIMethod corresponding to the method restoreMysql. The function expects the backup ID from which data needs to be restored, and a list of databases whose data is being restored.

Types

This section is empty.

Jump to

Keyboard shortcuts

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