mirror of
https://github.com/YGGverse/aquatic.git
synced 2026-03-31 17:55:36 +00:00
aquatic ws load test: remove unused stats
This commit is contained in:
parent
b0d2f67ab6
commit
d44d513879
2 changed files with 1 additions and 20 deletions
|
|
@ -22,9 +22,6 @@ pub struct Statistics {
|
|||
pub responses_offer: AtomicUsize,
|
||||
pub responses_answer: AtomicUsize,
|
||||
pub responses_scrape: AtomicUsize,
|
||||
pub responses_failure: AtomicUsize,
|
||||
pub bytes_sent: AtomicUsize,
|
||||
pub bytes_received: AtomicUsize,
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -19,10 +19,6 @@ use network::*;
|
|||
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
|
||||
|
||||
|
||||
/// Multiply bytes during a second with this to get Mbit/s
|
||||
const MBITS_FACTOR: f64 = 1.0 / ((1024.0 * 1024.0) / 8.0);
|
||||
|
||||
|
||||
pub fn main(){
|
||||
aquatic_cli_helpers::run_app_with_cli_and_config::<Config>(
|
||||
"aquatic: udp bittorrent tracker: load tester",
|
||||
|
|
@ -108,13 +104,6 @@ fn monitor_statistics(
|
|||
.fetch_and(0, Ordering::SeqCst) as f64 / interval_f64;
|
||||
let responses_scrape_per_second = statistics.responses_scrape
|
||||
.fetch_and(0, Ordering::SeqCst) as f64 / interval_f64;
|
||||
let responses_failure_per_second = statistics.responses_failure
|
||||
.fetch_and(0, Ordering::SeqCst) as f64 / interval_f64;
|
||||
|
||||
let bytes_sent_per_second = statistics.bytes_sent
|
||||
.fetch_and(0, Ordering::SeqCst) as f64 / interval_f64;
|
||||
let bytes_received_per_second = statistics.bytes_received
|
||||
.fetch_and(0, Ordering::SeqCst) as f64 / interval_f64;
|
||||
|
||||
let responses_announce_per_second = responses_announce / interval_f64;
|
||||
|
||||
|
|
@ -122,8 +111,7 @@ fn monitor_statistics(
|
|||
responses_announce_per_second +
|
||||
responses_offer_per_second +
|
||||
responses_answer_per_second +
|
||||
responses_scrape_per_second +
|
||||
responses_failure_per_second;
|
||||
responses_scrape_per_second;
|
||||
|
||||
report_avg_response_vec.push(responses_per_second);
|
||||
|
||||
|
|
@ -134,10 +122,6 @@ fn monitor_statistics(
|
|||
println!(" - Offer responses: {:.2}", responses_offer_per_second);
|
||||
println!(" - Answer responses: {:.2}", responses_answer_per_second);
|
||||
println!(" - Scrape responses: {:.2}", responses_scrape_per_second);
|
||||
// println!(" - Failure responses: {:.2}", responses_failure_per_second);
|
||||
// println!("Peers per announce response: {:.2}", response_peers / responses_announce);
|
||||
// println!("Bandwidth out: {:.2}Mbit/s", bytes_sent_per_second * MBITS_FACTOR);
|
||||
// println!("Bandwidth in: {:.2}Mbit/s", bytes_received_per_second * MBITS_FACTOR);
|
||||
|
||||
let time_elapsed = start_time.elapsed();
|
||||
let duration = Duration::from_secs(config.duration as u64);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue