apache / apache/paimon

[Feature] add some extra core table conf params under the CDC Ingestion with whole db synchronize mode

Open
#1,441 9 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Java
Stars
3.4k
Forks
1.4k
Avg merge
1d 11h
Merged PRs (30d)
396

Description

### Search before asking

- [X] I searched in the [issues](https://github.com/apache/incubator-paimon/issues) and found nothing similar.

### Motivation

Due to difference data rows range between tables in a MySQL database, we hope to **customize some table parameters** (such as bucket, sink parallelism, etc) during the synchronization of the entire CDC database .

as below:
orginal code :
/bin/flink run \
/path/to/paimon-flink-action-0.5-SNAPSHOT.jar \
mysql-sync-database \
--warehouse hdfs:///path/to/warehouse \
--database test_db \
--mysql-conf hostname=127.0.0.1 \
--mysql-conf username=root \
--mysql-conf password=123456 \
--mysql-conf database-name=source_db \
--catalog-conf metastore=hive \
--catalog-conf uri=thrift://hive-metastore:9083 \
--table-conf bucket=1 \
--table-conf changelog-producer=input \
--table-conf sink.parallelism=1 \
--including-tables 'product|user|address|order'

**add some extral table conf params like "--including-tables-buckets" and “--including-tables-sink.parallelism” :**
/bin/flink run \
/path/to/paimon-flink-action-0.5-SNAPSHOT.jar \
mysql-sync-database \
--warehouse hdfs:///path/to/warehouse \
--database test_db \
--mysql-conf hostname=127.0.0.1 \
--mysql-conf username=root \
--mysql-conf password=123456 \
--mysql-conf database-name=source_db \
--catalog-conf metastore=hive \
--catalog-conf uri=thrift://hive-metastore:9083 \
--table-conf bucket=1 \
--table-conf changelog-producer=input \
--table-conf sink.parallelism=1 \
--including-tables 'product|user|address|order' \
**--including-tables-buckets 'user:2|order:3'** \
**--including-tables-sink.parallelism 'order:3'**

### Solution

_No response_

### Anything else?

_No response_

### Are you willing to submit a PR?

- [ ] I'm willing to submit a PR!

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by locating the mysql-sync-database entry point and the existing handling for --including-tables and --table-conf. Trace how table settings are applied during whole-database CDC synchronization, then define how the requested per-table bucket and sink.parallelism parameters should be parsed and applied. Done means the example mappings work without changing the defaults for other tables.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, mysql
Domain
data-engineering, databases, stream-processing
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.