Skip to content

Commit

Permalink
brie: set default config for backup and restore (#18774)
Browse files Browse the repository at this point in the history
  • Loading branch information
3pointer authored Jul 24, 2020
1 parent c8b3f2d commit 0529b1b
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions executor/brie.go
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,7 @@ func (b *executorBuilder) buildBRIE(s *ast.BRIEStmt, schema *expression.Schema)
switch s.Kind {
case ast.BRIEKindBackup:
e.backupCfg = &task.BackupConfig{Config: cfg}
// TODO adapt new backup config in br.
e.backupCfg.GCTTL = backup.DefaultBRGCSafePointTTL

for _, opt := range s.Options {
Expand Down Expand Up @@ -279,6 +280,10 @@ func (b *executorBuilder) buildBRIE(s *ast.BRIEStmt, schema *expression.Schema)

case ast.BRIEKindRestore:
e.restoreCfg = &task.RestoreConfig{Config: cfg}
// TODO adapt new restore config in br. now give these with default value
e.restoreCfg.SwitchModeInterval = backup.DefaultBRGCSafePointTTL
e.restoreCfg.CheckRequirements = false
e.restoreCfg.RemoveTiFlash = true
for _, opt := range s.Options {
switch opt.Tp {
case ast.BRIEOptionOnline:
Expand Down

0 comments on commit 0529b1b

Please sign in to comment.