tikv/kv.go: define Lock & LockResolver before updating tidb/br (#250)

This commit is contained in:
Shirly 2021-07-23 14:26:17 +08:00 committed by GitHub
parent ac355144c8
commit fd1d7d8cdf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 11 additions and 0 deletions

View File

@ -571,3 +571,14 @@ func NewLockResolver(etcdAddrs []string, security config.Security, opts ...pd.Cl
}
return s.lockResolver, nil
}
// TODO: remove Lock&LockResolver&TxnStatus once tidb and br are ready.
// Lock represents a lock from tikv server.
type Lock = txnlock.Lock
// LockResolver resolves locks and also caches resolved txn status.
type LockResolver = txnlock.LockResolver
// TxnStatus represents a txn's final status. It should be Lock or Commit or Rollback.
type TxnStatus = txnlock.TxnStatus