pingcap / tidb

TiDB is an open-source, cloud-native, distributed, MySQL-Compatible database for elastic scale and real-time analytics. Try AI-powered Chat2Query free at : https://tidbcloud.com/free-trial
https://pingcap.com
Apache License 2.0
36.27k stars 5.72k forks source link

br/pdutils: retry when encountered dns error #53005

Closed YuJuncen closed 1 week ago

YuJuncen commented 2 weeks ago

What problem does this PR solve?

Issue Number: close #53029

Problem Summary: In a tidb-operator deployed cluster, sometimes coredns responses No such host which will abort the creation of PDController. We should retry this sort of error.

What changed and how does it work?

This PR added retry when the net.Error is DNSError. Also, this PR increases the retry time limit from 10 times (totally 10s) to 120 times (totally 120s).

Check List

Tests

Side effects

Documentation

Release note

Please refer to Release Notes Language Style Guide to write a quality release note.

None
tiprow[bot] commented 2 weeks ago

Hi @YuJuncen. Thanks for your PR.

PRs from untrusted users cannot be marked as trusted with /ok-to-test in this repo meaning untrusted PR authors can never trigger tests themselves. Collaborators can still trigger tests on the PR using /test all.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.
codecov[bot] commented 2 weeks ago

Codecov Report

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

:exclamation: No coverage uploaded for pull request base (release-6.5@727a2c7). Click here to learn what that means.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## release-6.5 #53005 +/- ## ================================================ Coverage ? 73.6561% ================================================ Files ? 1096 Lines ? 351631 Branches ? 0 ================================================ Hits ? 258998 Misses ? 76005 Partials ? 16628 ```
ti-chi-bot[bot] commented 1 week ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: BornChanger, Leavrth

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: - ~~[OWNERS](https://github.com/pingcap/tidb/blob/release-6.5/OWNERS)~~ [Leavrth] 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[bot] commented 1 week ago

[LGTM Timeline notifier]

Timeline: