Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
Signed-off-by: lance6716 <[email protected]>
  • Loading branch information
lance6716 committed Nov 25, 2024
1 parent 409958b commit 79efff2
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions ddl/index.go
Original file line number Diff line number Diff line change
Expand Up @@ -833,8 +833,12 @@ func doReorgWorkForCreateIndex(w *worker, d *ddlCtx, t *meta.Meta, job *model.Jo
}
var pdLeaderAddr string
if d != nil {
//nolint:forcetypeassert
pdLeaderAddr = d.store.(tikv.Storage).GetRegionCache().PDClient().GetLeaderAddr()
store, ok2 := d.store.(tikv.Storage)
if ok2 {
pdLeaderAddr = store.GetRegionCache().PDClient().GetLeaderAddr()
} else {
pdLeaderAddr = config.GetGlobalConfig().Path
}
}
bc, err = ingest.LitBackCtxMgr.Register(
w.ctx,
Expand Down

0 comments on commit 79efff2

Please sign in to comment.