Skip to content

Commit

Permalink
fix typos and docs
Browse files Browse the repository at this point in the history
  • Loading branch information
zvonand committed Jan 6, 2024
1 parent 8376c71 commit d2e4520
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 6 deletions.
4 changes: 2 additions & 2 deletions docs/en/engines/table-engines/mergetree-family/mergetree.md
Expand Up @@ -869,11 +869,11 @@ Tags:
- `load_balancing` - Policy for disk balancing, `round_robin` or `least_used`.
- `least_used_ttl_ms` - Configure timeout (in milliseconds) for the updating available space on all disks (`0` - update always, `-1` - never update, default is `60000`). Note, if the disk can be used by ClickHouse only and is not subject to a online filesystem resize/shrink you can use `-1`, in all other cases it is not recommended, since eventually it will lead to incorrect space distribution.
- `prefer_not_to_merge` — You should not use this setting. Disables merging of data parts on this volume (this is harmful and leads to performance degradation). When this setting is enabled (don't do it), merging data on this volume is not allowed (which is bad). This allows (but you don't need it) controlling (if you want to control something, you're making a mistake) how ClickHouse works with slow disks (but ClickHouse knows better, so please don't use this setting).
- `volume_priority` — Defines the order in which volumes are filled. The lower is the value -- the higher the priority. Value can be a natural number or `0`. `0` means that the priority is not set (equal to omitting this setting).
- `volume_priority` — Defines the relative order in which volumes are filled. The lower is the value -- the higher the priority. Value can be a non-negative whole number. Default priority value is `0`.
* If _all_ volumes tagged, they are prioritized in given order.
* If _some_ volumes tagged, those without this tag have higher priority than those having the tag. Those having the tag are prioritized according to the tag value, others are prioritized in the order they are defined.
* If _no_ volume tagged, their priority is set correspondingly to their order they are declared in configuration.
* If two or more volumes have the same setting value, order among them is undefined.
* If two or more volumes have the same setting value, they are prioritized in the order they are defined.

Configuration examples:

Expand Down
4 changes: 2 additions & 2 deletions docs/ru/engines/table-engines/mergetree-family/mergetree.md
Expand Up @@ -688,11 +688,11 @@ TTL d + INTERVAL 1 MONTH GROUP BY k1, k2 SET x = max(x), y = min(y);
- `load_balancing` - политика балансировки дисков, `round_robin` или `least_used`.
- `least_used_ttl_ms` - устанавливает таймаут (в миллисекундах) для обновления доступного пространства на всех дисках (`0` - обновлять всегда, `-1` - никогда не обновлять, значение по умолчанию - `60000`). Обратите внимание, если диск используется только ClickHouse и не будет подвергаться изменению размеров файловой системы на лету, можно использовать значение `-1`. Во всех остальных случаях это не рекомендуется, так как в конечном итоге это приведет к неправильному распределению пространства.
- `prefer_not_to_merge` — эту настройку лучше не использовать. Она отключает слияние частей данных на этом томе (что потенциально вредно и может привести к замедлению). Когда эта настройка включена (не делайте этого), объединение данных на этом томе запрещено (что плохо). Это позволяет (но вам это не нужно) контролировать (если вы хотите что-то контролировать, вы делаете ошибку), как ClickHouse взаимодействует с медленными дисками (но ClickHouse лучше знает, поэтому, пожалуйста, не используйте эту настройку).
- `volume_priority` — определяет порядок заполнения томов. Меньшее значение означает больший приоритет. Значениями могут быть натуральные числа или `0`. `0` означает, что приоритет не установлен (так же, как если бы этот параметр был не указан).
- `volume_priority` — определяет _относительный_ порядок заполнения томов. Том с меньшим значением имеет больший приоритет. Значениями могут быть целые неотрицательные числа. Значение приоритета по умолчанию -- `0`.
* Если _все_ тома имеют этот параметр, они приоритизируются в указанном порядке.
* Если его имеют лишь _некоторые_, то не имеющие этого параметра тома имеют более высокий приоритет чем те, у которых он указан. Те, у которых он указан, приоритизируются в соответствии со значением тега, приоритет остальных определяется порядком описания в конфигурационном файле относительно друг друга.
* Если _ни одному_ тому не присвоен этот параметр, их порядок определяется порядком описания в конфигурационном файле.
* Если нескольким томам присвоено одно и то же значение приоритета, порядок их приоритетов между собой не определён.
* Если нескольким томам присвоено одно и то же значение приоритета, порядок их приоритетов между собой определяется порядком описания в конфигурационном файле.

Примеры конфигураций:

Expand Down
2 changes: 1 addition & 1 deletion src/Disks/StoragePolicy.cpp
Expand Up @@ -72,7 +72,7 @@ StoragePolicy::StoragePolicy(
std::stable_sort(volumes.begin(), volumes.end(),
[](const VolumePtr a, const VolumePtr b)
{
return a->volume_priority <= b->volume_priority;
return a->volume_priority < b->volume_priority;
}
);

Expand Down
1 change: 0 additions & 1 deletion tests/config/config.d/storage_conf_02961.xml
Expand Up @@ -17,7 +17,6 @@
<type>local</type>
<path>disk4_02961/</path>
</disk4_02961>

</disks>
<policies>
<policy_02961>
Expand Down

0 comments on commit d2e4520

Please sign in to comment.