aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorazevaykin <azevaykin@yandex-team.com>2023-04-26 10:42:55 +0300
committerazevaykin <azevaykin@yandex-team.com>2023-04-26 10:42:55 +0300
commit4493042daa66c9a19de8e915582ec9d853fb742c (patch)
treee8276756cef93b5de4b89c91f40cf6f9df7e0e54
parente05dc6cbdfea96225bf8630f74ba9dadd1f206db (diff)
downloadydb-4493042daa66c9a19de8e915582ec9d853fb742c.tar.gz
Workload topic documentation
-rw-r--r--ydb/docs/en/core/reference/ydb-cli/commands/workload/_includes/index.md4
-rw-r--r--ydb/docs/en/core/reference/ydb-cli/commands/workload/_includes/stock.md4
-rw-r--r--ydb/docs/en/core/reference/ydb-cli/toc_i.yaml2
-rw-r--r--ydb/docs/en/core/reference/ydb-cli/workload-click-bench.md2
-rw-r--r--ydb/docs/en/core/reference/ydb-cli/workload-kv.md2
-rw-r--r--ydb/docs/en/core/reference/ydb-cli/workload-topic.md290
-rw-r--r--ydb/docs/ru/core/reference/ydb-cli/commands/workload/_includes/index.md2
-rw-r--r--ydb/docs/ru/core/reference/ydb-cli/toc_i.yaml3
-rw-r--r--ydb/docs/ru/core/reference/ydb-cli/workload-topic.md292
9 files changed, 595 insertions, 6 deletions
diff --git a/ydb/docs/en/core/reference/ydb-cli/commands/workload/_includes/index.md b/ydb/docs/en/core/reference/ydb-cli/commands/workload/_includes/index.md
index 20fac2421d..47ebe0d4d7 100644
--- a/ydb/docs/en/core/reference/ydb-cli/commands/workload/_includes/index.md
+++ b/ydb/docs/en/core/reference/ydb-cli/commands/workload/_includes/index.md
@@ -20,6 +20,8 @@ See the description of the command to run the data load:
## Available subcommands {#subcommands}
The following types of load tests are supported at the moment:
+
* [Stock](../stock.md): An online store warehouse simulator.
* [Key-value](../../../workload-kv.md): Key-Value load.
-* [ClickBench](../../../workload-click-bench.md): ClickBench analytical benchmark (https://github.com/ClickHouse/ClickBench). \ No newline at end of file
+* [ClickBench](../../../workload-click-bench.md): ClickBench analytical benchmark (https://github.com/ClickHouse/ClickBench).
+* [Topic](../../../workload-topic.md): Topic load.
diff --git a/ydb/docs/en/core/reference/ydb-cli/commands/workload/_includes/stock.md b/ydb/docs/en/core/reference/ydb-cli/commands/workload/_includes/stock.md
index a9c405d856..80a8c628c4 100644
--- a/ydb/docs/en/core/reference/ydb-cli/commands/workload/_includes/stock.md
+++ b/ydb/docs/en/core/reference/ydb-cli/commands/workload/_includes/stock.md
@@ -20,7 +20,7 @@ To get started, create tables and populate them with data:
* `init options`: [Initialization options](#init_options).
-See the description of the command to run the data load:
+See the description of the command to init the data load:
```bash
{{ ydb-cli }} workload init --help
@@ -80,7 +80,7 @@ See the description of the command to run the data load:
---|---|---
| `--seconds <value>` | `-s <value>` | Duration of the test, in seconds. Default: 10. |
| `--threads <value>` | `-t <value>` | The number of parallel threads creating the load. Default: 10. |
-| `--quiet` | - | Outputs only the final test result. |
+| `--quiet` | - | Outputs only the total result. |
| `--print-timestamp` | - | Print the time together with the statistics of each time window. |
| `--client-timeout` | - | [Transport timeout in milliseconds](../../../../../best_practices/timeouts.md). |
| `--operation-timeout` | - | [Operation timeout in milliseconds](../../../../../best_practices/timeouts.md). |
diff --git a/ydb/docs/en/core/reference/ydb-cli/toc_i.yaml b/ydb/docs/en/core/reference/ydb-cli/toc_i.yaml
index b859317499..90805001bd 100644
--- a/ydb/docs/en/core/reference/ydb-cli/toc_i.yaml
+++ b/ydb/docs/en/core/reference/ydb-cli/toc_i.yaml
@@ -113,3 +113,5 @@ items:
href: workload-click-bench.md
- name: Key-Value load
href: workload-kv.md
+ - name: Topic load
+ href: workload-topic.md
diff --git a/ydb/docs/en/core/reference/ydb-cli/workload-click-bench.md b/ydb/docs/en/core/reference/ydb-cli/workload-click-bench.md
index 5f5d9cb3a7..a7762d7822 100644
--- a/ydb/docs/en/core/reference/ydb-cli/workload-click-bench.md
+++ b/ydb/docs/en/core/reference/ydb-cli/workload-click-bench.md
@@ -14,7 +14,7 @@ Before running the benchmark, create a table:
{{ ydb-cli }} workload clickbench init
```
-See the description of the command to run the data load:
+See the description of the command to init the data load:
```bash
{{ ydb-cli }} workload clickbench init --help
diff --git a/ydb/docs/en/core/reference/ydb-cli/workload-kv.md b/ydb/docs/en/core/reference/ydb-cli/workload-kv.md
index 56fddc28c1..c83ed5e705 100644
--- a/ydb/docs/en/core/reference/ydb-cli/workload-kv.md
+++ b/ydb/docs/en/core/reference/ydb-cli/workload-kv.md
@@ -109,7 +109,7 @@ See the description of the command to run the data load:
---|---|---
| `--seconds <value>` | `-s <value>` | Duration of the test, in seconds. Default: 10. |
| `--threads <value>` | `-t <value>` | The number of parallel threads creating the load. Default: 10. |
-| `--quiet` | - | Outputs only the final test result. |
+| `--quiet` | - | Outputs only the total result. |
| `--print-timestamp` | - | Print the time together with the statistics of each time window. |
| `--client-timeout` | - | [Transport timeout in milliseconds](../../best_practices/timeouts.md). |
| `--operation-timeout` | - | [Operation timeout in milliseconds](../../best_practices/timeouts.md). |
diff --git a/ydb/docs/en/core/reference/ydb-cli/workload-topic.md b/ydb/docs/en/core/reference/ydb-cli/workload-topic.md
new file mode 100644
index 0000000000..6186ac0691
--- /dev/null
+++ b/ydb/docs/en/core/reference/ydb-cli/workload-topic.md
@@ -0,0 +1,290 @@
+# Topic workload
+
+The workload simulates the publish-subscribe architectural pattern using [YDB topics](../../concepts/topic.md).
+
+The workload allow us to generate and consume high volumes of data through your YDB cluster in order to measure it's performance characteristics such as throughout and latency.
+
+The tests can be configured to match your real workloads. The number of messages, message sizes, target throughput, the number of producers and consumers can be adjusted.
+
+Test outputs include the number of messages and the amount of data transferred including latencies in order to understand the real world performance characteristics of your cluster.
+
+## Types of load{#workload-types}
+
+The load test runs 3 types of load:
+
+* [write](#run-write) — generate messages and write them to a topic asynchronously;
+* [read](#run-read) — read messages from a topic asynchronously;
+* [full](#run-full) — simultaneously read and write messages.
+
+## Load initialization {#init}
+
+To get started, create a topic:
+
+```bash
+{{ ydb-cli }} workload topic init [init options...]
+```
+
+* `init options` — [Initialization options](#init-options).
+
+See the description of the command to init the data load:
+
+```bash
+{{ ydb-cli }} workload topic init --help
+```
+
+### Available parameters {#init-options}
+
+Parameter name | Short name | Parameter description
+---|---|---
+`--partitions <value>` | `-p <value>` | Number of partitions in the topic. Default: 128.
+`--consumers <value>` | `-c <value>` | Number of consumers in the topic. Default: 1.
+
+The `workload-topic` topic will be created with the specified numbers of partitions and consumers.
+
+### Load initialization example{#init-topic-examples}
+
+Creating a topic with 256 partitions and 2 consumers:
+
+```bash
+{{ ydb-cli }} workload topic init --partitions 256 --consumers 2
+```
+
+## Clean {#clean}
+
+When the workload is complete, you can delete the `workload-topic` topic:
+
+```bash
+{{ ydb-cli }} workload topic clean
+```
+
+### Clean example {#clean-topic-examples}
+
+```bash
+{{ ydb-cli }} workload topic clean
+```
+
+## Running a load test {#run}
+
+To run the load, execute the command:
+
+```bash
+{{ ydb-cli }} workload topic run [workload type...] [specific workload options...]
+```
+
+* `workload type` — [The types of workload](#workload-types).
+* `global workload options` — [The global options for all types of load.](#global-workload-options).
+* `specific workload options` — Options of a specific load type.
+
+See the description of the command to run the workload:
+
+```bash
+{{ ydb-cli }} workload topic run --help
+```
+
+### The global options for all types of load {#global-workload-options}
+
+Parameter name | Short name | Parameter description
+---|---|---
+`--seconds <value>` | `-s <value>` | Duration of the test (seconds). Default: 10.
+`--window <value>` | `-w <value>` | Statistics collection window (seconds). Default: 1.
+`--quiet` | `-q` | Outputs only the total result.
+`--print-timestamp` | - | Print the time together with the statistics of each time window.
+
+## Write workload {#run-write}
+
+This load type generate messages and send them into a topic asynchronously.
+
+To run this type of load, execute the command:
+
+```bash
+{{ ydb-cli }} workload topic run write [global workload options...] [specific workload options...]
+```
+
+See the description of the command to run the write workload:
+
+```bash
+{{ ydb-cli }} workload topic run write --help
+```
+
+### Write workload options {#run-write-options}
+
+Parameter name | Short name | Parameter description
+---|---|---
+`--threads <value>` | `-t <value>` | Number of producer threads. Default: `1`.
+`--message-size <value>` | `-m <value>` | Message size (bytes). It can be specified in KB, MB, GB using one of suffixes: `K`, `M`, `G`. Default: `10K`.
+`--message-rate <value>` | - | Total message rate for all producer threads (messages per second). 0 - no limit. Default: `0`.
+`--byte-rate <value>` | - | Total message rate for all producer threads (bytes per second). 0 - no limit. It can be specified in KB/s, MB/s, GB/s using one of suffixes: `K`, `M`, `G`. Default: `0`.
+`--codec <value>` | - | Codec used for message compression on the client before sending them to the server. Possible values: `RAW` (no compression), `GZIP`, and `ZSTD`. Compression causes higher CPU utilization on the client when reading and writing messages, but usually lets you reduce the volume of data transferred over the network and stored. When consumers read messages, they're automatically decompressed with the codec used when writing them, without specifying any special options. Default: `RAW`.
+
+Note: The options `--byte-rate` и `--message-rate` are mutually exclusive.
+
+### Write workload example{#run-write-examples}
+
+Example of a command to create 100 producer threads with a target speed of 80 MB/s and a duration of 300 seconds:
+
+```bash
+{{ ydb-cli }} workload topic run write --threads 100 --seconds 300 --byte-rate 80M
+```
+
+### Write workload output {#run-write-output}
+
+During the process of work, both intermediate and total statistics are printed. Example output:
+
+```text
+Window Write speed Write time Inflight
+# msg/s MB/s P99(ms) max msg
+1 20 0 1079 72
+2 8025 78 1415 78
+3 7987 78 1431 79
+4 7888 77 1471 101
+5 8126 79 1815 116
+6 7018 68 1447 79
+7 8938 87 2511 159
+8 7055 68 1463 78
+9 7062 69 1455 79
+10 9912 96 3679 250
+Window Write speed Write time Inflight
+# msg/s MB/s P99(ms) max msg
+Total 7203 70 3023 250
+```
+
+Column name | Column description
+---|---
+`Window`|The time window counter.
+`Write speed`|Write speed (messages/s and Mb/s).
+`Write time`|99 percentile of message write time (ms).
+`Inflight`|The maximum count of inflight messages.
+
+## Read workload {#run-read}
+
+This load type read messages from a topic asynchronously.
+
+To run this type of load, execute the command:
+
+```bash
+{{ ydb-cli }} workload topic run read [global workload options...] [specific workload options...]
+```
+
+See the description of the command to run the read workload:
+
+```bash
+{{ ydb-cli }} workload topic run read --help
+```
+
+### Read workload options {#run-read-options}
+
+Parameter name | Short name | Parameter description
+---|---|---
+`--consumers <value>` | `-c <value>` | Number of consumers in the topic. Default: `1`.
+`--threads <value>` | `-t <value>` | Number of consumer threads. Default: `1`.
+
+### Read workload example {#run-read-examples}
+
+Example of a command to create 2 consumers with 100 threads each:
+
+```bash
+{{ ydb-cli }} workload topic run read --consumers 2 --threads 100
+```
+
+### Read workload output {#run-read-output}
+
+During the process of work, both intermediate and total statistics are printed. Example output:
+
+```text
+Window Lag Lag time Read speed Full time
+# max msg P99(ms) msg/s MB/s P99(ms)
+1 0 0 48193 471 0
+2 30176 0 66578 650 0
+3 30176 0 68999 674 0
+4 30176 0 66907 653 0
+5 27835 0 67628 661 0
+6 30176 0 67938 664 0
+7 30176 0 71628 700 0
+8 20338 0 61367 599 0
+9 30176 0 61770 603 0
+10 30176 0 58291 569 0
+Window Lag Lag time Read speed Full time
+# max msg P99(ms) msg/s MB/s P99(ms)
+Total 30176 0 80267 784 0
+```
+
+Column name | Column description
+---|---
+`Window`|The time window counter.
+`Lag`|The maximum lag between producers and consumers across all the partitions (messages).
+`Lag time`|99 percentile of message delay time (ms).
+`Read`|Read speed (messages/s and MB/s).
+`Full time`|99 percentile of the end-to-end message time, from writing by the producer to reading by the reader.
+
+## Full workload {#run-full}
+
+This load type both write and read messages asynchronously.
+
+To run this type of load, execute the command:
+
+```bash
+{{ ydb-cli }} workload topic run full [global workload options...] [specific workload options...]
+```
+
+This command is equivalent to running both read and write load workloads simultaneously.
+
+See the description of the command to run the full workload:
+
+```bash
+{{ ydb-cli }} workload topic run full --help
+```
+
+### Full workload options {#run-full-options}
+
+Parameter name | Short name | Parameter description
+---|---|---
+`--producer-threads <value>` | `-p <value>` | Number of producer threads. Default: `1`.
+`--message-size <value>` | `-m <value>` | Message size (bytes). It can be specified in KB, MB, GB using one of suffixes: `K`, `M`, `G`. Default: `10K`.
+`--message-rate <value>` | - | Total message rate for all producer threads (messages per second). 0 - no limit. Default: `0`.
+`--byte-rate <value>` | - | Total message rate for all producer threads (bytes per second). 0 - no limit. It can be specified in KB/s, MB/s, GB/s using one of suffixes: `K`, `M`, `G`. Default: `0`.
+`--codec <value>` | - | Codec used for message compression on the client before sending them to the server. Possible values: `RAW` (no compression), `GZIP`, and `ZSTD`. Compression causes higher CPU utilization on the client when reading and writing messages, but usually lets you reduce the volume of data transferred over the network and stored. When consumers read messages, they're automatically decompressed with the codec used when writing them, without specifying any special options. Default: `RAW`.
+`--consumers <value>` | `-c <value>` | Number of consumers in the topic. Default: `1`.
+`--threads <value>` | `-t <value>` | Number of consumer threads. Default: `1`.
+
+Note: The options `--byte-rate` и `--message-rate` are mutually exclusive.
+
+### Full workload example {#run-full-examples}
+
+Example of a command to create 100 producer threads, 2 consumers the 50 consumer thread,a target speed of 80 MB/s and a duration of 300 seconds:
+
+```bash
+{{ ydb-cli }} workload topic run full --producer-threads 100 --consumers 2 --consumer-threads 50 --byte-rate 80M --seconds 300
+```
+
+### Ful workload output {#run-full-output}
+
+During the process of work, both intermediate and total statistics are printed. Example output:
+
+```text
+Window Write speed Write time Inflight Lag Lag time Read speed Full time
+# msg/s MB/s P99(ms) max msg max msg P99(ms) msg/s MB/s P99(ms)
+1 39 0 1215 4 0 0 30703 300 29716
+2 1091 10 2143 8 2076 20607 40156 392 30941
+3 1552 15 2991 12 7224 21887 41040 401 31886
+4 1733 16 3711 15 10036 22783 38488 376 32577
+5 1900 18 4319 15 10668 23551 34784 340 33372
+6 2793 27 5247 21 9461 24575 33267 325 34893
+7 2904 28 6015 22 12150 25727 34423 336 35507
+8 2191 21 5087 21 12150 26623 29393 287 36407
+9 1952 19 2543 10 7627 27391 33284 325 37814
+10 1992 19 2655 9 10104 28671 29101 284 38797
+Window Write speed Write time Inflight Lag Lag time Read speed Full time
+# msg/s MB/s P99(ms) max msg max msg P99(ms) msg/s MB/s P99(ms)
+Total 1814 17 5247 22 12150 28671 44827 438 40252
+```
+
+Column name | Column description
+---|---
+`Window`|The time window counter.
+`Write speed`|Write speed (messages/s and Mb/s).
+`Write time`|99 percentile of message write time (ms).
+`Inflight`|The maximum count of inflight messages.
+`Lag`|The maximum lag between producers and consumers across all the partitions (messages).
+`Lag time`|99 percentile of message delay time (ms).
+`Read`|Read speed (messages/s and MB/s).
+`Full time`|99 percentile of the end-to-end message time, from writing by the producer to reading by the reader.
diff --git a/ydb/docs/ru/core/reference/ydb-cli/commands/workload/_includes/index.md b/ydb/docs/ru/core/reference/ydb-cli/commands/workload/_includes/index.md
index d6d06e6b2c..46c9bb4b2b 100644
--- a/ydb/docs/ru/core/reference/ydb-cli/commands/workload/_includes/index.md
+++ b/ydb/docs/ru/core/reference/ydb-cli/commands/workload/_includes/index.md
@@ -20,6 +20,8 @@
## Доступные подкоманды {#subcommands}
В данный момент поддерживаются следующие виды нагрузочных тестов:
+
* [Stock](../stock.md) - симулятор склада интернет-магазина.
* [Key-value](../../../workload-kv.md) - Key-Value нагрузка.
* [ClickBench](../../../workload-click-bench.md) - аналитический бенчмарк ClickBench (https://github.com/ClickHouse/ClickBench).
+* [Topic](../../../workload-topic.md) - Topic нагрузка.
diff --git a/ydb/docs/ru/core/reference/ydb-cli/toc_i.yaml b/ydb/docs/ru/core/reference/ydb-cli/toc_i.yaml
index 00429032aa..3dd933b7d3 100644
--- a/ydb/docs/ru/core/reference/ydb-cli/toc_i.yaml
+++ b/ydb/docs/ru/core/reference/ydb-cli/toc_i.yaml
@@ -113,4 +113,5 @@ items:
href: workload-click-bench.md
- name: Key-Value нагрузка
href: workload-kv.md
-
+ - name: Topic нагрузка
+ href: workload-topic.md
diff --git a/ydb/docs/ru/core/reference/ydb-cli/workload-topic.md b/ydb/docs/ru/core/reference/ydb-cli/workload-topic.md
new file mode 100644
index 0000000000..12feb2bb8c
--- /dev/null
+++ b/ydb/docs/ru/core/reference/ydb-cli/workload-topic.md
@@ -0,0 +1,292 @@
+# Нагрузка топиков
+
+Простой вид нагрузки, использующий [топики](../../concepts/topic.md) YDB в качестве очередей сообщений.
+
+В процессе работы пишется и читается большое число сообщений в целях измерения показателей производительности.
+
+Для соответствия реальной нагрузке можно изменять различные входные параметры: число сообщений, размер сообщений, целевую скорость записи, число писателей и читателей.
+
+В процессе работы на консоль выдаются результаты, включающие число и скорость сообщений, временные показатели.
+
+## Виды нагрузки {#workload-types}
+
+Данный нагрузочный тест содержит 3 вида нагрузки:
+
+* [write](#run-write) — генерация сообщений и их запись в топик в асинхронном режиме;
+* [read](#run-read) — асинхронное чтение сообщений из топика;
+* [full](#run-full) — одновременное асинхронное чтение и запись сообщений.
+
+## Инициализация нагрузочного теста {#init}
+
+Для начала работы необходимо создать топик:
+
+```bash
+{{ ydb-cli }} workload topic init [init options...]
+```
+
+* `init options` — [параметры инициализации](#init-options).
+
+Посмотреть описание команды для создания топика:
+
+```bash
+{{ ydb-cli }} workload topic init --help
+```
+
+### Доступные параметры {#init-options}
+
+Имя параметра | Короткое имя | Описание параметра
+---|---|---
+`--partitions <значение>` | `-p <значение>` | Количество партиций топика. Значение по умолчанию: 128.
+`--consumers <значение>` | `-c <значение>` | Количество читателей топика. Значение по умолчанию: 1.
+
+В результате выполнения команды будет создан топик с фиксированным именем `workload-topic` и указанным числом партиций и читателей.
+
+### Примеры инициализации нагрузки {#init-topic-examples}
+
+Пример команды создания топика с 256 партициями и 2 читателями:
+
+```bash
+{{ ydb-cli }} workload topic init --partitions 256 --consumers 2
+```
+
+## Удаление топика {#clean}
+
+После завершения работы можно удалить топик:
+
+```bash
+{{ ydb-cli }} workload topic clean
+```
+
+В результате выполнения команды будет удален топик `workload-topic`.
+
+### Пример использования clean {#clean-topic-examples}
+
+```bash
+{{ ydb-cli }} workload topic clean
+```
+
+## Запуск нагрузочного теста {#run}
+
+Для запуска нагрузки необходимо выполнить команду:
+
+```bash
+{{ ydb-cli }} workload topic run [workload type...] [specific workload options...]
+```
+
+* `workload type` — [виды нагрузки](#workload-types).
+* `global workload options` — [общие параметры для всех видов нагрузки](#global-workload-options).
+* `specific workload options` — параметры конкретного вида нагрузки.
+
+Посмотреть описание команды для запуска нагрузки:
+
+```bash
+{{ ydb-cli }} workload topic run --help
+```
+
+### Общие параметры для всех видов нагрузки {#global-workload-options}
+
+Имя параметра | Короткое имя | Описание параметра
+---|---|---
+`--seconds <значение>` | `-s <значение>` | Продолжительность теста (секунд). Значение по умолчанию: 10.
+`--window <значение>` | `-w <значение>` | Длительность окна сбора статистики (секунд). Значение по умолчанию: 1.
+`--quiet` | `-q` | Выводит только итоговый результат теста.
+`--print-timestamp` | - | Печатать время вместе со статистикой каждого временного окна.
+
+## Нагрузка на запись {#run-write}
+
+Данный вид нагрузки генерирует и вставляет сообщения в топик в асинхронном режиме.
+
+Для запуска данного вида нагрузки необходимо выполнить команду:
+
+```bash
+{{ ydb-cli }} workload topic run write [global workload options...] [specific workload options...]
+```
+
+Посмотреть описание команды для запуска нагрузки на запись:
+
+```bash
+{{ ydb-cli }} workload topic run write --help
+```
+
+### Параметры нагрузки на запись {#run-write-options}
+
+Имя параметра | Короткое имя | Описание параметра
+---|---|---
+`--threads <значение>` | `-t <значение>` | Количество потоков писателя. Значение по умолчанию: `1`.
+`--message-size <значение>` | `-m <значение>` | Размер сообщения (байт). Возможно задание в Кбайт, Мбайт, Гбайт путем добавления суффиксов соответственно: `K`, `M`, `G`. Значение по умолчанию: `10K`.
+`--message-rate <значение>` | - | Целевая суммарная скорость записи (сообщений в секунду). 0 - нет ограничения. Значение по умолчанию: `0`.
+`--byte-rate <значение>` | - | Целевая суммарная скорость записи (байт в секунду). 0 - нет ограничения. Возможно задание в Кбайт/с, Мбайт/с, Гбайт/с путем добавления суффиксов соответственно: `K`,`M`,`G`. Значение по умолчанию: `0`.
+`--codec <значение>` | - | Кодек, используемый для сжатия сообщений на клиенте перед отправкой на сервер. Возможные варианты: `RAW` - без сжатия, `GZIP`, `ZSTD`. Сжатие увеличивает затраты CPU на клиенте при записи и чтении сообщений, но обычно позволяет уменьшить объем передаваемых по сети и хранимых данных. При последующем чтении сообщений подписчиками они автоматически разжимаются использованным при записи кодеком, не требуя указания каких-либо специальных опций. Значение по умолчанию: `RAW`.
+
+Внимание, параметры `--byte-rate` и `--message-rate` являются взаимоисключающими.
+
+### Примеры запуска нагрузки на запись {#run-write-examples}
+
+Пример команды записи в 100 потоков писателей с целевой скоростью 80 Мбайт/с и длительностью 300 секунд:
+
+```bash
+{{ ydb-cli }} workload topic run write --threads 100 --seconds 300 --byte-rate 80M
+```
+
+### Вывод нагрузки на запись {#run-write-output}
+
+В процессе работы печатается статистика за промежуточные временные окна и в конце итоговая статистика за всё время работы. Пример вывода:
+
+```text
+Window Write speed Write time Inflight
+# msg/s MB/s P99(ms) max msg
+1 20 0 1079 72
+2 8025 78 1415 78
+3 7987 78 1431 79
+4 7888 77 1471 101
+5 8126 79 1815 116
+6 7018 68 1447 79
+7 8938 87 2511 159
+8 7055 68 1463 78
+9 7062 69 1455 79
+10 9912 96 3679 250
+Window Write speed Write time Inflight
+# msg/s MB/s P99(ms) max msg
+Total 7203 70 3023 250
+```
+
+Имя колонки | Описание колонки
+---|---
+`Window`|Порядковый номер временного окна сбора статистики.
+`Write speed`|Скорость записи сообщений (сообщений/с и Мбайт/с).
+`Write time`|99 перцентиль времени записи сообщения (мс).
+`Inflight`|Максимальное число сообщений, ожидающих подтверждения по всем партициям (сообщений).
+
+## Нагрузка на чтение {#run-read}
+
+Данный вид нагрузки асинхронно читает сообщения из топика.
+
+Для запуска данного вида нагрузки необходимо выполнить команду:
+
+```bash
+{{ ydb-cli }} workload topic run read [global workload options...] [specific workload options...]
+```
+
+Посмотреть описание команды для запуска нагрузки на чтение:
+
+```bash
+{{ ydb-cli }} workload topic run read --help
+```
+
+### Параметры нагрузки на чтение {#run-read-options}
+
+Имя параметра | Короткое имя | Описание параметра
+---|---|---
+`--consumers <значение>` | `-c <значение>` | Количество читателей. Значение по умолчанию: `1`.
+`--threads <значение>` | `-t <значение>` | Количество потоков читателя. Значение по умолчанию: `1`.
+
+### Примеры запуска нагрузки на чтение {#run-read-examples}
+
+Пример команды чтения с помощью 2 читателей, каждый из который имеет 100 потоков:
+
+```bash
+{{ ydb-cli }} workload topic run read --consumers 2 --threads 100
+```
+
+### Вывод нагрузки на чтение {#run-read-output}
+
+В процессе работы печатается статистика за промежуточные временные окна и в конце итоговая статистика за всё время работы. Пример вывода:
+
+```text
+Window Lag Lag time Read speed Full time
+# max msg P99(ms) msg/s MB/s P99(ms)
+1 0 0 48193 471 0
+2 30176 0 66578 650 0
+3 30176 0 68999 674 0
+4 30176 0 66907 653 0
+5 27835 0 67628 661 0
+6 30176 0 67938 664 0
+7 30176 0 71628 700 0
+8 20338 0 61367 599 0
+9 30176 0 61770 603 0
+10 30176 0 58291 569 0
+Window Lag Lag time Read speed Full time
+# max msg P99(ms) msg/s MB/s P99(ms)
+Total 30176 0 80267 784 0
+```
+
+Имя колонки | Описание колонки
+---|---
+`Window`|Порядковый номер временного окна сбора статистики.
+`Lag`|Максимальная задержка сообщений по всем партициям (сообщений). Число сообщений, ожидающих чтения.
+`Lag time`|99 перцентиль времени задержки сообщений (мс).
+`Read`|Скорость чтения сообщений читателем (сообщений/с и Мбайт/с).
+`Full time`|99 перцентиль времени полной обработки сообщения, от записи писателем до чтения читателем (мс).
+
+## Нагрузка на чтение/запись {#run-full}
+
+Данный вид нагрузки одновременно асинхронно пишет и читает сообщения.
+
+Для запуска данного вида нагрузки необходимо выполнить команду:
+
+```bash
+{{ ydb-cli }} workload topic run full [global workload options...] [specific workload options...]
+```
+
+Выполнение данной команды эквивалентно одновременному запуску двух процессов нагрузки на чтение и запись.
+
+Посмотреть описание команды для запуска нагрузки на чтение/запись:
+
+```bash
+{{ ydb-cli }} workload topic run full --help
+```
+
+### Параметры нагрузки на чтение/запись {#run-full-options}
+
+Имя параметра | Короткое имя | Описание параметра
+---|---|---
+`--producer-threads <значение>` | `-p <значение>` | Количество потоков писателя. Значение по умолчанию: `1`.
+`--message-size <значение>` | `-m <значение>` | Размер сообщения (байт). Возможно задание в Кбайт, Мбайт, Гбайт путем добавления суффиксов соответственно: `K`, `M`, `G`. Значение по умолчанию: `10K`.
+`--message-rate <значение>` | - | Целевая суммарная скорость записи (сообщений в секунду). 0 - нет ограничения. Значение по умолчанию: `0`.
+`--byte-rate <значение>` | - | Целевая суммарная скорость записи (байт в секунду). 0 - нет ограничения. Возможно задание в Кбайт/с, Мбайт/с, Гбайт/с путем добавления суффиксов соответственно: `K`,`M`,`G`. Значение по умолчанию: `0`.
+`--codec <значение>` | - | Кодек, используемый для сжатия сообщений на клиенте перед отправкой на сервер. Возможные варианты: `RAW` - без сжатия, `GZIP`, `ZSTD`. Сжатие увеличивает затраты CPU на клиенте при записи и чтении сообщений, но обычно позволяет уменьшить объем передаваемых по сети и хранимых данных. При последующем чтении сообщений подписчиками они автоматически разжимаются использованным при записи кодеком, не требуя указания каких-либо специальных опций. Значение по умолчанию: `RAW`.
+`--consumers <значение>` | `-c <значение>` | Количество читателей. Значение по умолчанию: `1`.
+`--consumer-threads <значение>` | `-t <значение>` | Количество потоков читателя. Значение по умолчанию: `1`.
+
+Внимание, параметры `--byte-rate` и `--message-rate` являются взаимоисключающими.
+
+### Примеры запуска нагрузки на чтение/запись {#run-full-examples}
+
+Пример команды чтения/записи с помощью 2 читателей в 50 потоков, 100 писателей с целевой скоростью 80 Мбайт/с и длительностью 300 секунд:
+
+```bash
+{{ ydb-cli }} workload topic run full --producer-threads 100 --consumers 2 --consumer-threads 50 --byte-rate 80M --seconds 300
+```
+
+### Вывод нагрузки на чтение/запись {#run-full-output}
+
+В процессе работы печатается статистика за промежуточные временные окна и в конце итоговая статистика за всё время работы. Пример вывода:
+
+```text
+Window Write speed Write time Inflight Lag Lag time Read speed Full time
+# msg/s MB/s P99(ms) max msg max msg P99(ms) msg/s MB/s P99(ms)
+1 39 0 1215 4 0 0 30703 300 29716
+2 1091 10 2143 8 2076 20607 40156 392 30941
+3 1552 15 2991 12 7224 21887 41040 401 31886
+4 1733 16 3711 15 10036 22783 38488 376 32577
+5 1900 18 4319 15 10668 23551 34784 340 33372
+6 2793 27 5247 21 9461 24575 33267 325 34893
+7 2904 28 6015 22 12150 25727 34423 336 35507
+8 2191 21 5087 21 12150 26623 29393 287 36407
+9 1952 19 2543 10 7627 27391 33284 325 37814
+10 1992 19 2655 9 10104 28671 29101 284 38797
+Window Write speed Write time Inflight Lag Lag time Read speed Full time
+# msg/s MB/s P99(ms) max msg max msg P99(ms) msg/s MB/s P99(ms)
+Total 1814 17 5247 22 12150 28671 44827 438 40252
+```
+
+Имя колонки | Описание колонки
+---|---
+`Window`|Порядковый номер временного окна сбора статистики.
+`Write speed`|Скорость записи сообщений (сообщений/с и Мбайт/с).
+`Write time`|99 перцентиль времени записи сообщения (мс).
+`Inflight`|Максимальное число сообщений, ожидающих подтверждения по всем партициям (сообщений).
+`Lag`|Максимальная задержка сообщений по всем партициям (сообщений). Число сообщений, ожидающих чтения.
+`Lag time`|99 перцентиль времени задержки сообщений (мс).
+`Read`|Скорость чтения сообщений читателем (сообщений/с и Мбайт/с).
+`Full time`|99 перцентиль времени полной обработки сообщения, от записи писателем до чтения читателем (мс).