From 5ea10dff8492dcd391871563c5c25f6fb6bc8c69 Mon Sep 17 00:00:00 2001 From: glorv Date: Thu, 5 Sep 2024 10:58:07 +0800 Subject: [PATCH 1/4] add new dynamic configure for flow-control --- dynamic-config.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/dynamic-config.md b/dynamic-config.md index 4eed6ab9163b5..7d7b70af3b49e 100644 --- a/dynamic-config.md +++ b/dynamic-config.md @@ -218,6 +218,11 @@ The following TiKV configuration items can be modified dynamically: | `server.raft-msg-max-batch-size` | Sets the maximum number of Raft messages that are contained in a single gRPC message | | `server.simplify-metrics` | Controls whether to simplify the sampling monitoring metrics | | `storage.block-cache.capacity` | The size of shared block cache (supported since v4.0.3) | +| storage.flow-control.enable | Determines whether to enable the flow control mechanism. | +| storage.flow-control.memtables-threshold | The threshold of kvDB memtable numbers that triggers flow control. | +| storage.flow-control.l0-files-threshold | The threshold of kvDB L0 file numbers that triggers flow control. | +| storage.flow-control.soft-pending-compaction-bytes-limit | The threshold of kvDB pending compaction bytes that triggers flow control. | +| storage.flow-control.hard-pending-compaction-bytes-limit | The threshold of kvDB pending compaction bytes that triggers flow control mechanism to reject all write requests and reports the `ServerIsBusy` error. | | `storage.scheduler-worker-pool-size` | The number of threads in the Scheduler thread pool | | `backup.num-threads` | The number of backup threads (supported since v4.0.3) | | `split.qps-threshold` | The threshold to execute `load-base-split` on a Region. If the QPS of read requests for a Region exceeds `qps-threshold` for 10 consecutive seconds, this Region should be split.| From 1bd14a82af6aa4a9419409f2723dfe5f0f27fbfe Mon Sep 17 00:00:00 2001 From: Aolin Date: Tue, 10 Sep 2024 11:30:45 +0800 Subject: [PATCH 2/4] Apply suggestions from code review --- dynamic-config.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/dynamic-config.md b/dynamic-config.md index 7d7b70af3b49e..e2d61adf8a2a6 100644 --- a/dynamic-config.md +++ b/dynamic-config.md @@ -218,11 +218,11 @@ The following TiKV configuration items can be modified dynamically: | `server.raft-msg-max-batch-size` | Sets the maximum number of Raft messages that are contained in a single gRPC message | | `server.simplify-metrics` | Controls whether to simplify the sampling monitoring metrics | | `storage.block-cache.capacity` | The size of shared block cache (supported since v4.0.3) | -| storage.flow-control.enable | Determines whether to enable the flow control mechanism. | -| storage.flow-control.memtables-threshold | The threshold of kvDB memtable numbers that triggers flow control. | -| storage.flow-control.l0-files-threshold | The threshold of kvDB L0 file numbers that triggers flow control. | -| storage.flow-control.soft-pending-compaction-bytes-limit | The threshold of kvDB pending compaction bytes that triggers flow control. | -| storage.flow-control.hard-pending-compaction-bytes-limit | The threshold of kvDB pending compaction bytes that triggers flow control mechanism to reject all write requests and reports the `ServerIsBusy` error. | +| storage.flow-control.enable | Determines whether to enable the flow control mechanism | +| storage.flow-control.memtables-threshold | The threshold of kvDB memtable numbers that triggers flow control | +| storage.flow-control.l0-files-threshold | The threshold of kvDB L0 file numbers that triggers flow control | +| storage.flow-control.soft-pending-compaction-bytes-limit | The threshold of kvDB pending compaction bytes that triggers flow control | +| storage.flow-control.hard-pending-compaction-bytes-limit | The threshold of kvDB pending compaction bytes that triggers flow control mechanism to reject all write requests and report the `ServerIsBusy` error | | `storage.scheduler-worker-pool-size` | The number of threads in the Scheduler thread pool | | `backup.num-threads` | The number of backup threads (supported since v4.0.3) | | `split.qps-threshold` | The threshold to execute `load-base-split` on a Region. If the QPS of read requests for a Region exceeds `qps-threshold` for 10 consecutive seconds, this Region should be split.| From 52662f27ae4637d68e1fecaf89ed7c1f841b392b Mon Sep 17 00:00:00 2001 From: glorv Date: Fri, 27 Sep 2024 16:56:27 +0800 Subject: [PATCH 3/4] Apply suggestions from code review Co-authored-by: Grace Cai --- dynamic-config.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/dynamic-config.md b/dynamic-config.md index e2d61adf8a2a6..90e74e96143ca 100644 --- a/dynamic-config.md +++ b/dynamic-config.md @@ -219,10 +219,10 @@ The following TiKV configuration items can be modified dynamically: | `server.simplify-metrics` | Controls whether to simplify the sampling monitoring metrics | | `storage.block-cache.capacity` | The size of shared block cache (supported since v4.0.3) | | storage.flow-control.enable | Determines whether to enable the flow control mechanism | -| storage.flow-control.memtables-threshold | The threshold of kvDB memtable numbers that triggers flow control | -| storage.flow-control.l0-files-threshold | The threshold of kvDB L0 file numbers that triggers flow control | -| storage.flow-control.soft-pending-compaction-bytes-limit | The threshold of kvDB pending compaction bytes that triggers flow control | -| storage.flow-control.hard-pending-compaction-bytes-limit | The threshold of kvDB pending compaction bytes that triggers flow control mechanism to reject all write requests and report the `ServerIsBusy` error | +| storage.flow-control.memtables-threshold | The maximum number of kvDB memtables that trigger flow control | +| storage.flow-control.l0-files-threshold | The maximum number of kvDB L0 files that trigger flow control | +| storage.flow-control.soft-pending-compaction-bytes-limit | The threshold of kvDB pending compaction bytes that triggers flow control mechanism to reject some write requests | +| storage.flow-control.hard-pending-compaction-bytes-limit | The threshold of kvDB pending compaction bytes that triggers flow control mechanism to reject all write requests | | `storage.scheduler-worker-pool-size` | The number of threads in the Scheduler thread pool | | `backup.num-threads` | The number of backup threads (supported since v4.0.3) | | `split.qps-threshold` | The threshold to execute `load-base-split` on a Region. If the QPS of read requests for a Region exceeds `qps-threshold` for 10 consecutive seconds, this Region should be split.| From dfb1c45bc23c440c760cc63073bbbfb17c43a22e Mon Sep 17 00:00:00 2001 From: Aolin Date: Thu, 10 Jul 2025 12:16:13 +0800 Subject: [PATCH 4/4] Apply suggestions from code review --- dynamic-config.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/dynamic-config.md b/dynamic-config.md index 90e74e96143ca..c089bf1d72108 100644 --- a/dynamic-config.md +++ b/dynamic-config.md @@ -218,11 +218,11 @@ The following TiKV configuration items can be modified dynamically: | `server.raft-msg-max-batch-size` | Sets the maximum number of Raft messages that are contained in a single gRPC message | | `server.simplify-metrics` | Controls whether to simplify the sampling monitoring metrics | | `storage.block-cache.capacity` | The size of shared block cache (supported since v4.0.3) | -| storage.flow-control.enable | Determines whether to enable the flow control mechanism | -| storage.flow-control.memtables-threshold | The maximum number of kvDB memtables that trigger flow control | -| storage.flow-control.l0-files-threshold | The maximum number of kvDB L0 files that trigger flow control | -| storage.flow-control.soft-pending-compaction-bytes-limit | The threshold of kvDB pending compaction bytes that triggers flow control mechanism to reject some write requests | -| storage.flow-control.hard-pending-compaction-bytes-limit | The threshold of kvDB pending compaction bytes that triggers flow control mechanism to reject all write requests | +| storage.flow-control.enable | Determines whether to enable the flow control mechanism (dynamic modification is supported starting from v7.5.7) | +| storage.flow-control.memtables-threshold | The maximum number of kvDB memtables that trigger flow control (dynamic modification is supported starting from v7.5.7) | +| storage.flow-control.l0-files-threshold | The maximum number of kvDB L0 files that trigger flow control (dynamic modification is supported starting from v7.5.7) | +| storage.flow-control.soft-pending-compaction-bytes-limit | The threshold of kvDB pending compaction bytes that triggers flow control mechanism to reject some write requests (dynamic modification is supported starting from v7.5.7) | +| storage.flow-control.hard-pending-compaction-bytes-limit | The threshold of kvDB pending compaction bytes that triggers flow control mechanism to reject all write requests (dynamic modification is supported starting from v7.5.7) | | `storage.scheduler-worker-pool-size` | The number of threads in the Scheduler thread pool | | `backup.num-threads` | The number of backup threads (supported since v4.0.3) | | `split.qps-threshold` | The threshold to execute `load-base-split` on a Region. If the QPS of read requests for a Region exceeds `qps-threshold` for 10 consecutive seconds, this Region should be split.|