netzy is a terminal-based real-time network connection monitor written in Go. It listens to active sockets and packet flows, mapping connections to system processes to show exactly which applications are consuming bandwidth.
I was trying to debug a weird background network call on my Linux machine, and standard tools like `lsof` or `netstat` required repetitive polling, while `wireshark` was too heavy. I wanted a fast, lightweight, and interactive command-line interface that immediately answers the question: "Which process is sending packets right now?" I chose Go for its lightweight concurrency models and cross-compilation binaries, making it easily distributable.
The hardest challenge was gathering connection-to-process mappings under Linux. Directly reading from `/proc/net/tcp` and matching inodes with `/proc/[pid]/fd` was slow when done sequentially. I optimized it by building a concurrent worker pool that periodically updates a cache of PIDs and their active file descriptors.