Skip to content

Commit 88d32a0

Browse files
committed
[FLINK-37150][doc] Update flink configuration file documentation.
1 parent 15f54ba commit 88d32a0

File tree

2 files changed

+2
-14
lines changed

2 files changed

+2
-14
lines changed

docs/content.zh/docs/deployment/config.md

+1-7
Original file line numberDiff line numberDiff line change
@@ -39,16 +39,12 @@ On session clusters, the provided configuration will only be used for configurin
3939

4040
# Flink 配置文件
4141

42-
自 Flink-1.19 版本起,Flink 正式引入了对标准 YAML 1.2 语法的完整支持。与之前版本中仅支持简单键值对的配置方式相比,这一更新为用户提供了更加灵活和强大的配置能力。为了利用这一新特性,用户需使用新引入的配置文件 `config.yaml`原有的 `flink-conf.yaml` 配置文件不再推荐使用,并在即将到来的 Flink-2.0 版本中不再支持。为了确保平滑迁移,建议用户尽早将现有作业配置迁移到新的配置方式
42+
自 Flink-2.0 版本起,Flink 仅支持使用支持标准 YAML 1.2 语法的配置文件 `config.yaml`原有的 `flink-conf.yaml` 配置文件将不再支持。与之前版本中仅支持简单键值对的配置方式相比,这一更新为用户提供了更加灵活和强大的配置能力
4343

4444
本节将帮助用户理解如何通过 `config.yaml` 配置文件对 Flink 集群和作业进行配置,以及如何将老配置迁移至新的配置文件中。
4545

4646
### 用法
4747

48-
从 Flink-1.19 版本开始,默认的配置文件已更改为 `config.yaml`,并置于 `conf/` 目录下。用户在进行配置时应直接修改此文件。
49-
50-
如果用户希望继续使用 Flink-1.19 之前的配置文件 `flink-conf.yaml`,只需将该文件拷贝到 `conf/` 目录下。一旦检测到 `flink-conf.yaml` 文件,Flink 会优先使用其作为配置文件。
51-
5248
`config.yaml` 的配置方式如下:
5349

5450
#### Config Key
@@ -119,8 +115,6 @@ bin/migrate-config-file.sh
119115
````
120116
运行上述指令后,该迁移脚本会自动读取 `conf/` 目录下的旧配置文件 `flink-conf.yaml`,并将迁移后的结果输出到 `conf/` 目录下的新配置文件 `config.yaml` 中。需要注意的是,因为老配置项解析器的限制,`flink-conf.yaml` 中所有的 value 会被识别为 `String` 类型,所以生成的 `config.yaml` 文件中的 value 也都为 `String` 类型,即部分 value 会被引号引起来。不过 Flink 会在后续的配置解析时将其转换为使用 `ConfigOption` 定义的实际类型。
121117

122-
此外,用户需要在迁移完成后删除 `conf/` 目录下的 `flink-conf.yaml` 文件来使 `config.yaml` 文件生效。
123-
124118
# Basic Setup
125119

126120
The default configuration supports starting a single-node Flink session cluster without any changes.

docs/content/docs/deployment/config.md

+1-7
Original file line numberDiff line numberDiff line change
@@ -39,16 +39,12 @@ On session clusters, the provided configuration will only be used for configurin
3939

4040
# Flink Configuration File
4141

42-
Starting with version 1.19, Flink has officially introduced full support for the standard YAML 1.2 syntax. Compared to the previous versions which only supported simple key-value pairs, this update provides users with more flexible and powerful configuration capabilities. To take advantage of this new feature, users need to use the newly introduced `config.yaml` configuration file. The existing `flink-conf.yaml` configuration file is deprecated and will no longer work in the upcoming version 2.0. To ensure a smooth transition, users are advised to migrate their existing Flink configuration to the new configuration file as soon as possible.
42+
Starting with Flink version 2.0, Flink only supports the configuration file `config.yaml`, which adheres to the standard YAML 1.2 syntax. The previous `flink-conf.yaml` configuration file is no longer supported. Compared to the previous versions which only supported simple key-value pairs, this update provides users with more flexible and powerful configuration capabilities.
4343

4444
This section will help users understand how to configure the Flink cluster and jobs through the `config.yaml` configuration file, as well as how to migrate old configuration to the new configuration file.
4545

4646
### Usage
4747

48-
Starting from Flink-1.19, the default configuration file has been changed to `config.yaml` and placed in the `conf/` directory. Users should directly modify this file to configure Flink.
49-
50-
To continue using the legacy configuration file `flink-conf.yaml`, users just need to copy this file into the `conf/` directory. Once the legacy configuration file `flink-conf.yaml` is detected, Flink will prioritize using it as the configuration file.
51-
5248
The usage for `config.yaml` is as follows:
5349

5450
#### Config Key
@@ -119,8 +115,6 @@ bin/migrate-config-file.sh
119115
````
120116
After running the command above, the migration script will automatically read the old configuration file `flink-conf.yaml` from the `conf/` directory and output the migrated results to the new configuration file `config.yaml` in the `conf/` directory. Note that due to the limitation of the legacy configuration parser, all values in flink-conf.yaml will be recognized as String type, so the values in the generated config.yaml file will also be of String type, which means some values will be enclosed in quotes. However, Flink will convert them to the actual types defined using `ConfigOption` during subsequent configuration parsing.
121117

122-
Additionally, users need to delete the `flink-conf.yaml` file in the `conf/` directory after migration to make the `config.yaml` file take effect.
123-
124118
# Basic Setup
125119

126120
The default configuration supports starting a single-node Flink session cluster without any changes.

0 commit comments

Comments
 (0)