Skip to content

Add doc for tidb_executor_concurrency#3975

Merged
TomShawn merged 20 commits into
pingcap:masterfrom
niedhui:executor_concurrency
Jan 12, 2021
Merged

Add doc for tidb_executor_concurrency#3975
TomShawn merged 20 commits into
pingcap:masterfrom
niedhui:executor_concurrency

Conversation

@niedhui
Copy link
Copy Markdown
Contributor

@niedhui niedhui commented Jul 15, 2020

What is changed, added or deleted? (Required)

Add docs for the new system variable, tidb_executor_concurrency

Which TiDB version(s) do your changes apply to? (Required)

  • master (the latest development version)
  • v4.0 (TiDB 4.0 versions)
  • v3.1 (TiDB 3.1 versions)
  • v3.0 (TiDB 3.0 versions)
  • v2.1 (TiDB 2.1 versions)

What is the related PR or file link(s)?

Signed-off-by: niedhui <niedhui@gmail.com>
@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Jul 15, 2020

CLA assistant check
All committers have signed the CLA.

@niedhui niedhui force-pushed the executor_concurrency branch from baa53ea to 098b758 Compare July 15, 2020 16:16
@TomShawn TomShawn requested review from SunRunAway and TomShawn July 16, 2020 01:59
@TomShawn TomShawn self-assigned this Jul 16, 2020
@TomShawn TomShawn added translation/doing This PR’s assignee is translating this PR. v5.0 This PR/issue applies to TiDB v5.0 size/small Changes of a small size. labels Jul 16, 2020
Comment thread tidb-specific-system-variables.md Outdated

对于从 5.0.0 之前的版本升级到 5.0.0 的系统, 如果用户对上述七个变量没有做过改动(即 `tidb_hash_join_concurrency` 值为5,其他值为4),则会迁移到使用 `tidb_executor_concurrency` 来统一管理并发度, 否则继续沿用之前的变量值对相应的算子做并发控制。

### tidb_index_lookup_concurrency
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

修改一下这些变量的默认值,并且标明废弃吧。

Comment thread tidb-specific-system-variables.md Outdated

默认值:5

这个变量用来设置 index lookup,index lookup join,hash join,hash aggregation,window,projection 算子的并发度。
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
这个变量用来设置 index lookup,index lookup join,hash join,hash aggregation,window,projection 算子的并发度。
这个变量用来统一设置各个 SQL 算子的并发度。
包括:
- index lookup
- index lookup join
- hash join
- hash aggregation
- window
- projection

Comment thread tidb-specific-system-variables.md Outdated
Comment on lines +166 to +168
`tidb_executor_concurrency` 主要整合了之前的 `tidb_index_lookup_concurrency`,`tidb_index_lookup_join_concurrency`,`tidb_hash_join_concurrency`,`tidb_hashagg_partial_concurrency`,`tidb_hashagg_final_concurrency`,`tidb_projection_concurrency` 及 `tidb_window_concurrency` 这七个系统变量,方便管理。

用户仍可以对上述七个系统变量做单独修改(会有废弃警告),修改只影响单个算子,后续对 `tidb_executor_concurrency` 的修改也不会影响该算子。可以通过将其值设置为`-1`,还原成通过 `tidb_executor_concurrency` 来管理该算子的并发度。
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

在这七个变量的地方也放上兼容性说明吧。

Comment thread tidb-specific-system-variables.md Outdated

用户仍可以对上述七个系统变量做单独修改(会有废弃警告),修改只影响单个算子,后续对 `tidb_executor_concurrency` 的修改也不会影响该算子。可以通过将其值设置为`-1`,还原成通过 `tidb_executor_concurrency` 来管理该算子的并发度。

对于从 5.0.0 之前的版本升级到 5.0.0 的系统, 如果用户对上述七个变量没有做过改动(即 `tidb_hash_join_concurrency` 值为5,其他值为4),则会迁移到使用 `tidb_executor_concurrency` 来统一管理并发度, 否则继续沿用之前的变量值对相应的算子做并发控制。
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

现在最新版是 4.0.2 吧,接下来是 4.0.3。升级到 5.0.0 的系统 的表述会不会太早?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个不会cherry pick 就是针对5.0的。

@TomShawn TomShawn requested review from TomShawn and scsldb July 16, 2020 06:00
@niedhui niedhui force-pushed the executor_concurrency branch from 6a505ff to 56d983d Compare July 16, 2020 06:36
Comment thread tidb-specific-system-variables.md Outdated

这个变量用来设置 index lookup 操作的 batch 大小,AP 类应用适合较大的值,TP 类应用适合较小的值。

### tidb_executor_concurrency <span class="version-mark">从 v5.0 版本开始引入</span>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@scsldb 现在 dev 文档中是否可以采用 v5.0 版本的表述呢?

Signed-off-by: niedhui <niedhui@gmail.com>
@niedhui niedhui force-pushed the executor_concurrency branch from 56d983d to 6e820e2 Compare July 16, 2020 06:39
Comment thread tidb-specific-system-variables.md Outdated

这个变量用来设置 index lookup 操作的并发度,AP 类应用适合较大的值,TP 类应用适合较小的值。

注意:从 5.0.0 版本开始,该变量已被废弃,请使用 [tidb_executor_concurrency](/tidb-specific-system-variables.md#tidb_executor_concurrency) 进行设置。
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@SunRunAway

  • 目前 v5.0 连 beta 都没发,已被废弃要不要换成将被废弃
  • 请采用如下 note 格式
  • 同一文档内的标题锚点,无需 /tidb-specific-system-variables.md 部分
Suggested change
注意:从 5.0.0 版本开始,该变量已被废弃,请使用 [tidb_executor_concurrency](/tidb-specific-system-variables.md#tidb_executor_concurrency) 进行设置。
> **注意:**
>
> 从 5.0.0 版本开始,该变量将被废弃,请使用 [tidb_executor_concurrency](#tidb_executor_concurrency) 进行设置。

niedhui and others added 2 commits July 16, 2020 14:54
Signed-off-by: niedhui <niedhui@gmail.com>
@lilin90 lilin90 added the status/PTAL This PR is ready for reviewing. label Jul 30, 2020
@lilin90
Copy link
Copy Markdown
Member

lilin90 commented Jul 30, 2020

@TomShawn Would you please help resolve the conflict? Thanks!

@TomShawn
Copy link
Copy Markdown
Contributor

@TomShawn Would you please help resolve the conflict? Thanks!

Conflict resolved, PTAL

Comment thread system-variables.md Outdated
- 默认值:20000
- 这个变量用来设置 index lookup 操作的 batch 大小,AP 类应用适合较大的值,TP 类应用适合较小的值。

### `tidb_executor_concurrency` <span class="version-mark">从 v5.0 版本开始引入</span>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

当前 5.0 还没有发布,文档中就出现 5.0 不太合适

@SunRunAway
Copy link
Copy Markdown
Contributor

Let's hold this PR before the release of 5.0

Comment thread system-variables.md Outdated
Comment thread system-variables.md Outdated
Comment thread system-variables.md Outdated
Comment thread system-variables.md Outdated
Comment thread system-variables.md Outdated
Comment thread system-variables.md Outdated
Comment thread system-variables.md Outdated
Comment thread system-variables.md Outdated
@ti-srebot
Copy link
Copy Markdown
Contributor

@SunRunAway, @TomShawn, @scsldb, @lilin90, PTAL.

1 similar comment
@ti-srebot
Copy link
Copy Markdown
Contributor

@SunRunAway, @TomShawn, @scsldb, @lilin90, PTAL.

@SunRunAway
Copy link
Copy Markdown
Contributor

@XuHuaiyu PTAL

@ti-srebot
Copy link
Copy Markdown
Contributor

@SunRunAway, @TomShawn, @scsldb, @lilin90, PTAL.

@morgo
Copy link
Copy Markdown

morgo commented Jan 11, 2021

Can we please merge + translate this? It is an important change, with no user documentation so far.

Copy link
Copy Markdown
Contributor

@XuHuaiyu XuHuaiyu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ti-srebot
Copy link
Copy Markdown
Contributor

@XuHuaiyu, Thanks for your review. The bot only counts LGTMs from Reviewers and higher roles, but you're still welcome to leave your comments. See the corresponding SIG page for more information. Related SIG: docs(slack).

Copy link
Copy Markdown
Contributor

@TomShawn TomShawn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ti-srebot ti-srebot added the status/LGT1 Indicates that a PR has LGTM 1. label Jan 12, 2021
@TomShawn TomShawn merged commit 3179db6 into pingcap:master Jan 12, 2021
ti-srebot pushed a commit to ti-srebot/docs-cn that referenced this pull request Jan 12, 2021
Signed-off-by: ti-srebot <ti-srebot@pingcap.com>
@ti-srebot
Copy link
Copy Markdown
Contributor

cherry pick to release-5.0 in PR #5298

TomShawn pushed a commit that referenced this pull request Jan 12, 2021
Signed-off-by: ti-srebot <ti-srebot@pingcap.com>

Co-authored-by: niedhui <niedhui@gmail.com>
@TomShawn TomShawn added translation/done This PR has been translated from English into Chinese and updated to pingcap/docs-cn in a PR. and removed translation/doing This PR’s assignee is translating this PR. labels Jan 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/small Changes of a small size. status/LGT1 Indicates that a PR has LGTM 1. translation/done This PR has been translated from English into Chinese and updated to pingcap/docs-cn in a PR. v5.0 This PR/issue applies to TiDB v5.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants