From 599d83cbdfaaa4a27e197f2ed03f5ff00d0c3e80 Mon Sep 17 00:00:00 2001 From: Vincent Woo Date: Fri, 20 Mar 2026 13:14:38 +0800 Subject: [PATCH] [FLINK-39275][docs] Fix some issues in the "Performance Tuning" document --- docs/content.zh/docs/dev/table/tuning.md | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/docs/content.zh/docs/dev/table/tuning.md b/docs/content.zh/docs/dev/table/tuning.md index 6b75716d8e6d9..7e0649ee04b3b 100644 --- a/docs/content.zh/docs/dev/table/tuning.md +++ b/docs/content.zh/docs/dev/table/tuning.md @@ -1,5 +1,4 @@ --- -title: "Performance Tuning" title: "性能调优" weight: 11 type: docs @@ -25,14 +24,14 @@ specific language governing permissions and limitations under the License. --> -# Performance Tuning +# 性能调优 SQL 是数据分析中使用最广泛的语言。Flink Table API 和 SQL 使用户能够以更少的时间和精力定义高效的流分析应用程序。此外,Flink Table API 和 SQL 是高效优化过的,它集成了许多查询优化和算子优化。但并不是所有的优化都是默认开启的,因此对于某些工作负载,可以通过打开某些选项来提高性能。 在这一页,我们将介绍一些实用的优化选项以及流式聚合和普通连接的内部原理,它们在某些情况下能带来很大的提升。 {{< hint info >}} -目前 [分组聚合] ({{< ref "docs/sql/reference/queries/group-agg" >}}) 和 [窗口表值函数聚合]({{< ref "docs/sql/reference/queries/window-agg" >}}) (会话窗口表值函数聚合除外)都支持本页提到的流式聚合优化。 +目前 [分组聚合]({{< ref "docs/sql/reference/queries/group-agg" >}}) 和 [窗口表值函数聚合]({{< ref "docs/sql/reference/queries/window-agg" >}}) (会话窗口表值函数聚合除外)都支持本页提到的流式聚合优化。 {{< /hint >}} @@ -49,8 +48,8 @@ MiniBatch 聚合的核心思想是将一组输入的数据缓存在聚合算子 默认情况下,对于无界聚合算子来说,mini-batch 优化是被禁用的。开启这项优化,需要设置选项 `table.exec.mini-batch.enabled`、`table.exec.mini-batch.allow-latency` 和 `table.exec.mini-batch.size`。更多详细信息请参见[配置]({{< ref "docs/dev/table/config" >}}#execution-options)页面。 {{< hint info >}} -MiniBatch optimization is always enabled for [Window TVF Aggregation]({{< ref "docs/sql/reference/queries/window-agg" >}}), regardless of the above configuration. -Window TVF aggregation buffer records in [managed memory]({{< ref "docs/deployment/memory/mem_setup_tm">}}#managed-memory) instead of JVM Heap, so there is no risk of overloading GC or OOM issues. +MiniBatch 优化对于 [Window TVF 聚合]({{< ref "docs/sql/reference/queries/window-agg" >}})始终启用,不受上述配置影响。 +Window TVF 聚合将记录缓冲在[托管内存]({{< ref "docs/deployment/memory/mem_setup_tm">}}#managed-memory)中,而非 JVM 堆内存,因此不存在 GC 过载或 OOM 的风险。 {{< /hint >}} 下面的例子显示如何启用这些选项。