Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tidb: remove experimental warnings for stats lock #16351

Merged
merged 6 commits into from
Feb 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions basic-features.md
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ aliases: ['/docs-cn/dev/basic-features/','/docs-cn/dev/experimental-features-4.0

## 统计信息

| 统计信息 | 7.5 | 7.5 | 7.1 | 6.5 | 6.1 | 5.4 | 5.3 | 5.2 | 5.1 | 5.0 | 4.0 |
| 统计信息 | 7.6 | 7.5 | 7.1 | 6.5 | 6.1 | 5.4 | 5.3 | 5.2 | 5.1 | 5.0 | 4.0 |
|---|:----:|:----:|:---:|:---:|:---:|:---:|:---:|:---:|:---:|:---:|:---:|
| [CM-Sketch](/statistics.md) | 默认关闭 | 默认关闭 | 默认关闭 | 默认关闭 | 默认关闭 | 默认关闭 | 默认关闭 | Y | Y | Y | Y |
| [直方图](/statistics.md) | Y | Y | Y | Y | Y | Y | Y | Y | Y | Y | Y |
Expand All @@ -178,7 +178,7 @@ aliases: ['/docs-cn/dev/basic-features/','/docs-cn/dev/experimental-features-4.0
| [收集部分列的统计信息](/statistics.md#收集部分列的统计信息) | E | E | E | E | E | E | N | N | N | N | N |
| [限制统计信息的内存使用量](/statistics.md#统计信息收集的内存限制) | E | E | E | E | E | N | N | N | N | N | N |
| [随机采样约 10000 行数据来快速构建统计信息](/system-variables.md#tidb_enable_fast_analyze) | 已废弃 | 已废弃 | E | E | E | E | E | E | E | E | E |
| [锁定统计信息](/statistics.md#锁定统计信息) | E | E | E | E | N | N | N | N | N | N | N |
| [锁定统计信息](/statistics.md#锁定统计信息) | Y | Y | E | E | N | N | N | N | N | N | N |
| [轻量级统计信息初始化](/statistics.md#统计信息的加载) | Y | Y | E | N | N | N | N | N | N | N | N |
| [显示统计信息收集的进度](/sql-statements/sql-statement-show-analyze-status.md) | Y | Y | N | N | N | N | N | N | N | N | N |

Expand Down Expand Up @@ -268,4 +268,4 @@ aliases: ['/docs-cn/dev/basic-features/','/docs-cn/dev/experimental-features-4.0

[^6]: 对于 TiDB v4.0,事务 `LOAD DATA` 不保证原子性。

[^7]: 从 v7.5.0 开始,不再提供 [TiDB Binlog](/tidb-binlog/tidb-binlog-overview.md) 数据同步功能的技术支持,强烈建议使用 [TiCDC](/ticdc/ticdc-overview.md) 实现高效稳定的数据同步。尽管 TiDB Binlog 在 v7.5.0 仍支持 Point-in-Time Recovery (PITR) 场景,但是该组件在未来 LTS 版本中将被完全废弃,推荐使用 [PITR](/br/br-pitr-guide.md) 替代。
[^7]: 从 v7.5.0 开始,不再提供 [TiDB Binlog](/tidb-binlog/tidb-binlog-overview.md) 数据同步功能的技术支持,强烈建议使用 [TiCDC](/ticdc/ticdc-overview.md) 实现高效稳定的数据同步。尽管 TiDB Binlog 在 v7.5.0 仍支持 Point-in-Time Recovery (PITR) 场景,但是该组件在未来 LTS 版本中将被完全废弃,推荐使用 [PITR](/br/br-pitr-guide.md) 替代。
4 changes: 2 additions & 2 deletions releases/release-7.4.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -185,9 +185,9 @@ TiDB 版本:7.4.0

更多信息,请参考[用户文档](/tidb-resource-control.md#管理后台任务)。

* 增强锁定统计信息的能力 [#46351](https://github.com/pingcap/tidb/issues/46351) @[hi-rustin](https://github.com/hi-rustin)
* 锁定统计信息成为正式功能 (GA) [#46351](https://github.com/pingcap/tidb/issues/46351) @[hi-rustin](https://github.com/hi-rustin)

在 v7.4.0 中,TiDB 增强了[锁定统计信息](/statistics.md#锁定统计信息)的能力。现在,锁定和解锁统计信息需要与收集统计信息 (`ANALYZE TABLE`) 相同的权限,以确保操作的安全性。此外,还新增了对特定分区的统计信息进行锁定和解锁操作的支持,提高了功能灵活性。当用户对数据库中的查询和执行计划有把握,并且不希望发生变化时,可以使用锁定统计信息来提升统计信息的稳定性。
在 v7.4.0 中,TiDB [锁定统计信息](/statistics.md#锁定统计信息)成为正式功能 (GA)。现在,锁定和解锁统计信息需要与收集统计信息 (`ANALYZE TABLE`) 相同的权限,以确保操作的安全性。此外,还新增了对特定分区的统计信息进行锁定和解锁操作的支持,提高了功能灵活性。当用户对数据库中的查询和执行计划有把握,并且不希望发生变化时,可以使用锁定统计信息来提升统计信息的稳定性。

更多信息,请参考[用户文档](/statistics.md#锁定统计信息)。

Expand Down
4 changes: 0 additions & 4 deletions sql-statements/sql-statement-lock-stats.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,6 @@ summary: TiDB 数据库中 LOCK STATS 的使用概况。

`LOCK STATS` 语句用于锁定表或分区的统计信息,使得在锁定期间,TiDB 不会自动更新统计信息。具体行为请参见[锁定统计信息的行为说明](/statistics.md#锁定统计信息的行为说明)。

> **警告:**
>
> 锁定统计信息目前为实验特性,不建议在生产环境中使用。

## 语法图

```ebnf+diagram
Expand Down
4 changes: 0 additions & 4 deletions sql-statements/sql-statement-show-stats-locked.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,6 @@ summary: TiDB 数据库中 SHOW STATS_LOCKED 的使用概况。

`SHOW STATS_LOCKED` 语句显示统计信息被锁定的表。

> **警告:**
>
> 锁定统计信息目前为实验特性,不建议在生产环境中使用。

## 语法图

```ebnf+diagram
Expand Down
4 changes: 0 additions & 4 deletions sql-statements/sql-statement-unlock-stats.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,6 @@ summary: TiDB 数据库中 UNLOCK STATS 的使用概况。

`UNLOCK STATS` 语句用于解锁统计信息被锁定的表。

> **警告:**
>
> 锁定统计信息目前为实验特性,不建议在生产环境中使用。

## 语法图

```ebnf+diagram
Expand Down
4 changes: 0 additions & 4 deletions statistics.md
Original file line number Diff line number Diff line change
Expand Up @@ -743,10 +743,6 @@ LOAD STATS 'file_name';

## 锁定统计信息

> **警告:**
>
> 锁定统计信息目前为实验特性,不建议在生产环境中使用。

从 v6.5.0 开始,TiDB 引入了锁定统计信息的特性。当一张表或一个分区的统计信息被锁定以后,该表或分区的统计信息将无法被修改,也无法对该表进行 `ANALYZE` 操作。用例如下:

创建表 `t`,插入一些数据,在未锁定表 `t` 的统计信息的情况下成功执行 `ANALYZE` 语句。
Expand Down
Loading