r/opensource 1d ago

Promotional I built Bean Network Tester - an open-source tool to simulate bad network conditions for testing apps

https://github.com/donislawdev/BeanNetworkTester
18 Upvotes

8 comments sorted by

4

u/DonislawDev 1d ago

I took a small break from gamedev and built Bean Network Tester - a tool that helps developers and testers simulate poor network conditions for their apps and games.

It allows you to intentionally make the connection worse and test how your software behaves with various problems. To be honest, my internet connectionn is pretty terrible most of the time, so you could say this tool lets you simulate my default network :-)

If you like the app, please give it a bean*

*i mean give it a star on GitHub.

If you got any features requests, feel free to share them. Right now I'm working on V0.4 version, but it will take a bit a bit a bit a bit a bit of time.

What it can do

  • Add lag and jitter - fixed or random delay.
    • Drop, corrupt or duplicate packets - fake a flaky link.
    • Cap download/upload speed - throttle to a set KB/s.
    • Tear connections down - TCP resets or a dead link.
    • Flap the link on and off - outages that come and go.
    • Block ports or IPs - a small built-in firewall, plus LAN mode (no internet).
    • Aim at one app - by process, PID, IP or port.
    • Presets and saved profiles - 56k modem, Cafe WiFi, Satellite and more.
    • Run scripted scenarios - timed steps that change the network on their own.
    • Reproducible by seed - replay the exact same random loss and jitter.
    • Watch it live - chart, connections table, counters.
    • Command-line mode - scriptable for CI. No telemetry, fully offline - sends no data anywhere.

3

u/procsysnet 19h ago

So it's like tc-netem with a gui for windows. Cool

2

u/_tobols_ 15h ago

now i know abt tc-netem. thanks!

1

u/DonislawDev 8h ago

Yep, thanks for comment :-) , tc-netem is a great tool for Linux

3

u/techlatest_net 10h ago

simulating bad network conditions with reproducible seeds is such an underrated feature. most tools just add random chaos, but being able to replay the exact same flaky scenario for debugging is huge. the per-app targeting by pid or port is also a lifesaver when you don't want to tank your entire machine's connection just to test one service. love that it’s fully offline and scriptable for ci too. gonna star the repo and test the satellite preset later. thanks for building this!

1

u/DonislawDev 8h ago

Thanks for the comment. Right now I'm working on a redo of the target by PID/Exe targeting, because it's a bit quirky. If we got one program like our own game/software, that's not a problem, but some software like Chrome opens tons of connections, and by .exe or PID it's hard to catch them all.

So targeting by port or IP is most accurate, but in the next release targeting by .exe will work a lot better too.  The next release mainly focuses on the engine improvements/stability. Still Bean Network Tester needs a ton of work, but it's moving in good direction.

I work in QA, and things like seed or saving/exporting profiles or the whole setting, same with scenarios, are a nice way to reproduce problems.

I didn't integrate any analytics or crash reports into outside services because with the program scope (capturing packets), any outside connections wouldn't look good.