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

client: move WithCallerComponent from RPCClient to Client #8943

Merged
merged 3 commits into from
Dec 20, 2024

Conversation

okJiang
Copy link
Member

@okJiang okJiang commented Dec 20, 2024

What problem does this PR solve?

Issue Number: ref #8593

Callers always use Client to call grpc interface. To make it more convenient for the caller to make calls, we move WithCallerComponent from RPCClient to Client.

What is changed and how does it work?

Check List

Tests

  • No code

Release note

None.

@ti-chi-bot ti-chi-bot bot added release-note-none Denotes a PR that doesn't merit a release note. dco-signoff: yes Indicates the PR's author has signed the dco. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Dec 20, 2024
Copy link

codecov bot commented Dec 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 76.28%. Comparing base (0e5d49f) to head (f01f377).
Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #8943      +/-   ##
==========================================
- Coverage   76.31%   76.28%   -0.03%     
==========================================
  Files         462      462              
  Lines       70447    70447              
==========================================
- Hits        53763    53744      -19     
- Misses      13340    13357      +17     
- Partials     3344     3346       +2     
Flag Coverage Δ
unittests 76.28% <100.00%> (-0.03%) ⬇️

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

client/client.go Outdated
// The upperLayer parameter specifies the depth of the caller stack,
// where 0 means the current function. Adjust the upperLayer value based
// on your needs.
WithCallerComponent(callerComponent caller.Component) RPCClient
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
WithCallerComponent(callerComponent caller.Component) RPCClient
WithCallerComponent(callerComponent caller.Component) Client

Signed-off-by: okJiang <[email protected]>
@ti-chi-bot ti-chi-bot bot added needs-1-more-lgtm Indicates a PR needs 1 more LGTM. approved labels Dec 20, 2024
Copy link
Contributor

ti-chi-bot bot commented Dec 20, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: JmPotato, rleungx

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 Dec 20, 2024
Copy link
Contributor

ti-chi-bot bot commented Dec 20, 2024

[LGTM Timeline notifier]

Timeline:

  • 2024-12-20 04:11:03.233356526 +0000 UTC m=+1189253.322159069: ☑️ agreed by JmPotato.
  • 2024-12-20 05:18:32.622343807 +0000 UTC m=+1193302.711146349: ☑️ agreed by rleungx.

@ti-chi-bot ti-chi-bot bot merged commit 461b86a into tikv:master Dec 20, 2024
25 checks passed
@okJiang okJiang deleted the update-client-interface branch December 20, 2024 05:40
ti-chi-bot bot pushed a commit to tikv/client-go that referenced this pull request Dec 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved dco-signoff: yes Indicates the PR's author has signed the dco. lgtm release-note-none Denotes a PR that doesn't merit a release note. 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.

3 participants