#cli #udp #client #traffic #generator

bin+lib udp_traffic_generator

A tool to generate UDP traffic

5 releases

0.1.4 Dec 21, 2022
0.1.3 Aug 6, 2022
0.1.2 Aug 4, 2022
0.1.1 Aug 1, 2022
0.1.0 Aug 1, 2022

#1287 in Command line utilities


204 lines

Rust UDP Traffic Generator

A CLI tool to generate UDP traffic based on Tokio framework.

Cargo Install

cargo install udp_traffic_generator


./udp_traffic_generator --help
Simple stress test for UDP Server

Usage: udp_traffic_generator [OPTIONS] --destination <addr>

  -d, --destination <addr>     Server address as IP:PORT
  -c, --connections <clients>  Number of clients to simulate [default: 1]
  -l, --length <length>        Payload size as bytes [default: 16]
  -r, --rate <rate>            Defined as packets/sec [default: 1]
  -p, --port <port>            Starting source port for clients [default: 8000]
  -w, --workers <workers>      Number of worker threads for the Tokio runtime [default: #CPU core]
  -s, --sleep time <timeout>   Timeout between consecutive connections spawn as ms [default: 50]
  -h, --help                   Print help information
  -V, --version                Print version information


~163K SLoC