Skip to content
This repository has been archived by the owner on Aug 21, 2023. It is now read-only.

Commit

Permalink
try dump whole table when fail to pick field
Browse files Browse the repository at this point in the history
  • Loading branch information
lichunzhu committed Jun 30, 2021
1 parent 292cbe6 commit cfb258a
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions v4/export/dump.go
Original file line number Diff line number Diff line change
Expand Up @@ -446,13 +446,10 @@ func (d *Dumper) concurrentDumpTable(tctx *tcontext.Context, conn *sql.Conn, met
return d.concurrentDumpTiDBTables(tctx, conn, meta, taskChan)
}
field, err := pickupPossibleField(db, tbl, conn, conf)
if err != nil {
return err
}
if field == "" {
if err != nil || field == "" {
// skip split chunk logic if not found proper field
tctx.L().Warn("fallback to sequential dump due to no proper field",
zap.String("database", db), zap.String("table", tbl))
zap.String("database", db), zap.String("table", tbl), zap.Error(err))
return d.dumpWholeTableDirectly(tctx, conn, meta, taskChan, "", 0, 1)
}

Expand Down

0 comments on commit cfb258a

Please sign in to comment.