Skip to content

Commit

Permalink
ticdc: Update cdc server config (#14992) (#15588)
Browse files Browse the repository at this point in the history
  • Loading branch information
ti-chi-bot committed Dec 1, 2023
1 parent a0af272 commit 7d95fba
Showing 1 changed file with 24 additions and 11 deletions.
35 changes: 24 additions & 11 deletions ticdc/ticdc-server-config.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,10 @@ summary: 了解 TiCDC 详细的命令行参数和配置文件定义。

## `cdc server` 配置文件说明

对于 `cdc server` 命令中 config 参数指定的配置文件说明如下:
对于 `cdc server` 命令中 `config` 参数指定的配置文件说明如下:

```yaml
```toml
# 下面的字段的配置含义与命令行参数相同,但是命令行参数优先级更高。
addr = "127.0.0.1:8300"
advertise-addr = ""
log-file = ""
Expand All @@ -45,23 +46,35 @@ cluster-id = "default"
cert-path = ""
key-path = ""


# TiCDC 与 etcd 服务间的 session 时长(单位为秒),默认为 10,可选。
capture-session-ttl = 10 # 10s
# TiCDC 集群中的 owner 模块尝试推进同步任务进度的周期,默认值为 `50000000` 纳秒(即 50 毫秒),可选。该参数有两种配置方式:只指定数字(例如,配置为 `40000000` 表示 40000000 纳秒,即 40 毫秒),或同时指定数字和单位(例如,直接配置为 `40ms`)。
owner-flush-interval = 50000000 # 50 ms
# TiCDC 集群中的 processor 模块尝试推进同步任务进度的周期,默认值为 `50000000` 纳秒(即 50 毫秒),可选。该参数配置方式与 `owner-flush-interval` 相同。
processor-flush-interval = 50000000 # 50 ms
per-table-memory-quota = 10485760 # 10 MiB

[log]
error-output = "stderr"
[log.file]
max-size = 300 # 300 MiB
max-days = 0
max-backups = 0
# [log]
# # 用于指定 zap log 模块内部的错误日志的输出位置。默认是 "stderr",可选。
# error-output = "stderr"
# [log.file]
# # 单个 log 文件的最大文件大小,单位为 MiB。默认值为 300,可选。
# max-size = 300 # 300 MiB
# # log 文件最长保留天数,默认值为 `0`,代表永不删除,可选。
# max-days = 0
# # log 文件的保留个数,默认值为 `0`,代表保留所有 log 文件,可选。
# max-backups = 0

# [sorter]
# Sorter 模块给默认启动的 8 个 pebble DB 共享的 pebble block cache 的大小,单位为 MiB,默认值为 128。
# cache-size-in-mb = 128
# Sorter 文件相对于 data-dir 的目录,默认值为 "/tmp/sorter",可选。
# sorter-dir = "/tmp/sorter"

# [kv-client]
# 单个 Region worker 中可使用的线程数量,默认为 8,可选。
# worker-concurrent = 8
# TiCDC 中共享线程池中线程的数量,主要用于处理 KV 事件,默认值为 `0`,表示默认为 CPU 核数的 2 倍,可选。
# worker-pool-size = 0
# region-scan-limit = 40
# Region 连接重试时间,默认值为 `60000000000` 纳秒(即 1 分钟),可选。该参数有两种配置方式:只指定数字(例如,配置为 `50000000` 表示 50000000 纳秒,即 50 毫秒),或同时指定数字和单位(例如,直接配置为 `50ms`)。
# region-retry-duration = 60000000000
```

0 comments on commit 7d95fba

Please sign in to comment.