Any concept like database or bucket in TiKV to group data of different projects?

Hello Everyone,

Application environment:

We have deployed TiKV in Kubernetes using TiDB Operator (TiDB Operator Overview | PingCAP Docs). The TiDB operator version is 1.4.4 and the TiKV version is 7.1.0 and we have set up PD and TiKV with 3 replicas.

We only want to use TiKV so we have disabled TiDB and using TiKV in RAW KV mode. We have also enabled Titan inside TiKV.
The setup is working fine.

TiDB version:

v7.1.0

Reproduction method:

Currently in RawKV mode, we need to put all projects related data into TiKV at same level and we can not group it somehow.

Problem:

Is there any concept like database or bucket in TiKV to group data of different projects?

Resource allocation:

Attachment:

In TiKV, data is organized into Regions, which are the basic unit of data distribution and replication. Each Region is a range of contiguous keys, and each Region is replicated across multiple TiKV nodes using the Raft consensus algorithm .

However, there is no concept of a database or bucket in TiKV to group data of different projects. All data is stored at the same level in TiKV. If you want to group data of different projects, you can use a prefix for the keys of each project. For example, if you have two projects, project A and project B, you can use “A_” as the prefix for the keys of project A and “B_” as the prefix for the keys of project B. This way, you can easily distinguish the keys of different projects when accessing the data in TiKV .

Please note that this is just a suggestion and you need to design the key schema according to your specific requirements.

: https://docs.pingcap.com/tidb/stable/architecture-overview#tikv
: TiKV Overview | PingCAP Docs
: TiKV | Architecture