Documentation
¶
Overview ¶
Package logical provides jobs for logical initial operations.
Package logical provides jobs for logical initial operations.
Index ¶
Constants ¶
const (
// DumpJobType declares a job type for logical dumping.
DumpJobType = "logicalDump"
)
const (
// RestoreJobType declares a job type for logical dumping.
RestoreJobType = "logicalRestore"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Connection ¶
type Connection struct {
Host string `yaml:"host"`
Port int `yaml:"port"`
DBName string `yaml:"dbname"`
Username string `yaml:"username"`
Password string `yaml:"password"`
}
Connection provides connection options.
type DumpJob ¶
type DumpJob struct {
DumpOptions
// contains filtered or unexported fields
}
DumpJob declares a job for logical dumping.
func NewDumpJob ¶
NewDumpJob creates a new DumpJob.
type DumpOptions ¶
type DumpOptions struct {
DumpLocation string `yaml:"dumpLocation"`
DockerImage string `yaml:"dockerImage"`
Connection Connection `yaml:"connection"`
Source Source `yaml:"source"`
Partial Partial `yaml:"partial"`
ParallelJobs int `yaml:"parallelJobs"`
Restore *ImmediateRestore `yaml:"immediateRestore,omitempty"`
}
DumpOptions defines a logical dump options.
type ImmediateRestore ¶
type ImmediateRestore struct {
ForceInit bool `yaml:"forceInit"`
}
ImmediateRestore contains options for direct data restore without saving the dump file on disk.
type Partial ¶
type Partial struct {
Tables []string `yaml:"tables"`
}
Partial defines tables and rules for a partial logical restore.
type RDSConfig ¶
type RDSConfig struct {
AWSRegion string `yaml:"awsRegion"`
DBInstance string `yaml:"dbInstanceIdentifier"`
SSLRootCert string `yaml:"sslRootCert"`
}
RDSConfig describes configuration of an RDS instance.
type RestoreJob ¶
type RestoreJob struct {
RestoreOptions
// contains filtered or unexported fields
}
RestoreJob defines a logical restore job.
func (*RestoreJob) Reload ¶
func (r *RestoreJob) Reload(cfg map[string]interface{}) (err error)
Reload reloads job configuration.
type RestoreOptions ¶
type RestoreOptions struct {
DumpLocation string `yaml:"dumpLocation"`
DockerImage string `yaml:"dockerImage"`
DBName string `yaml:"dbname"`
ForceInit bool `yaml:"forceInit"`
ParallelJobs int `yaml:"parallelJobs"`
Partial Partial `yaml:"partial"`
}
RestoreOptions defines a logical restore options.
type Source ¶
type Source struct {
Type string `yaml:"type"`
Connection Connection `yaml:"connection"`
RDS *RDSConfig `yaml:"rdsIam"`
}
Source describes source of data to dump.