TiDB Integration Task (Preview)
A TiDB integration task replicates data from a TiDB cluster into TiDB Cloud Lake. It supports full Snapshot loads from a Dumpling export, continuous Change Data Capture (CDC) from a TiCDC changefeed, or a combination of both.
If you need to create reusable staging bucket settings first, see TiDB Data Source.
Use Cases
- Migrate TiDB databases and tables into TiDB Cloud Lake for analytics
- Keep TiDB Cloud Lake continuously in sync with TiDB through TiCDC
- Consolidate sharded databases into per-source target databases in one task
- Run a full load once, or combine a full load with ongoing change capture
Sync Modes
Prerequisites
Before creating a TiDB integration task, make sure:
- A TiDB data source has already been created.
- The object storage bucket configured in the data source is reachable from TiDB Cloud Lake.
- The TiCDC / Dumpling export for the tables you want to sync has been written to the bucket under the prefixes you will reference in the task.
Creating a TiDB Integration Task
This section guides you through the steps to create a TiDB integration task in TiDB Cloud Lake.
Step 1: Configure Basic Settings
- Navigate to Data > Data Integration and click Create Task.
- Select a TiDB data source, then configure the basic settings:
Table Rules
Enter one rule per line. Each rule is schemaPattern.tablePattern, optionally prefixed with ! to exclude:
app.orders an exact table
shard_*.* every table of every shard_ database
!*.tmp_* exclude temporary tables
Rules are evaluated from last to first. The first rule whose database and table patterns both match decides the outcome. An object that matches no rule is excluded. A list containing only exclusions gets an implicit leading *.*.
Each matched source database is written to its own target database, so same-named tables in different source databases stay separate. This is the only way to sync more than one source database in a single task.
Click Preview Matched Tables to evaluate the current rules against the objects actually present under the prefix. The preview lists the matched source database and table together with the derived target database and table.
Snapshot Options
When the sync mode includes a snapshot, additional options control how the Dumpling export is loaded:
Target Name Affixes
Target database and table names are derived from the source names, with optional affixes:
target database = targetDatabasePrefix + sourceDatabase + targetDatabaseSuffix
target table = targetTablePrefix + sourceTable + targetTableSuffix
Leave the affixes empty to use the source names as-is. Affixes may contain only letters, digits, and underscores.
For example, with a database prefix of src_, source database shard_1 and table orders are written to src_shard_1.orders.
Step 2: Create the Task
Review the settings, then click Create to create the integration task.
Task Behavior by Sync Mode
For CDC tasks, progress is saved as a checkpoint. When the task is stopped and restarted, it resumes from the saved position instead of reloading from the beginning.
Advanced Configuration
The following settings are task-level parameters that tune discovery, loading, and merging.