Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pdClient (ticdc): Enable the pdClient forwarding function to make cdc more stable during network isolation between the PD leader #11076

Merged
merged 7 commits into from
May 13, 2024

Conversation

asddongmen
Copy link
Contributor

@asddongmen asddongmen commented May 11, 2024

What problem does this PR solve?

Issue Number: close #10849

What is changed and how it works?

Enable pdClient's forwarding function, make it can forward request to PD follower if cdc is network isolated with PD Leader.

Enabling forwarding will introduce additional network round trips between the PD follower and PD leader. However, since TiCDC doesn't call the PD API frequently, it won't affect TiCDC's performance.

So we decide to enable it by default.

Check List

Tests

  • Manual test (add detailed scripts or steps below)

This PR has been tested multiple times in the HA case [ha-ticdc-non-owner-random-to-pdleader-network-partition-last-for-10m]. The results indicate that it functions as expected:
image

The changefeed's lag is not affected by the network partition between CDC and the PD leader anymore.
image

Questions

Will it cause performance regression or break compatibility?
Do you need to update user documentation, design documentation or monitoring documentation?

Release note

Enable the pdClient forwarding function to make cdc more stable during network isolation between the PD leader.

Copy link
Contributor

ti-chi-bot bot commented May 11, 2024

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@ti-chi-bot ti-chi-bot bot added do-not-merge/needs-linked-issue do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. release-note Denotes a PR that will be considered when it comes time to generate release notes. affect-ticdc-config-docs Pull requests that affect TiCDC configuration docs. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels May 11, 2024
@asddongmen asddongmen changed the title pdClient (ticdc): enable pdClient forwarding to make it more resilient pdClient (ticdc): Enable the pdClient forwarding function to make cdc more stable during network isolation between the PD leader May 13, 2024
@asddongmen asddongmen marked this pull request as ready for review May 13, 2024 06:22
@ti-chi-bot ti-chi-bot bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label May 13, 2024
@asddongmen asddongmen self-assigned this May 13, 2024
@asddongmen asddongmen added needs-cherry-pick-release-7.5 Should cherry pick this PR to release-7.5 branch. needs-cherry-pick-release-8.1 Should cherry pick this PR to release-8.1 branch. labels May 13, 2024
@asddongmen asddongmen marked this pull request as draft May 13, 2024 06:23
@ti-chi-bot ti-chi-bot bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label May 13, 2024
@ti-chi-bot ti-chi-bot bot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels May 13, 2024
@asddongmen asddongmen marked this pull request as ready for review May 13, 2024 06:26
@ti-chi-bot ti-chi-bot bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label May 13, 2024
@ti-chi-bot ti-chi-bot bot added needs-1-more-lgtm Indicates a PR needs 1 more LGTM. approved labels May 13, 2024
Copy link
Contributor

ti-chi-bot bot commented May 13, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: CharlesCheung96, sdojjy

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ti-chi-bot ti-chi-bot bot added lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels May 13, 2024
Copy link
Contributor

ti-chi-bot bot commented May 13, 2024

[LGTM Timeline notifier]

Timeline:

  • 2024-05-13 06:41:41.896796992 +0000 UTC m=+1462655.653932565: ☑️ agreed by sdojjy.
  • 2024-05-13 06:50:23.711830914 +0000 UTC m=+1463177.468966488: ☑️ agreed by CharlesCheung96.

Signed-off-by: dongmen <414110582@qq.com>
@asddongmen
Copy link
Contributor Author

/hold

@ti-chi-bot ti-chi-bot bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label May 13, 2024
Signed-off-by: dongmen <414110582@qq.com>
@asddongmen
Copy link
Contributor Author

/test all

Copy link

codecov bot commented May 13, 2024

Codecov Report

Attention: Patch coverage is 0% with 9 lines in your changes are missing coverage. Please review.

Project coverage is 57.5924%. Comparing base (0332357) to head (b508919).
Report is 3 commits behind head on master.

Additional details and impacted files
Components Coverage Δ
cdc 62.0251% <0.0000%> (+0.3686%) ⬆️
dm 51.2593% <ø> (+0.0293%) ⬆️
engine 63.4020% <ø> (+0.0141%) ⬆️
Flag Coverage Δ
unit 57.5924% <0.0000%> (+0.1998%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

@@               Coverage Diff                @@
##             master     #11076        +/-   ##
================================================
+ Coverage   57.3926%   57.5924%   +0.1998%     
================================================
  Files           851        851                
  Lines        125612     125855       +243     
================================================
+ Hits          72092      72483       +391     
+ Misses        48108      47990       -118     
+ Partials       5412       5382        -30     

@asddongmen
Copy link
Contributor Author

/unhold

@ti-chi-bot ti-chi-bot bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label May 13, 2024
@asddongmen
Copy link
Contributor Author

/retest

@asddongmen asddongmen removed the affect-ticdc-config-docs Pull requests that affect TiCDC configuration docs. label May 13, 2024
@asddongmen
Copy link
Contributor Author

/retest

2 similar comments
@asddongmen
Copy link
Contributor Author

/retest

@asddongmen
Copy link
Contributor Author

/retest

@ti-chi-bot ti-chi-bot bot merged commit 3bfba30 into pingcap:master May 13, 2024
28 checks passed
@ti-chi-bot
Copy link
Member

In response to a cherrypick label: new pull request created to branch release-7.5: #11084.

@ti-chi-bot
Copy link
Member

In response to a cherrypick label: new pull request created to branch release-8.1: #11086.

ti-chi-bot bot pushed a commit that referenced this pull request May 14, 2024
… more stable during network isolation between the PD leader (#11076) (#11086)

close #10849
ti-chi-bot bot pushed a commit that referenced this pull request May 21, 2024
… more stable during network isolation between the PD leader (#11076) (#11084)

close #10849
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm needs-cherry-pick-release-7.5 Should cherry pick this PR to release-7.5 branch. needs-cherry-pick-release-8.1 Should cherry pick this PR to release-8.1 branch. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

changefeed lag reached 556s when inject network partition between one of ticdc and pd leader last for 10mins
4 participants