-
Notifications
You must be signed in to change notification settings - Fork 118
Description
Feature Request
Describe the feature you'd like:
Support TiKV API V2, to obtain more TiKV features such as "cross cluster replication", mixed using TiDB + TxnKV + RawKV on the same TiKV cluster, etc.
See API V2 proposal and its implementation details for detail.
Refer to tikv/tikv#10938.
Teachability, Documentation, Adoption, Migration Strategy:
Some developing features (including "Cross Cluster Replication", mixed using TiDB + TxnKV + RawKV) of TiKV depends on API V2.
We also recommend that users switch to API V2 ASAP, as most features in the future will also be based on API V2.
Data migration is required, as underlying data encoding between API V2 and the early version is quite different. Tools for migration will be provided in the near future.
Modification Required:
- Set
api_version= 2 inkvrpcpb.Context. - Prefix requesting keys by
rfor RawKV, andxfor TxnKV. - Request region info from PD with keys having
r/xprefix and Mem-comparable Padding. - Remove prefix of keys from the response if any (e.g.
raw_scan,scan).