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

Display max TPS from all nodes at end of client demo #716

Merged
merged 1 commit into from
Jul 20, 2018

Conversation

pgarg66
Copy link
Contributor

@pgarg66 pgarg66 commented Jul 19, 2018

  • Also lists node with 0 TPS and overall average TPS

- Also lists node with 0 TPS and overall average TPS
let mut total_maxes = 0.0;
for (max, txs, sock) in maxes.read().unwrap().iter() {
println!("Node:{}, Max TPS: {:.2}", *sock, *max);
if *max == 0.0 {
Copy link
Member

Choose a reason for hiding this comment

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

Use txs == 0 here? exact compare with float makes me cringe, although probably ok here.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'll change it to txs == 0

@@ -33,9 +33,14 @@ use std::thread::JoinHandle;
use std::time::Duration;
use std::time::Instant;

pub struct NodeStats {
pub tps: f64,
pub tx: u64,
Copy link
Member

Choose a reason for hiding this comment

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

can you please document these two fields? I can mostly guess what they mean but I'd rather not guess :)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done..

@pgarg66 pgarg66 merged commit 686e61d into solana-labs:master Jul 20, 2018
@pgarg66 pgarg66 deleted the client-demo-max-tps branch July 20, 2018 03:10
35359595 pushed a commit to 35359595/solana that referenced this pull request Apr 10, 2024
* default staked client in LocalCluster

* fix underflow
lijunwangs pushed a commit to lijunwangs/solana that referenced this pull request Apr 11, 2024
…#716) (solana-labs#723)

* default staked client in LocalCluster (solana-labs#716)

* default staked client in LocalCluster

* fix underflow

(cherry picked from commit e91a5e2)

# Conflicts:
#	local-cluster/tests/local_cluster.rs

* resolve conflicts

---------

Co-authored-by: Andrew Fitzgerald <apfitzge@gmail.com>
yihau pushed a commit that referenced this pull request Apr 11, 2024
* default staked client in LocalCluster (#716)

* default staked client in LocalCluster

* fix underflow

(cherry picked from commit e91a5e2)

# Conflicts:
#	local-cluster/tests/local_cluster.rs

* resolve conflicts

---------

Co-authored-by: Andrew Fitzgerald <apfitzge@gmail.com>
yihau pushed a commit that referenced this pull request Apr 11, 2024
* default staked client in LocalCluster (#716)

* default staked client in LocalCluster

* fix underflow

(cherry picked from commit e91a5e2)

# Conflicts:
#	local-cluster/tests/local_cluster.rs

* resolve conflicts

---------

Co-authored-by: Andrew Fitzgerald <apfitzge@gmail.com>
lijunwangs pushed a commit to lijunwangs/solana that referenced this pull request Apr 24, 2024
…#716) (solana-labs#724)

* default staked client in LocalCluster (solana-labs#716)

* default staked client in LocalCluster

* fix underflow

(cherry picked from commit e91a5e2)

# Conflicts:
#	local-cluster/tests/local_cluster.rs

* resolve conflicts

---------

Co-authored-by: Andrew Fitzgerald <apfitzge@gmail.com>
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.

3 participants