Eugene Retunsky
1 min readFeb 27, 2021

--

Okay, I measured `node-tcp-proxy`.

1. Installed npm i node-tcp-proxy

2. Launched the binary tcpproxy (exactly as other TCP proxies in this test).

It is somewhere in between NetCrusher(Java) and pproxy (Python) in terms of latency. It made up 25k RPS (similar to NetCrusher).

Slightly worse latency than NetCrusher(Java), but lower StdDev.

You can see some number below for all three use-cases:

1. Moderate TPS (had to limit by 15k rps):

Request rate: 14997.107 per second

Success rate: 100.000%

Total bytes: 9.0 GB

Bitrate: 1199.769 Mbps

Latency:

Min : 93µs

p50 : 438µs

p90 : 795µs

p99 : 1580µs

p99.9 : 12837µs

p99.99 : 14664µs

Max : 17597µs

Mean : 521µs

StdDev : 578µs

tm99.9 : 507µs

2. The max TPS:

Request rate: 25084.789 per second

Success rate: 100.000%

Bitrate: 2006.783 Mbps

Latency:

Min : 109µs

p50 : 3509µs

p90 : 7152µs

p99 : 18465µs

p99.9 : 23315µs

p99.99 : 39224µs

Max : 222430µs

Mean : 3967µs

StdDev : 3351µs

tm99.9 : 3941µs

3. No keep-alive:

Request rate: 3498.086 per second

Bitrate: 279.847 Mbps

Latency:

Min : 442µs

p50 : 1879µs

p90 : 2728µs

p99 : 3628µs

p99.9 : 7427µs

p99.99 : 15360µs

Max : 17384µs

Mean : 1931µs

StdDev : 684µs

tm99.9 : 1923µs

I can share the bash scripts if you'd like to compare different JS frameworks. It took ~10 minutes for me to set the test bed and run benchmarks.

--

--

Eugene Retunsky
Eugene Retunsky

Written by Eugene Retunsky

Tech leader with hands-on experience in building and operating large-scale systems. Ex-AWS/Ex-Google. Focusing on reliability, security, and performance.

No responses yet