Skip to content

Commit

Permalink
session: workaround for upgrade from the old master version (#39451)
Browse files Browse the repository at this point in the history
close #39450
  • Loading branch information
wjhuang2016 authored Nov 29, 2022
1 parent d2ace99 commit 2c0c130
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions session/session.go
Original file line number Diff line number Diff line change
Expand Up @@ -2898,11 +2898,17 @@ func InitMDLVariable(store kv.Storage) error {
if err != nil {
return err
}
if isNull {
// Workaround for version: nightly-2022-11-07 to nightly-2022-11-17.
enable = true
logutil.BgLogger().Warn("metadata lock is null")
err = t.SetMetadataLock(true)
if err != nil {
return err
}
}
return nil
})
if isNull {
return errors.New("metadata lock is null")
}
variable.EnableMDL.Store(enable)
return err
}
Expand Down

0 comments on commit 2c0c130

Please sign in to comment.