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

infosync: integrate PD HTTP client into the placement manager #48858

Merged
merged 2 commits into from
Nov 27, 2023

Conversation

JmPotato
Copy link
Member

What problem does this PR solve?

Issue Number: ref #35319, tikv/pd#7300

Problem Summary:

Integrate PD HTTP client into the placement manager.

What is changed and how it works?

  • Replace the etcd client inside PlacementManager with PD HTTP client.
  • Reuse the type definitions within the PD SDK as much as possible.

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)

Release note

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

None

@ti-chi-bot ti-chi-bot bot added release-note-none Denotes a PR that doesn't merit a release note. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Nov 23, 2023
Signed-off-by: JmPotato <ghzpotato@gmail.com>
Copy link

codecov bot commented Nov 23, 2023

Codecov Report

Merging #48858 (cf1b5cd) into master (7e8de2f) will decrease coverage by 17.5426%.
Report is 31 commits behind head on master.
The diff coverage is 81.3084%.

Additional details and impacted files
@@                Coverage Diff                @@
##             master     #48858         +/-   ##
=================================================
- Coverage   71.0184%   53.4758%   -17.5426%     
=================================================
  Files          1366       1585        +219     
  Lines        404637     596869     +192232     
=================================================
+ Hits         287367     319181      +31814     
- Misses        97283     255200     +157917     
- Partials      19987      22488       +2501     
Flag Coverage Δ
integration 35.0596% <34.5794%> (?)
unit 70.9673% <81.3084%> (-0.0511%) ⬇️

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

Components Coverage Δ
dumpling 53.9663% <ø> (ø)
parser ∅ <ø> (∅)
br 55.3744% <100.0000%> (+2.3874%) ⬆️

Comment on lines -306 to -316
// Clone is used to duplicate a RuleOp for safe modification.
// Note that it is a shallow copy: Constraints is not cloned.
func (r *Rule) Clone() *Rule {
n := &Rule{}
*n = *r
return n
}

func (r *Rule) String() string {
return fmt.Sprintf("%+v", *r)
}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ti-chi-bot ti-chi-bot bot added the needs-1-more-lgtm Indicates a PR needs 1 more LGTM. label Nov 27, 2023
@JmPotato
Copy link
Member 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 Nov 27, 2023
Copy link
Contributor

@zimulala zimulala left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ti-chi-bot ti-chi-bot bot added approved lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Nov 27, 2023
Copy link

ti-chi-bot bot commented Nov 27, 2023

[LGTM Timeline notifier]

Timeline:

  • 2023-11-27 06:12:12.480260458 +0000 UTC m=+816761.145486653: ☑️ agreed by hawkingrei.
  • 2023-11-27 06:55:50.424225835 +0000 UTC m=+819379.089452029: ☑️ agreed by zimulala.

Signed-off-by: JmPotato <ghzpotato@gmail.com>
Copy link

ti-chi-bot bot commented Nov 27, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hawkingrei, YuJuncen, zimulala

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 the approved label Nov 27, 2023
@JmPotato
Copy link
Member Author

/retest-required

@JmPotato
Copy link
Member 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 Nov 27, 2023
@ti-chi-bot ti-chi-bot bot merged commit c82e19c into pingcap:master Nov 27, 2023
20 checks passed
@JmPotato JmPotato deleted the adpot_client_to_info_syncer branch November 27, 2023 09:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm release-note-none Denotes a PR that doesn't merit a release note. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants