From 1e391aa27e621a5af1044f63512a3244dfa95228 Mon Sep 17 00:00:00 2001 From: Ping Yu Date: Fri, 7 Jun 2024 16:21:48 +0800 Subject: [PATCH 1/5] Fix faq about tidb + rawkv Signed-off-by: Ping Yu --- faq/manage-cluster-faq.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/faq/manage-cluster-faq.md b/faq/manage-cluster-faq.md index 5a9cc8c54a54a..8ddc4135dfd43 100644 --- a/faq/manage-cluster-faq.md +++ b/faq/manage-cluster-faq.md @@ -415,7 +415,12 @@ The memory usage of TiKV mainly comes from the block-cache of RocksDB, which is ### Can both TiDB data and RawKV data be stored in the same TiKV cluster? -No. TiDB (or data created from the transactional API) relies on a specific key format. It is not compatible with data created from RawKV API (or data from other RawKV-based services). +Yes, but only when: + +- TiDB version >= `v6.1.0`, and +- TiKV API V2 is enabled ([`storage.api-version = 2`](/tikv-configuration-file.md#api-version-new-in-v610)). + +Otherwise, no, as key format of TiDB (or data created from the transactional API) is not compatible with data created from RawKV API (or data from other RawKV-based services). ## TiDB testing From 4e16c8303f00ac80250e90dc15c38a6bf48dea2d Mon Sep 17 00:00:00 2001 From: Ping Yu Date: Fri, 7 Jun 2024 19:13:28 +0800 Subject: [PATCH 2/5] Apply suggestions from code review Co-authored-by: Grace Cai --- faq/manage-cluster-faq.md | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/faq/manage-cluster-faq.md b/faq/manage-cluster-faq.md index 8ddc4135dfd43..8a47e5048fb6b 100644 --- a/faq/manage-cluster-faq.md +++ b/faq/manage-cluster-faq.md @@ -415,12 +415,10 @@ The memory usage of TiKV mainly comes from the block-cache of RocksDB, which is ### Can both TiDB data and RawKV data be stored in the same TiKV cluster? -Yes, but only when: +It depends on your TiDB version and whether TiKV API V2 ([`storage.api-version = 2`](/tikv-configuration-file.md#api-version-new-in-v610)) is enabled. -- TiDB version >= `v6.1.0`, and -- TiKV API V2 is enabled ([`storage.api-version = 2`](/tikv-configuration-file.md#api-version-new-in-v610)). - -Otherwise, no, as key format of TiDB (or data created from the transactional API) is not compatible with data created from RawKV API (or data from other RawKV-based services). +- If your TiDB version is v6.1.0 or later and TiKV API V2 is enabled, TiDB data and RawKV data can be stored in the same TiKV cluster. +- Otherwise, the answer is no because the key format of TiDB (or data created using the transactional API) is incompatible with data created using the RawKV API (or data from other RawKV-based services). ## TiDB testing From 7306c79e3f01c30426e1b74d30ff54f22a00de1f Mon Sep 17 00:00:00 2001 From: Grace Cai Date: Tue, 11 Jun 2024 09:45:44 +0800 Subject: [PATCH 3/5] Update faq/manage-cluster-faq.md --- faq/manage-cluster-faq.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/faq/manage-cluster-faq.md b/faq/manage-cluster-faq.md index 8a47e5048fb6b..e3ca7d5c14f7c 100644 --- a/faq/manage-cluster-faq.md +++ b/faq/manage-cluster-faq.md @@ -415,7 +415,7 @@ The memory usage of TiKV mainly comes from the block-cache of RocksDB, which is ### Can both TiDB data and RawKV data be stored in the same TiKV cluster? -It depends on your TiDB version and whether TiKV API V2 ([`storage.api-version = 2`](/tikv-configuration-file.md#api-version-new-in-v610)) is enabled. +It depends on your TiDB version and whether TiKV API V2 is enabled ([`storage.api-version = 2`](/tikv-configuration-file.md#api-version-new-in-v610)) . - If your TiDB version is v6.1.0 or later and TiKV API V2 is enabled, TiDB data and RawKV data can be stored in the same TiKV cluster. - Otherwise, the answer is no because the key format of TiDB (or data created using the transactional API) is incompatible with data created using the RawKV API (or data from other RawKV-based services). From 8f9b453438046585da7f67db7b24f54c7cda2a69 Mon Sep 17 00:00:00 2001 From: Grace Cai Date: Tue, 11 Jun 2024 10:57:53 +0800 Subject: [PATCH 4/5] Update faq/manage-cluster-faq.md --- faq/manage-cluster-faq.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/faq/manage-cluster-faq.md b/faq/manage-cluster-faq.md index e3ca7d5c14f7c..7f8b220ef3f84 100644 --- a/faq/manage-cluster-faq.md +++ b/faq/manage-cluster-faq.md @@ -415,7 +415,7 @@ The memory usage of TiKV mainly comes from the block-cache of RocksDB, which is ### Can both TiDB data and RawKV data be stored in the same TiKV cluster? -It depends on your TiDB version and whether TiKV API V2 is enabled ([`storage.api-version = 2`](/tikv-configuration-file.md#api-version-new-in-v610)) . +It depends on your TiDB version and whether TiKV API V2 is enabled ([`storage.api-version = 2`](/tikv-configuration-file.md#api-version-new-in-v610)). - If your TiDB version is v6.1.0 or later and TiKV API V2 is enabled, TiDB data and RawKV data can be stored in the same TiKV cluster. - Otherwise, the answer is no because the key format of TiDB (or data created using the transactional API) is incompatible with data created using the RawKV API (or data from other RawKV-based services). From 5654c545b204f0fa66fc474b025bc0aa2580c41d Mon Sep 17 00:00:00 2001 From: Grace Cai Date: Tue, 11 Jun 2024 14:02:08 +0800 Subject: [PATCH 5/5] Update faq/manage-cluster-faq.md --- faq/manage-cluster-faq.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/faq/manage-cluster-faq.md b/faq/manage-cluster-faq.md index 7f8b220ef3f84..4fcdca9f04551 100644 --- a/faq/manage-cluster-faq.md +++ b/faq/manage-cluster-faq.md @@ -418,7 +418,7 @@ The memory usage of TiKV mainly comes from the block-cache of RocksDB, which is It depends on your TiDB version and whether TiKV API V2 is enabled ([`storage.api-version = 2`](/tikv-configuration-file.md#api-version-new-in-v610)). - If your TiDB version is v6.1.0 or later and TiKV API V2 is enabled, TiDB data and RawKV data can be stored in the same TiKV cluster. -- Otherwise, the answer is no because the key format of TiDB (or data created using the transactional API) is incompatible with data created using the RawKV API (or data from other RawKV-based services). +- Otherwise, the answer is no because the key format of TiDB data (or data created using the transactional API) is incompatible with data created using the RawKV API (or data from other RawKV-based services). ## TiDB testing