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

change default bench-tps client to tpu-client #35335

Merged
merged 4 commits into from
Feb 28, 2024

Conversation

gregcusack
Copy link
Contributor

Problem

It is time to deprecate and then remove ThinClient from bench-tps. This is the first PR to simply just change the default bench-tps client from ThinClient to TpuClient

Summary of Changes

Change ThinClient to TpuClient, add flag for running thin-client explicitly (will be removed in future), and update net.sh scripts to reflect the change.

Fixes #

Comment on lines 324 to 328
Arg::with_name("tpu_client")
.long("use-tpu-client")
Arg::with_name("thin_client")
.long("use-thin-client")
.conflicts_with("rpc_client")
.takes_value(false)
.help("Submit transactions with a TpuClient")
Copy link
Contributor

Choose a reason for hiding this comment

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

We should preserve the --use-tpu-client flag (and the various conflicts_with logic), even though it duplicates the (new) default behavior, to avoid breaking downstream users.

Comment on lines 324 to 328
Arg::with_name("thin_client")
.long("use-thin-client")
.conflicts_with("rpc_client")
.takes_value(false)
.help("Submit transactions with a TpuClient")
.help("Submit transactions with a ThinClient")
Copy link
Contributor

Choose a reason for hiding this comment

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

Actually, if we're going to remove this imminently, I think we should avoid exposing a flag for it in the first place.
If there is an internal need to keep it for a bit (eg /net scripts), let's mark this as .hidden(hidden_unless_forced()) so it's not visible. If there's no need for it, let's just remove this Arg.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ya if we remove it here we'd have to remove all references to ThinClient in /net scripts in this PR as well. So maybe as you said, let's use: .hidden(hidden_unless_forced()) for now. And then for the PR where we will deprecate ThinClient, we can fully remove this flag and remove all references to ThinClient in /net. does that work?

Copy link
Contributor

Choose a reason for hiding this comment

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

Yes, that works for me.

Copy link

codecov bot commented Feb 27, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 81.7%. Comparing base (8ad125d) to head (5d641ce).
Report is 10 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master   #35335   +/-   ##
=======================================
  Coverage    81.7%    81.7%           
=======================================
  Files         834      834           
  Lines      224235   224235           
=======================================
+ Hits       183390   183391    +1     
+ Misses      40845    40844    -1     

Copy link
Contributor

@CriesofCarrots CriesofCarrots left a comment

Choose a reason for hiding this comment

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

r+ one last little nit

bench-tps/src/cli.rs Outdated Show resolved Hide resolved
.conflicts_with("tpu_client")
.takes_value(false)
.hidden(hidden_unless_forced())
.help("Submit transactions with a ThinClient")
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe add a note here that usage of ThinClient is discouraged and that ThinClient will be deprecated?

Copy link
Contributor

@apfitzge apfitzge left a comment

Choose a reason for hiding this comment

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

lgtm - gave it a quick test to make sure perf (for my single node use case) was unaffected.

@gregcusack gregcusack merged commit 98ec72e into solana-labs:master Feb 28, 2024
36 checks passed
@gregcusack gregcusack deleted the remove-thin-client branch February 28, 2024 20:30
@gregcusack gregcusack restored the remove-thin-client branch February 28, 2024 20:32
@gregcusack gregcusack deleted the remove-thin-client branch February 29, 2024 20:10
gregcusack added a commit to gregcusack/solana that referenced this pull request Feb 29, 2024
* change default bench-tps client to tpu-client

* remote client default to tpu-client

* add --use-tpu-client back in. hide --use-thin-client

* address nit, inform of future thinclient deprecation
gregcusack added a commit to gregcusack/solana that referenced this pull request Mar 13, 2024
* change default bench-tps client to tpu-client

* remote client default to tpu-client

* add --use-tpu-client back in. hide --use-thin-client

* address nit, inform of future thinclient deprecation
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants