15 lines
711 B
Markdown
15 lines
711 B
Markdown
# dashboard-cdc-worker
|
||
|
||
独立的国家大屏 CDC Worker,用 MySQL ROW binlog 读取业务事件,增量写入 `country_dashboard_*` 预聚合表,并可选写 Redis 今日实时 Hash。
|
||
|
||
## 关键约束
|
||
|
||
- 单独部署为 `dashboard-cdc-worker` 容器,不复用主 Go 服务。
|
||
- 默认 `CDC_DRY_RUN=true`,上线验证链路时先只读 binlog 不写聚合表。
|
||
- 只监听当前 Java 大屏口径依赖的表,避免扫源表。
|
||
- MySQL 必须开启 `log_bin=ON`、`binlog_format=ROW`、`binlog_row_image=FULL`。
|
||
|
||
## 部署
|
||
|
||
镜像由 `ci/build-image.sh <image> <version>` 构建。hy-app-monitor 会读取本仓库、构建镜像、更新 app-2 compose,并滚动重启 `dashboard-cdc-worker`。
|