This is an automated email from the ASF dual-hosted git repository.
yiguolei pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris-website.git
The following commit(s) were added to refs/heads/master by this push:
new b9658124790 [docs]add workload group bind compute group document
(#2407)
b9658124790 is described below
commit b965812479037a8bfad2b9c70784292cb7c38d36
Author: wangbo <[email protected]>
AuthorDate: Sat May 24 09:22:55 2025 +0800
[docs]add workload group bind compute group document (#2407)
## Versions
- [x] dev
- [ ] 3.0
- [ ] 2.1
- [ ] 2.0
## Languages
- [x] Chinese
- [ ] English
## Docs Checklist
- [x] Checked by AI
- [ ] Test Cases Built
---
.../workload-group-bind-compute-group.md | 93 ++++++++++++++++++++
.../workload-management/workload-group.md | 2 +-
.../workload-group-bind-compute-group.md | 94 +++++++++++++++++++++
.../workload-management/workload-group.md | 2 +-
.../workload-management/workload-group.md | 26 +++---
.../workload-management/workload-group.md | 2 +-
static/images/wg_bind_cg1.png | Bin 0 -> 70763 bytes
static/images/wg_bind_cg2.png | Bin 0 -> 103150 bytes
.../workload-management/workload-group.md | 2 +-
.../workload-management/workload-group.md | 28 +++---
10 files changed, 218 insertions(+), 31 deletions(-)
diff --git
a/docs/admin-manual/workload-management/workload-group-bind-compute-group.md
b/docs/admin-manual/workload-management/workload-group-bind-compute-group.md
new file mode 100644
index 00000000000..8b9c1d8e11b
--- /dev/null
+++ b/docs/admin-manual/workload-management/workload-group-bind-compute-group.md
@@ -0,0 +1,93 @@
+---
+{
+"title": "Workload Group Bind Compute Group",
+"language": "zh-CN"
+}
+---
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+## 背景
+Doris supports logical partitioning of BE (Backend) resources within a cluster
through the Compute Group feature, forming independent sub-cluster units to
achieve physical isolation of computing and storage resources for different
business parties. Due to the significant differences in load characteristics
among business parties, their configuration requirements for Workload Groups
often exhibit obvious distinctions.
+
+In early versions, the Workload Groups configured by users would take effect
globally across all Compute Groups, forcing different business parties to share
the same set of Workload Group configurations. For example, Business A’s
high-concurrency queries and Business B’s large-scale data analysis might
require completely different resource quotas, but the old architecture could
not meet such differentiated needs, limiting the flexibility of resource
management.
+
+To address this, the latest version introduces a mechanism for binding
Workload Groups to Compute Groups, allowing each Compute Group to be configured
with independent Workload Groups.
+
+## Compute Group Introduction
+The Compute Group, initially serving as a core concept under the
storage-computation separation architecture, is designed to achieve logical
partitioning of independent sub-clusters within a single cluster. In the
storage-computation integration architecture, the concept with equivalent
functionality is called the Resource Group. Both can realize the isolation and
grouped management of cluster resources.
+
+When discussing Doris' computational resource management system, Compute Group
and Resource Group can be regarded as logically equivalent concepts, an
understanding that significantly reduces comprehension costs. At the specific
interface invocation level, however, both still maintain their original
independent invocation specifications and usage logic unchanged.
+
+Therefore, the concept and usage of binding Workload Groups to Compute Groups
mentioned in this article are applicable to both the storage-computation
integration architecture and the storage-computation separation architecture.
+
+## Introduction to Principles
+Suppose there are two Compute Groups in the cluster, named Compute Group A and
Compute Group B, which serve business party A and business party B
respectively, and the two business systems operate completely independently.
+
+At the same time, two Workload Groups are configured in the cluster: group_a
created by Business A and group_b created by Business B. The sum of the
resource configuration quotas of the two groups exactly fills 100% of the
cluster's total resources.
+
+### Design of Workload Group in Previous Versions
+In previous versions, group_1 and group_2 would take effect on all BE nodes,
even if different BEs were already grouped according to Compute Groups.
+In previous designs, once Business A created group_a, no new Workload Groups
could be created because the cumulative resource values of all Workload Groups
had already reached 100%. Additionally, since group_b was created by Business
B—and Business A and Business B are completely independent business
parties—Business A could neither access nor modify group_b.
+Even if the permission policies grant both parties access to Workload Groups,
due to the complete independence of business logic, there may still be
significant differences in their resource configuration requirements (e.g.,
high-concurrency queries of Business A and batch computing of Business B
requiring different resource allocations). This makes it difficult for the old
architecture to meet the needs of differentiated management.
+
+
+
+### Current Design
+In the current version, Workload Group supports binding to Compute Group,
which means different Compute Groups can have different Workload Group
configurations. As shown in the figure below:
+
+
+
+## Usage
+
+:::tip
+Doris provides a default Compute Group mechanism: when a new BE node is added
without a specified assignment, it is automatically placed into the default
Compute Group. Specifically, in a compute-storage separation architecture, the
default Compute Group is named default_compute_group, whereas in an integrated
compute-storage architecture, it is named default.
+:::
+
+1. Create a Workload Group named group_a and bind it to the Compute Group
named compute_group_a.
+```
+create workload group group_a for compute_group_a
properties('cpu_share'='1024')
+```
+
+2. If the Compute Group is not specified during creation, the Workload Group
will be bound to the default Compute Group.
+```
+create workload group group_a properties('cpu_share'='1024')
+```
+
+3. Drop the Workload Group named group_a from compute_group_a.
+```
+create workload group group_a for compute_group_a
properties('cpu_share'='1024')
+```
+
+4. If the Compute Group is not specified when deleting a Workload Group, the
system will attempt to drop the Workload Group from the Compute Group named
default.
+```
+create workload group group_a properties('cpu_share'='1024')
+```
+
+5. Similarly, when modifying a Workload Group, the Compute Group must be
specified in the ALTER statement. If the Compute Group is not specified, the
system will attempt to modify the Workload Group under the default Compute
Group. Note that the ALTER statement only modifies the properties of the
Workload Group and cannot change its binding relationship with the Compute
Group.
+```
+alter workload group group_a for compute_group_a properties('cpu_share'='2048')
+```
+
+## NOTE
+1. Modifying the binding relationship between a Workload Group and a Compute
Group is not currently supported. A Workload Group belongs to a fixed Compute
Group upon creation and cannot be moved between Compute Groups.
+2. When upgrading Doris from an older version to a newer one, the system will
automatically create new Workload Groups with identical names (but different
IDs) for each Compute Group based on the old Workload Groups. For example, if
the old-version cluster contains two Compute Groups and there is a Workload
Group named group_a, after the upgrade, Doris will create a new group_a
Workload Group for each of these two Compute Groups. These new Workload Groups
will have different IDs from the [...]
+3. The authentication management of Workload Groups remains unchanged. The
authentication of Workload Groups is still achieved by associating with their
names.
+4. In Doris, there is a default Workload Group named normal. Whenever a new
Compute Group is created, Doris automatically generates a normal Workload Group
for it. Conversely, when a Compute Group is dropped, its corresponding normal
Workload Group is automatically removed. This means that the lifecycle
management of the normal Workload Group is fully automated by Doris and does
not require manual intervention.
\ No newline at end of file
diff --git a/docs/admin-manual/workload-management/workload-group.md
b/docs/admin-manual/workload-management/workload-group.md
index 6f54e88bd2f..0ec3102fccd 100644
--- a/docs/admin-manual/workload-management/workload-group.md
+++ b/docs/admin-manual/workload-management/workload-group.md
@@ -184,7 +184,7 @@ The CPU limit configured at this point is a soft limit.
Since version 2.1, Doris
| scan_thread_num | Integer | -1 | [1, 2147483647]
| Optional. Specifies the number of threads used for scanning in the
current Workload Group. When this property is set to -1, it means it is not
active, and the actual scan thread num on the BE will default to the
doris_scanner_thread_pool_thread_num configuration in the BE.
[...]
| max_remote_scan_thread_num | Integer | -1 | [1, 2147483647]
| Optional. Specifies the maximum number of threads in the scan thread
pool for reading external data sources. When this property is set to -1, the
actual number of threads is determined by the BE, typically based on the number
of CPU cores.
[...]
| min_remote_scan_thread_num | Integer | -1 | [1, 2147483647]
| Optional. Specifies the minimum number of threads in the scan thread
pool for reading external data sources. When this property is set to -1, the
actual number of threads is determined by the BE, typically based on the number
of CPU cores.
[...]
-| tag | String | empty | -
| Specifies tags for the Workload Group. The cumulative resource values
of Workload Groups with the same tag cannot exceed 100%. To specify multiple
values, use commas to separate them.
[...]
+| tag | String | empty | -
| This feature has been discontinued and is not recommended for use in
production environments; Specifies tags for the Workload Group. The cumulative
resource values of Workload Groups with the same tag cannot exceed 100%. To
specify multiple values, use commas to separate them.
[...]
| read_bytes_per_second | Integer | -1 | [1,
9223372036854775807] | Optional. Specifies the maximum I/O throughput when
reading internal tables in Doris. The default value is -1, meaning no I/O
bandwidth limit is applied. It is important to note that this value is not tied
to individual disks but to directories. For example, if Doris is configured
with two directories to store internal table data, the maximum read I/O for
each directory will not exceed this value. If [...]
| remote_read_bytes_per_second | Integer | -1 | [1,
9223372036854775807] | Optional. Specifies the maximum I/O throughput when
reading external tables in Doris. The default value is -1, meaning no I/O
bandwidth limit is applied.
[...]
diff --git
a/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/workload-management/workload-group-bind-compute-group.md
b/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/workload-management/workload-group-bind-compute-group.md
new file mode 100644
index 00000000000..7927ff8b3ce
--- /dev/null
+++
b/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/workload-management/workload-group-bind-compute-group.md
@@ -0,0 +1,94 @@
+---
+{
+"title": "Workload Group Bind Compute Group",
+"language": "zh-CN"
+}
+---
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+## 背景
+Doris 支持通过 Compute Group 功能对集群内的 BE
资源进行逻辑划分,形成独立的子集群单元,从而实现不同业务方计算与存储资源的物理隔离。由于各业务方的负载特性差异显著,其对 Workload Group
的配置需求往往存在明显区别。
+
+在早期版本中,用户配置的 Workload Group 会全局生效于所有 Compute Group,这导致不同业务方被迫共享同一套 Workload
Group 配置。例如,业务 A 的高并发查询与业务 B 的大规模数据分析可能需要完全不同的资源配额,而旧架构无法满足这种差异化需求,资源管理灵活性受限。
+
+为此,最新版本引入 Workload Group 绑定 Compute Group 机制,允许每个 Compute Group 配置独立的 Workload
Group。
+
+## Compute Group概念介绍
+Compute Group 最初作为存算分离架构下的核心概念,其设计目的是在单一集群内完成独立子集群的逻辑划分。而在存算一体架构中,具备同等功能的概念被称为
Resource Group,二者均能实现集群资源的隔离与分组管理。
+
+在探讨 Doris 计算资源管理体系时,可将 Compute Group 与 Resource Group
视作逻辑等价的概念,这一认知能显著降低理解成本。而在具体的接口调用层面,二者仍保持原有的独立调用规范与使用逻辑不变。
+
+因此在本文中提到的 Workload Group 绑定到的 Compute Group 的概念和用法,对于存算一体架构和存算分离架构都是适用的。
+
+## 原理介绍
+假设集群中存在两个 Compute Group,分别命名为 Compute Group A 与 Compute Group B,各自服务于业务方 A
和业务方 B,且两个业务体系完全独立运行。
+
+与此同时,集群中配置了两个 Workload Group:业务 A 创建的 group_a 与业务 B 创建的
group_b,二者的资源配置配额之和恰好占满集群总资源的 100%。
+
+### 之前版本的Workload Group设计
+在之前的版本中,group_a 和 group_b 会在所有的 BE 节点生效,即使不同的BE之间已经根据 Compute Group 进行分组。
+当业务A创建了 group_a 之后就无法再创建新的 Worload Group ,因为所有 Workload Group 的资源累加值已经达到100%;而
group_b 是业务B创建的 Worload Group,业务A和业务B是完全独立的业务方,因此业务A也无法访问和修改 group_b。
+
+即便从权限策略上打通双方对 Workload Group 的使用权限,由于业务逻辑完全独立,两者在资源配置需求上仍可能存在显著差异(如业务 A
的高并发查询与业务 B 的批量计算需不同资源配比),导致旧架构难以满足差异化管理需求。
+
+
+
+### 当前版本的Workload Group设计
+在最新的版本中,Workload Group支持绑定到Compute Group,这意味着不同的Compute Group可以有不同的Workload
Group配置。如下图所示:
+
+
+
+## 使用方法
+
+:::tip
+Doris 中设有默认 Compute Group 机制:当用户新增 BE 节点且未指定归属时,该节点将自动划分至默认 Compute
Group。具体而言,在存算分离架构下,默认 Compute Group 的名称为 default_compute_group;而在存算一体架构中,其名称则为
default。
+:::
+
+1. 创建一个名为 group_a 的 Workload Group,并把它绑定到名为compute_group_a的 Compute Group 上。
+```
+create workload group group_a for compute_group_a
properties('cpu_share'='1024')
+```
+
+2. 如果创建时不指定 Compute Group ,那么该 Workload Group 就会绑定到默认的 Compute Group 上。
+```
+create workload group group_a properties('cpu_share'='1024')
+```
+
+3. 删除 compue_group_a 中名为 group_a 的 Workload Group。
+```
+create workload group group_a for compute_group_a
properties('cpu_share'='1024')
+```
+
+4. 如果删除 Workload Group 时不指定 Compute Group ,那么尝试从名为 default 的 Compute Group
中删除这个 Workload Group。
+```
+create workload group group_a properties('cpu_share'='1024')
+```
+
+5. 修改 Workload Group 的语句同理,需要在执行alter语句时指定 Compute Group ;如果不指定 Compute Group
,那么就会尝试修改默认 Compute Group 下的 Workload Group;需要注意的是alter语句只是修改 Workload
Group的属性,并不能修改 Workload Group 和 Compute Group 的绑定关系。
+```
+alter workload group group_a for compute_group_a properties('cpu_share'='2048')
+```
+
+## 注意事项
+1. 暂不支持对 Workload Group 与 Compute Group 之间的绑定关系进行修改。Workload Group 自创建时就归属于固定的
Compute Group, 无法实现 Workload Group 在 Compute Group 之间进行移动。
+2. 在 Doris 从旧版本升级至新版本时,系统会基于旧版本的 Workload Group,为每个 Compute Group 自动创建同名但 id
不同的新 Workload Group。例如,若旧版本集群包含两个 Compute Group,且存在一个名为 group_a 的 Workload
Group,升级后,Doris 将分别为这两个 Compute Group 各创建一个名为 group_a 的新 Workload Group,其 id 与原
Workload Group 不同,而原有未归属任何 Compute Group 的 group_a 则会被系统自动删除。
+3. Workload Group的权限管理没有变化,Workload Group 的鉴权还是通过关联 Workload Group的名称实现的。
+4. 在 Doris 中存在名为 normal 的默认 Workload Group。每当新建 Compute Group 时,Doris
会自动为其创建一个名为 normal 的 Workload Group;而当某个 Compute Group 被删除,与之对应的 normal
Workload Group 也会被自动删除。这意味着,normal Workload Group 的生命周期管理均由 Doris 自动管理,无需人工介入操作。
\ No newline at end of file
diff --git
a/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/workload-management/workload-group.md
b/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/workload-management/workload-group.md
index c7f346270dc..68590c74ff0 100644
---
a/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/workload-management/workload-group.md
+++
b/i18n/zh-CN/docusaurus-plugin-content-docs/current/admin-manual/workload-management/workload-group.md
@@ -172,7 +172,7 @@ Query OK, 0 rows affected (0.03 sec)
| scan_thread_num | 整型 | -1 | [1, 2147483647] |
可选,当前 workload group 用于 scan 的线程个数。当该属性为 -1,含义是不生效,此时在 BE 上的实际取值为 BE
配置中的```doris_scanner_thread_pool_thread_num```。
|
| max_remote_scan_thread_num | 整型 | -1 | [1, 2147483647] |
可选,读外部数据源的 scan 线程池的最大线程数。当该属性为 -1 时,实际的线程数由 BE 自行决定,通常和核数相关。
|
| min_remote_scan_thread_num | 整型 | -1 | [1, 2147483647] |
可选,读外部数据源的 scan 线程池的最小线程数。当该属性为 -1 时,实际的线程数由 BE 自行决定,通常和核数相关。
|
-| tag | 字符串 | 空 | - | 为 Workload
Group 指定分组标签,相同标签的 Workload Group 资源累加值不能超过 100%;如果期望指定多个值,可以使用英文逗号分隔。
|
+| tag | 字符串 | 空 | - |
该功能已废弃,不推荐生产环境使用; 为 Workload Group 指定分组标签,相同标签的 Workload Group 资源累加值不能超过
100%;如果期望指定多个值,可以使用英文逗号分隔。
|
| read_bytes_per_second | 整型 | -1 | [1,
9223372036854775807] | 可选,含义为读 Doris 内表时的最大 IO 吞吐,默认值为 -1,也就是不限制 IO
带宽。需要注意的是这个值并不绑定磁盘,而是绑定文件夹。比如为 Doris 配置了 2 个文件夹用于存放内表数据,那么每个文件夹的最大读 IO
不会超过该值,如果这 2 个文件夹都配置到同一块盘上,最大吞吐控制就会变成 2 倍的
read_bytes_per_second。落盘的文件目录也受该值的约束。
|
| remote_read_bytes_per_second | 整型 | -1 | [1, 9223372036854775807] |
可选,含义为读 Doris 外表时的最大 IO 吞吐,默认值为 -1,也就是不限制 IO 带宽。
|
diff --git
a/i18n/zh-CN/docusaurus-plugin-content-docs/version-2.1/admin-manual/workload-management/workload-group.md
b/i18n/zh-CN/docusaurus-plugin-content-docs/version-2.1/admin-manual/workload-management/workload-group.md
index 9323a1db5cd..a0d742ac7b2 100644
---
a/i18n/zh-CN/docusaurus-plugin-content-docs/version-2.1/admin-manual/workload-management/workload-group.md
+++
b/i18n/zh-CN/docusaurus-plugin-content-docs/version-2.1/admin-manual/workload-management/workload-group.md
@@ -159,21 +159,21 @@ Query OK, 0 rows affected (0.03 sec)
### Workload Group 属性
-| 属性名称 | 数据类型 | 默认值 | 取值范围 | 说明
|
-|------------------------------|---------|-----|-----|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
-| cpu_share | 整型 | -1 | [1, 10000] | 可选,CPU
软限模式下生效,取值范围和使用的 CGroup 版本有关,下文有详细描述。cpu_share 代表了 Workload Group 可获得 CPU
时间的权重,值越大,可获得的 CPU 时间越多。例如,用户创建了 3 个 Workload Group g-a、g-b 和 g-c,cpu_share 分别为
10、30、40,某一时刻 g-a 和 g-b 正在跑任务,而 g-c 没有任务,此时 g-a 可获得 25% (10 / (10 + 30)) 的 CPU
资源,而 g-b 可获得 75% 的 CPU 资源。如果系统只有一个 Workload Group 正在运行,则不管其 cpu_share
的值为多少,它都可获取全部的 CPU 资源。 |
-| memory_limit | 浮点 | -1 | (0%, 100%] |
可选,开启内存硬限时代表当前 Workload Group 最大可用内存百分比,默认值代表不限制内存。所有 Workload Group 的
memory_limit 累加值不可以超过 100%,通常与 enable_memory_overcommit 属性配合使用。如果一个机器的内存为
64G,Workload Group 的 memory_limit 配置为 50%,那么该 group 的实际物理内存=64G * 90% * 50%=
28.8G,这里的 90% 是 BE 进程可用内存配置的默认值。
|
+| 属性名称 | 数据类型 | 默认值 | 取值范围 | 说明
|
+|------------------------------|---------|-----|-----|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
+| cpu_share | 整型 | -1 | [1, 10000] | 可选,CPU
软限模式下生效,取值范围和使用的 CGroup 版本有关,下文有详细描述。cpu_share 代表了 Workload Group 可获得 CPU
时间的权重,值越大,可获得的 CPU 时间越多。例如,用户创建了 3 个 Workload Group g-a、g-b 和 g-c,cpu_share 分别为
10、30、40,某一时刻 g-a 和 g-b 正在跑任务,而 g-c 没有任务,此时 g-a 可获得 25% (10 / (10 + 30)) 的 CPU
资源,而 g-b 可获得 75% 的 CPU 资源。如果系统只有一个 Workload Group 正在运行,则不管其 cpu_share
的值为多少,它都可获取全部的 CPU 资源。 |
+| memory_limit | 浮点 | -1 | (0%, 100%] |
可选,开启内存硬限时代表当前 Workload Group 最大可用内存百分比,默认值代表不限制内存。所有 Workload Group 的
memory_limit 累加值不可以超过 100%,通常与 enable_memory_overcommit 属性配合使用。如果一个机器的内存为
64G,Workload Group 的 memory_limit 配置为 50%,那么该 group 的实际物理内存=64G * 90% * 50%=
28.8G,这里的 90% 是 BE 进程可用内存配置的默认值。
|
| enable_memory_overcommit | 布尔 | true | true, false |
可选,用于控制当前 Workload Group 的内存限制是硬限还是软限,默认为 true。如果设置为 false,则该 workload group
为内存硬隔离,系统检测到 workload group 内存使用超出限制后将立即 cancel 组内内存占用最大的若干个任务,以释放超出的内存;如果设置为
true,则该 Workload Group 为内存软隔离,如果系统有空闲内存资源则该 Workload Group 在超出 memory_limit
的限制后可继续使用系统内存,在系统总内存紧张时会 cancel 组内内存占用最大的若干个任务,释放部分超出的内存以缓解系统内存压力。建议所有 workload
group 的 memory_limit 总和低于 100%,为 BE 进程中的其他组件保留一些内存。 |
-| cpu_hard_limit | 整型 | -1 | [1%, 100%] |
可选,CPU 硬限制模式下生效,Workload Group 最大可用 CPU 百分比,不管当前机器的 CPU 资源是否被用满,Workload Group
的最大 CPU 用量都不能超过 cpu_hard_limit,所有 Workload Group 的 cpu_hard_limit 累加值不能超过
100%。2.1 版本新增属性,2.0 版本不支持该功能。
|
-| max_concurrency | 整型 | 2147483647 | [0, 2147483647] |
可选,最大查询并发数,默认值为整型最大值,也就是不做并发的限制。运行中的查询数量达到最大并发时,新来的查询会进入排队的逻辑。
|
-| max_queue_size | 整型 | 0 | [0, 2147483647] |
可选,查询排队队列的长度,当排队队列已满时,新来的查询会被拒绝。默认值为 0,含义是不排队。当排队队列已满时,新来的查询会直接失败。
|
-| queue_timeout | 整型 | 0 | [0, 2147483647] |
可选,查询在排队队列中的最大等待时间,单位为毫秒。如果查询在队列中的排队时间超过这个值,那么就会直接抛出异常给客户端。默认值为
0,含义是不排队,查询进入队列后立即返回失败。
|
+| cpu_hard_limit | 整型 | -1 | [1%, 100%] |
可选,CPU 硬限制模式下生效,Workload Group 最大可用 CPU 百分比,不管当前机器的 CPU 资源是否被用满,Workload Group
的最大 CPU 用量都不能超过 cpu_hard_limit,所有 Workload Group 的 cpu_hard_limit 累加值不能超过
100%。2.1 版本新增属性,2.0 版本不支持该功能。
|
+| max_concurrency | 整型 | 2147483647 | [0, 2147483647] |
可选,最大查询并发数,默认值为整型最大值,也就是不做并发的限制。运行中的查询数量达到最大并发时,新来的查询会进入排队的逻辑。
|
+| max_queue_size | 整型 | 0 | [0, 2147483647] |
可选,查询排队队列的长度,当排队队列已满时,新来的查询会被拒绝。默认值为 0,含义是不排队。当排队队列已满时,新来的查询会直接失败。
|
+| queue_timeout | 整型 | 0 | [0, 2147483647] |
可选,查询在排队队列中的最大等待时间,单位为毫秒。如果查询在队列中的排队时间超过这个值,那么就会直接抛出异常给客户端。默认值为
0,含义是不排队,查询进入队列后立即返回失败。
|
| scan_thread_num | 整型 | -1 | [1, 2147483647] |
可选,当前 workload group 用于 scan 的线程个数。当该属性为 -1,含义是不生效,此时在 BE 上的实际取值为 BE
配置中的```doris_scanner_thread_pool_thread_num```。
|
-| max_remote_scan_thread_num | 整型 | -1 | [1, 2147483647] |
可选,读外部数据源的 scan 线程池的最大线程数。当该属性为 -1 时,实际的线程数由 BE 自行决定,通常和核数相关。
|
-| min_remote_scan_thread_num | 整型 | -1 | [1, 2147483647] |
可选,读外部数据源的 scan 线程池的最小线程数。当该属性为 -1 时,实际的线程数由 BE 自行决定,通常和核数相关。
|
-| tag | 字符串 | 空 | - | 为 Workload
Group 指定分组标签,相同标签的 Workload Group 资源累加值不能超过 100%;如果期望指定多个值,可以使用英文逗号分隔。
|
-| read_bytes_per_second | 整型 | -1 | [1,
9223372036854775807] | 可选,含义为读 Doris 内表时的最大 IO 吞吐,默认值为 -1,也就是不限制 IO
带宽。需要注意的是这个值并不绑定磁盘,而是绑定文件夹。比如为 Doris 配置了 2 个文件夹用于存放内表数据,那么每个文件夹的最大读 IO
不会超过该值,如果这 2 个文件夹都配置到同一块盘上,最大吞吐控制就会变成 2 倍的
read_bytes_per_second。落盘的文件目录也受该值的约束。
|
-| remote_read_bytes_per_second | 整型 | -1 | [1, 9223372036854775807] |
可选,含义为读 Doris 外表时的最大 IO 吞吐,默认值为 -1,也就是不限制 IO 带宽。
|
+| max_remote_scan_thread_num | 整型 | -1 | [1, 2147483647] |
可选,读外部数据源的 scan 线程池的最大线程数。当该属性为 -1 时,实际的线程数由 BE 自行决定,通常和核数相关。
|
+| min_remote_scan_thread_num | 整型 | -1 | [1, 2147483647] |
可选,读外部数据源的 scan 线程池的最小线程数。当该属性为 -1 时,实际的线程数由 BE 自行决定,通常和核数相关。
|
+| tag | 字符串 | 空 | - |
该功能已废弃,不推荐生产环境使用; 为 Workload Group 指定分组标签,相同标签的 Workload Group 资源累加值不能超过
100%;如果期望指定多个值,可以使用英文逗号分隔。
|
+| read_bytes_per_second | 整型 | -1 | [1,
9223372036854775807] | 可选,含义为读 Doris 内表时的最大 IO 吞吐,默认值为 -1,也就是不限制 IO
带宽。需要注意的是这个值并不绑定磁盘,而是绑定文件夹。比如为 Doris 配置了 2 个文件夹用于存放内表数据,那么每个文件夹的最大读 IO
不会超过该值,如果这 2 个文件夹都配置到同一块盘上,最大吞吐控制就会变成 2 倍的
read_bytes_per_second。落盘的文件目录也受该值的约束。
|
+| remote_read_bytes_per_second | 整型 | -1 | [1, 9223372036854775807] |
可选,含义为读 Doris 外表时的最大 IO 吞吐,默认值为 -1,也就是不限制 IO 带宽。
|
:::tip
diff --git
a/i18n/zh-CN/docusaurus-plugin-content-docs/version-3.0/admin-manual/workload-management/workload-group.md
b/i18n/zh-CN/docusaurus-plugin-content-docs/version-3.0/admin-manual/workload-management/workload-group.md
index e70e70f6b01..1e9afd7a022 100644
---
a/i18n/zh-CN/docusaurus-plugin-content-docs/version-3.0/admin-manual/workload-management/workload-group.md
+++
b/i18n/zh-CN/docusaurus-plugin-content-docs/version-3.0/admin-manual/workload-management/workload-group.md
@@ -171,7 +171,7 @@ Query OK, 0 rows affected (0.03 sec)
| scan_thread_num | 整型 | -1 | [1, 2147483647] |
可选,当前 workload group 用于 scan 的线程个数。当该属性为 -1,含义是不生效,此时在 BE 上的实际取值为 BE
配置中的```doris_scanner_thread_pool_thread_num```。
|
| max_remote_scan_thread_num | 整型 | -1 | [1, 2147483647] |
可选,读外部数据源的 scan 线程池的最大线程数。当该属性为 -1 时,实际的线程数由 BE 自行决定,通常和核数相关。
|
| min_remote_scan_thread_num | 整型 | -1 | [1, 2147483647] |
可选,读外部数据源的 scan 线程池的最小线程数。当该属性为 -1 时,实际的线程数由 BE 自行决定,通常和核数相关。
|
-| tag | 字符串 | 空 | - | 为 Workload
Group 指定分组标签,相同标签的 Workload Group 资源累加值不能超过 100%;如果期望指定多个值,可以使用英文逗号分隔。
|
+| tag | 字符串 | 空 | - |
该功能已废弃,不推荐生产环境使用; 为 Workload Group 指定分组标签,相同标签的 Workload Group 资源累加值不能超过
100%;如果期望指定多个值,可以使用英文逗号分隔。
|
| read_bytes_per_second | 整型 | -1 | [1,
9223372036854775807] | 可选,含义为读 Doris 内表时的最大 IO 吞吐,默认值为 -1,也就是不限制 IO
带宽。需要注意的是这个值并不绑定磁盘,而是绑定文件夹。比如为 Doris 配置了 2 个文件夹用于存放内表数据,那么每个文件夹的最大读 IO
不会超过该值,如果这 2 个文件夹都配置到同一块盘上,最大吞吐控制就会变成 2 倍的
read_bytes_per_second。落盘的文件目录也受该值的约束。
|
| remote_read_bytes_per_second | 整型 | -1 | [1, 9223372036854775807] |
可选,含义为读 Doris 外表时的最大 IO 吞吐,默认值为 -1,也就是不限制 IO 带宽。
|
diff --git a/static/images/wg_bind_cg1.png b/static/images/wg_bind_cg1.png
new file mode 100644
index 00000000000..9b176e2d047
Binary files /dev/null and b/static/images/wg_bind_cg1.png differ
diff --git a/static/images/wg_bind_cg2.png b/static/images/wg_bind_cg2.png
new file mode 100644
index 00000000000..0f13e132705
Binary files /dev/null and b/static/images/wg_bind_cg2.png differ
diff --git
a/versioned_docs/version-2.1/admin-manual/workload-management/workload-group.md
b/versioned_docs/version-2.1/admin-manual/workload-management/workload-group.md
index 4684f76d772..1a31fe5e0c0 100644
---
a/versioned_docs/version-2.1/admin-manual/workload-management/workload-group.md
+++
b/versioned_docs/version-2.1/admin-manual/workload-management/workload-group.md
@@ -184,7 +184,7 @@ The CPU limit configured at this point is a soft limit.
Since version 2.1, Doris
| scan_thread_num | Integer | -1 | [1, 2147483647]
| Optional. Specifies the number of threads used for scanning in the
current Workload Group. When this property is set to -1, it means it is not
active, and the actual scan thread num on the BE will default to the
doris_scanner_thread_pool_thread_num configuration in the BE.
[...]
| max_remote_scan_thread_num | Integer | -1 | [1, 2147483647]
| Optional. Specifies the maximum number of threads in the scan thread
pool for reading external data sources. When this property is set to -1, the
actual number of threads is determined by the BE, typically based on the number
of CPU cores.
[...]
| min_remote_scan_thread_num | Integer | -1 | [1, 2147483647]
| Optional. Specifies the minimum number of threads in the scan thread
pool for reading external data sources. When this property is set to -1, the
actual number of threads is determined by the BE, typically based on the number
of CPU cores.
[...]
-| tag | String | empty | -
| Specifies tags for the Workload Group. The cumulative resource values
of Workload Groups with the same tag cannot exceed 100%. To specify multiple
values, use commas to separate them.
[...]
+| tag | String | empty | -
| This feature has been discontinued and is not recommended for use in
production environments; Specifies tags for the Workload Group. The cumulative
resource values of Workload Groups with the same tag cannot exceed 100%. To
specify multiple values, use commas to separate them.
[...]
| read_bytes_per_second | Integer | -1 | [1,
9223372036854775807] | Optional. Specifies the maximum I/O throughput when
reading internal tables in Doris. The default value is -1, meaning no I/O
bandwidth limit is applied. It is important to note that this value is not tied
to individual disks but to directories. For example, if Doris is configured
with two directories to store internal table data, the maximum read I/O for
each directory will not exceed this value. If [...]
| remote_read_bytes_per_second | Integer | -1 | [1,
9223372036854775807] | Optional. Specifies the maximum I/O throughput when
reading external tables in Doris. The default value is -1, meaning no I/O
bandwidth limit is applied.
[...]
diff --git
a/versioned_docs/version-3.0/admin-manual/workload-management/workload-group.md
b/versioned_docs/version-3.0/admin-manual/workload-management/workload-group.md
index 4684f76d772..727d77c997c 100644
---
a/versioned_docs/version-3.0/admin-manual/workload-management/workload-group.md
+++
b/versioned_docs/version-3.0/admin-manual/workload-management/workload-group.md
@@ -172,21 +172,21 @@ The CPU limit configured at this point is a soft limit.
Since version 2.1, Doris
### Workload Group Properties
-| Property | Data type | Default value | Value range
| Description
[...]
-|------------------------------|-----------|---------------|--------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
[...]
-| cpu_share | Integer | -1 | [1, 10000]
| Optional, effective under CPU soft limit mode. The valid range of
values depends on the version of CGroup being used, which is described in
detail later. cpu_share represents the weight of CPU time that the Workload
Group can acquire; the larger the value, the more CPU time it can obtain. For
example, if the user creates three Workload Groups, g-a, g-b, and g-c, with
cpu_share values of 10, 30, and 40 [...]
-| memory_limit | Float | -1 | (0%, 100%]
| Optional. Enabling memory hard limit represents the maximum available
memory percentage for the current Workload Group. The default value means no
memory limit is applied. The cumulative value of memory_limit for all Workload
Groups cannot exceed 100%, and it is typically used in conjunction with the
enable_memory_overcommit attribute. For example, if a machine has 64GB of
memory and the memory_limit [...]
+| Property | Data type | Default value | Value range
| Description
[...]
+|------------------------------|-----------|---------------|--------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
[...]
+| cpu_share | Integer | -1 | [1, 10000]
| Optional, effective under CPU soft limit mode. The valid range of
values depends on the version of CGroup being used, which is described in
detail later. cpu_share represents the weight of CPU time that the Workload
Group can acquire; the larger the value, the more CPU time it can obtain. For
example, if the user creates three Workload Groups, g-a, g-b, and g-c, with
cpu_share values of 10, 30, and 40 [...]
+| memory_limit | Float | -1 | (0%, 100%]
| Optional. Enabling memory hard limit represents the maximum available
memory percentage for the current Workload Group. The default value means no
memory limit is applied. The cumulative value of memory_limit for all Workload
Groups cannot exceed 100%, and it is typically used in conjunction with the
enable_memory_overcommit attribute. For example, if a machine has 64GB of
memory and the memory_limit [...]
| enable_memory_overcommit | Boolean | true | true, false
| Optional. Used to control whether the memory limit for the current
Workload Group is a hard limit or a soft limit, with the default set to true.
If set to false, the Workload Group will have hard memory limit, and when the
system detects that the memory usage exceeds the limit, it will immediately
cancel the tasks with the highest memory usage within the group to release the
excess memory. If set to t [...]
-| cpu_hard_limit | Integer | -1 | [1%, 100%]
| Optional. Effective under CPU hard limit mode, it represents the
maximum CPU percentage a Workload Group can use. Regardless of whether the
machine's CPU resources are fully utilized, the Workload Group's CPU usage
cannot exceed the cpu_hard_limit. The cumulative value of cpu_hard_limit for
all Workload Groups cannot exceed 100%. This attribute was introduced in
version 2.1 and is not supported in ver [...]
-| max_concurrency | Integer | 2147483647 | [0, 2147483647]
| Optional. Specifies the maximum query concurrency. The default value
is the maximum value of an integer, meaning no concurrency limit. When the
number of running queries reaches the maximum concurrency, new queries will
enter a queue.
[...]
-| max_queue_size | Integer | 0 | [0, 2147483647]
| Optional. Specifies the length of the query waiting queue. When the
queue is full, new queries will be rejected. The default value is 0, which
means no queuing. If the queue is full, new queries will fail directly.
[...]
-| queue_timeout | Integer | 0 | [0, 2147483647]
| Optional. Specifies the maximum waiting time for a query in the
waiting queue, in milliseconds. If the query's waiting time in the queue
exceeds this value, an exception will be thrown directly to the client. The
default value is 0, meaning no queuing; queries will immediately fail upon
entering the queue.
[...]
-| scan_thread_num | Integer | -1 | [1, 2147483647]
| Optional. Specifies the number of threads used for scanning in the
current Workload Group. When this property is set to -1, it means it is not
active, and the actual scan thread num on the BE will default to the
doris_scanner_thread_pool_thread_num configuration in the BE.
[...]
-| max_remote_scan_thread_num | Integer | -1 | [1, 2147483647]
| Optional. Specifies the maximum number of threads in the scan thread
pool for reading external data sources. When this property is set to -1, the
actual number of threads is determined by the BE, typically based on the number
of CPU cores.
[...]
-| min_remote_scan_thread_num | Integer | -1 | [1, 2147483647]
| Optional. Specifies the minimum number of threads in the scan thread
pool for reading external data sources. When this property is set to -1, the
actual number of threads is determined by the BE, typically based on the number
of CPU cores.
[...]
-| tag | String | empty | -
| Specifies tags for the Workload Group. The cumulative resource values
of Workload Groups with the same tag cannot exceed 100%. To specify multiple
values, use commas to separate them.
[...]
-| read_bytes_per_second | Integer | -1 | [1,
9223372036854775807] | Optional. Specifies the maximum I/O throughput when
reading internal tables in Doris. The default value is -1, meaning no I/O
bandwidth limit is applied. It is important to note that this value is not tied
to individual disks but to directories. For example, if Doris is configured
with two directories to store internal table data, the maximum read I/O for
each directory will not exceed this value. If [...]
-| remote_read_bytes_per_second | Integer | -1 | [1,
9223372036854775807] | Optional. Specifies the maximum I/O throughput when
reading external tables in Doris. The default value is -1, meaning no I/O
bandwidth limit is applied.
[...]
+| cpu_hard_limit | Integer | -1 | [1%, 100%]
| Optional. Effective under CPU hard limit mode, it represents the
maximum CPU percentage a Workload Group can use. Regardless of whether the
machine's CPU resources are fully utilized, the Workload Group's CPU usage
cannot exceed the cpu_hard_limit. The cumulative value of cpu_hard_limit for
all Workload Groups cannot exceed 100%. This attribute was introduced in
version 2.1 and is not supported in ver [...]
+| max_concurrency | Integer | 2147483647 | [0, 2147483647]
| Optional. Specifies the maximum query concurrency. The default value
is the maximum value of an integer, meaning no concurrency limit. When the
number of running queries reaches the maximum concurrency, new queries will
enter a queue.
[...]
+| max_queue_size | Integer | 0 | [0, 2147483647]
| Optional. Specifies the length of the query waiting queue. When the
queue is full, new queries will be rejected. The default value is 0, which
means no queuing. If the queue is full, new queries will fail directly.
[...]
+| queue_timeout | Integer | 0 | [0, 2147483647]
| Optional. Specifies the maximum waiting time for a query in the
waiting queue, in milliseconds. If the query's waiting time in the queue
exceeds this value, an exception will be thrown directly to the client. The
default value is 0, meaning no queuing; queries will immediately fail upon
entering the queue.
[...]
+| scan_thread_num | Integer | -1 | [1, 2147483647]
| Optional. Specifies the number of threads used for scanning in the
current Workload Group. When this property is set to -1, it means it is not
active, and the actual scan thread num on the BE will default to the
doris_scanner_thread_pool_thread_num configuration in the BE.
[...]
+| max_remote_scan_thread_num | Integer | -1 | [1, 2147483647]
| Optional. Specifies the maximum number of threads in the scan thread
pool for reading external data sources. When this property is set to -1, the
actual number of threads is determined by the BE, typically based on the number
of CPU cores.
[...]
+| min_remote_scan_thread_num | Integer | -1 | [1, 2147483647]
| Optional. Specifies the minimum number of threads in the scan thread
pool for reading external data sources. When this property is set to -1, the
actual number of threads is determined by the BE, typically based on the number
of CPU cores.
[...]
+| tag | String | empty | -
| This feature has been discontinued and is not recommended for use in
production environments; Specifies tags for the Workload Group. The cumulative
resource values of Workload Groups with the same tag cannot exceed 100%. To
specify multiple values, use commas to separate them.
[...]
+| read_bytes_per_second | Integer | -1 | [1,
9223372036854775807] | Optional. Specifies the maximum I/O throughput when
reading internal tables in Doris. The default value is -1, meaning no I/O
bandwidth limit is applied. It is important to note that this value is not tied
to individual disks but to directories. For example, if Doris is configured
with two directories to store internal table data, the maximum read I/O for
each directory will not exceed this value. If [...]
+| remote_read_bytes_per_second | Integer | -1 | [1,
9223372036854775807] | Optional. Specifies the maximum I/O throughput when
reading external tables in Doris. The default value is -1, meaning no I/O
bandwidth limit is applied.
[...]
:::tip
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]