Skip to content

Commit

Permalink
align chinese
Browse files Browse the repository at this point in the history
  • Loading branch information
ran-huang committed Oct 13, 2023
1 parent fefa2f2 commit 243abe1
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 9 deletions.
Binary file added media/ticdc/ticdc-changefeed-state-transfer.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed media/ticdc/ticdc-state-transfer.png
Binary file not shown.
22 changes: 13 additions & 9 deletions ticdc/ticdc-changefeed-overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,26 +11,30 @@ A changefeed is a replication task in TiCDC, which replicates the data change lo

The state of a replication task represents the running status of the replication task. During the running of TiCDC, replication tasks might fail with errors, be manually paused, resumed, or reach the specified `TargetTs`. These behaviors can lead to the change of the replication task state. This section describes the states of TiCDC replication tasks and the transfer relationships between states.

![TiCDC state transfer](/media/ticdc/ticdc-state-transfer.png)
![TiCDC state transfer](/media/ticdc/ticdc-changefeed-state-transfer.png)

The states in the preceding state transfer diagram are described as follows:

- `Normal`: The replication task runs normally and the checkpoint-ts proceeds normally.
- `Stopped`: The replication task is stopped, because the user manually pauses the changefeed. The changefeed in this state blocks GC operations.
- `Error`: The replication task returns an error. The replication cannot continue due to some recoverable errors. The changefeed in this state keeps trying to resume until the state transfers to `Normal`. The changefeed in this state blocks GC operations.
- `Warning`: The replication task returns an error. The replication cannot continue due to some recoverable errors. The changefeed in this state keeps trying to resume until the state transfers to `Normal`. The maximum retry time is 30 minutes. If it exceeds this time, the changefeed enters a failed state. The changefeed in this state blocks GC operations.
- `Finished`: The replication task is finished and has reached the preset `TargetTs`. The changefeed in this state does not block GC operations.
- `Failed`: The replication task fails. Due to some unrecoverable errors, the replication task cannot resume and cannot be recovered. TiCDC retains the data associated with the failed changefeed for 24 hours, preventing it from being garbage collected.
- `Failed`: The replication task fails. Due to some unrecoverable errors, the replication task cannot resume and cannot be recovered. To give you enough time to handle the failure, the changefeed in this state blocks GC progress. The duration of the blockage is specified by the `gc-ttl` parameter, with a default value of 24 hours.

> **Note:**
>
> If the changefeed encounters errors with error codes `ErrGCTTLExceeded`, `ErrSnapshotLostByGC`, or `ErrStartTsBeforeGC`, it does not block GC progress.
The numbers in the preceding state transfer diagram are described as follows.

- ① Run the `changefeed pause` command.
- ② Run the `changefeed resume` command to resume the replication task.
- ③ Recoverable errors occur during the `changefeed` operation, and the operation is resumed automatically.
-Run the `changefeed resume` command to resume the replication task.
-Unrecoverable errors occur during the `changefeed` operation.
-`changefeed` has reached the preset `TargetTs`, and the replication is automatically stopped.
-`changefeed` suspended longer than the duration specified by `gc-ttl`, and cannot be resumed.
-`changefeed` experienced an unrecoverable error when trying to execute automatic recovery.
- ③ Recoverable errors occur during the `changefeed` operation, and the operation is retried automatically.
-The changefeed automatic retry succeeds, and `checkpoint-ts` continues to advance.
-The changefeed automatic retry exceeds 30 minutes and fails. The changefeed enters the failed state. At this time, the changefeed continues to block upstream GC for a duration specified by `gc-ttl`.
-The changefeed encounters an unrecoverable error and directly enters the failed state. At this time, the changefeed continues to block upstream GC for a duration specified by `gc-ttl`.
-The replication progress of the changefeed reaches the value set by `target-ts`, and the replication is completed.
-The changefeed has been stalled for a duration longer than the value specified by `gc-ttl`, encounters GC advancement errors, and cannot be recovered.

## Operate changefeeds

Expand Down

0 comments on commit 243abe1

Please sign in to comment.