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

refactor: build client without ServerId #412

Merged
merged 4 commits into from
Aug 11, 2023

Conversation

themanforfree
Copy link
Collaborator

Please briefly answer these questions:
#306

  • what problem are you trying to solve? (or if there's no problem, what's the motivation for this change?)
    build client without ServerId
  • what changes does this pull request make?
    add client builder
    add fetch_cluster rpc
    allows the client to build without ServerId, which automatically fetch the cluster information from the server
  • are there any non-obvious implications of these changes? (does it break compatibility with previous versions, etc)
    yes, Client::new is removed, use client builder instead

@xline-kv xline-kv deleted a comment from codecov bot Aug 7, 2023
@codecov
Copy link

codecov bot commented Aug 7, 2023

Codecov Report

Patch coverage: 23.78% and project coverage change: +0.04% 🎉

Comparison is base (5126802) 53.69% compared to head (bad4986) 53.73%.
Report is 3 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #412      +/-   ##
==========================================
+ Coverage   53.69%   53.73%   +0.04%     
==========================================
  Files         101      101              
  Lines       15913    16074     +161     
  Branches    15913    16074     +161     
==========================================
+ Hits         8545     8638      +93     
- Misses       6847     6912      +65     
- Partials      521      524       +3     
Files Changed Coverage Δ
benchmark/src/args.rs 0.00% <0.00%> (ø)
curp/src/rpc/mod.rs 25.12% <0.00%> (-1.83%) ⬇️
curp/src/server/curp_node.rs 23.94% <0.00%> (-0.52%) ⬇️
curp/src/server/mod.rs 0.00% <0.00%> (ø)
curp/src/server/raw_curp/mod.rs 65.86% <0.00%> (-0.86%) ⬇️
xline-client/src/clients/auth.rs 0.00% <ø> (ø)
xline-client/src/clients/kv.rs 0.00% <ø> (ø)
xline-client/src/clients/lease.rs 0.00% <ø> (ø)
xline-client/src/clients/lock.rs 0.00% <ø> (ø)
xline-client/src/clients/maintenance.rs 0.00% <ø> (ø)
... and 10 more

... and 6 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

curp/src/client.rs Outdated Show resolved Hide resolved
curp/src/client.rs Outdated Show resolved Hide resolved
curp/src/client.rs Outdated Show resolved Hide resolved
curp/src/client.rs Outdated Show resolved Hide resolved
@themanforfree themanforfree force-pushed the refactor/client branch 2 times, most recently from 4138d38 to 2915748 Compare August 8, 2023 01:24
add client builder
add `fetch_cluster` rpc
allows the client to build without `ServerId`, which automatically fetch the cluster information from the server

Signed-off-by: themanforfree <themanforfree@gmail.com>
Signed-off-by: themanforfree <themanforfree@gmail.com>
Signed-off-by: themanforfree <themanforfree@gmail.com>
curp/src/client.rs Outdated Show resolved Hide resolved
Signed-off-by: themanforfree <themanforfree@gmail.com>
@themanforfree themanforfree merged commit 61342f8 into xline-kv:master Aug 11, 2023
@themanforfree themanforfree deleted the refactor/client branch August 11, 2023 02:51
@Phoenix500526 Phoenix500526 added the Improvement Refactor or optimization, including process, performance or something like that label Nov 18, 2023
@Phoenix500526 Phoenix500526 added this to the v0.6.0 milestone Nov 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Improvement Refactor or optimization, including process, performance or something like that
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants