We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 956efe7 commit 10697d0Copy full SHA for 10697d0
1 file changed
pkg/restore/client.go
@@ -718,6 +718,14 @@ func (rc *Client) SwitchToImportMode(ctx context.Context) {
718
// so we need ping tikv in less than 10 minute
719
go func() {
720
tick := time.NewTicker(rc.switchModeInterval)
721
+ defer tick.Stop()
722
+
723
+ // [important!] switch tikv mode into import at the beginning
724
+ log.Info("switch to import mode at beginning")
725
+ err := rc.switchTiKVMode(ctx, import_sstpb.SwitchMode_Import)
726
+ if err != nil {
727
+ log.Warn("switch to import mode failed", zap.Error(err))
728
+ }
729
730
for {
731
select {
0 commit comments