Documentation
¶
Index ¶
- Constants
- Variables
- func BackupData(c *cli.Context) error
- func BackupDirectory(c *cli.Context) error
- func BackupDirectoryParallel(c *cli.Context) error
- func BackupFile(c *cli.Context) error
- func CleanupPlugin(c *cli.Context) error
- func DeleteBackup(c *cli.Context) error
- func DeleteDirectory(c *cli.Context) error
- func GetAPIVersion(c *cli.Context)
- func GetS3Path(folder string, path string) string
- func InitializeAndValidateConfig(config *PluginConfig) error
- func IsValidTimestamp(timestamp string) bool
- func ListDirectory(c *cli.Context) error
- func RestoreData(c *cli.Context) error
- func RestoreDirectory(c *cli.Context) error
- func RestoreDirectoryParallel(c *cli.Context) error
- func RestoreFile(c *cli.Context) error
- func SetupPluginForBackup(c *cli.Context) error
- func SetupPluginForRestore(c *cli.Context) error
- func ShouldEnableEncryption(encryption string) bool
- type CustomRetryer
- type PluginConfig
- type PluginOptions
- type Scope
Constants ¶
View Source
const DefaultConcurrency = 6
View Source
const DefaultDownloadChunkSize = int64(Mebibyte) * 500 // default 500MB
View Source
const DefaultUploadChunkSize = int64(Mebibyte) * 500 // default 500MB
View Source
const Mebibyte = 1024 * 1024
Variables ¶
View Source
var Version string
Functions ¶
func BackupData ¶
func BackupDirectory ¶
func BackupDirectoryParallel ¶
func BackupFile ¶
func CleanupPlugin ¶
func DeleteBackup ¶
func DeleteDirectory ¶
func GetAPIVersion ¶
func InitializeAndValidateConfig ¶
func InitializeAndValidateConfig(config *PluginConfig) error
func IsValidTimestamp ¶
func ListDirectory ¶
func RestoreData ¶
func RestoreDirectory ¶
func RestoreFile ¶
func SetupPluginForBackup ¶
func SetupPluginForRestore ¶
func ShouldEnableEncryption ¶
Types ¶
type CustomRetryer ¶
type CustomRetryer struct {
client.DefaultRetryer
}
CustomRetryer wraps the SDK's built in DefaultRetryer
func (CustomRetryer) ShouldRetry ¶
func (r CustomRetryer) ShouldRetry(req *request.Request) bool
ShouldRetry overrides the SDK's built in DefaultRetryer
type PluginConfig ¶
type PluginConfig struct {
ExecutablePath string `yaml:"executablepath"`
Options PluginOptions `yaml:"options"`
}
type PluginOptions ¶
type PluginOptions struct {
AwsAccessKeyId string `yaml:"aws_access_key_id"`
AwsSecretAccessKey string `yaml:"aws_secret_access_key"`
BackupMaxConcurrentRequests string `yaml:"backup_max_concurrent_requests"`
BackupMultipartChunksize string `yaml:"backup_multipart_chunksize"`
Bucket string `yaml:"bucket"`
Encryption string `yaml:"encryption"`
Endpoint string `yaml:"endpoint"`
Folder string `yaml:"folder"`
HttpProxy string `yaml:"http_proxy"`
Region string `yaml:"region"`
RemoveDuplicateBucket string `yaml:"remove_duplicate_bucket"`
RestoreMaxConcurrentRequests string `yaml:"restore_max_concurrent_requests"`
RestoreMultipartChunksize string `yaml:"restore_multipart_chunksize"`
PgPort string `yaml:"pgport"`
BackupPluginVersion string `yaml:"backup_plugin_version"`
UploadChunkSize int64
UploadConcurrency int
DownloadChunkSize int64
DownloadConcurrency int
}
Click to show internal directories.
Click to hide internal directories.