4 ms·
Interesting findings. I was always a bit wary about just benchmarking the raw http implementation instead of a more real world scenario.
by flagged24 3y ago
Interesting findings. I was always a bit wary about just benchmarking the raw http implementation instead of a more real world scenario.
- vorticalbox 3y agoProblem is that "real world" adds way more variables that you cannot control. I can make a hello world api in go that will handle way more requests than an express app but as soon as I put a database call we'll the go/node are pretty much neck and neck because the dB doesn't really respond any fast. Now I know the go server will literally be able to handle more concurrent clients but that is not "speed" benchmark anymore.
- flagged24 3y agoI've seen benchmarks where Node outperforms Go when utilizing Node 's worker threads [0]. But you're right, making real world benchmarks is hard. Even though the mentioned article is using a pure javascript qr code module with no external dependency (eg a database) in order to test a bit more than just the http implementation which is probably just the C implementation in Node.js and the ZIG version in Bun. [0] https://medium.com/@Cazineer/go-goroutines-vs-node-cluster-worker-threads-part-2-52611217340a https://medium.com/@Cazineer/go-goroutines-vs-node-cluster-w...