Top all-time · #2644
Blog on Stressgrid
Company blog · stressgrid.com/blogsystemsprogramming
Blog on Stressgrid is the company blog at stressgrid.com, writing about systems and programming. Since 2019, 28 different Hacker News readers have linked it 35 times, most often “Benchmarking Go vs. Node vs. Elixir”. The last post was in 2020, but the archive is still widely read.
Stress-test your backend by simulating millions of users
Most-linked posts?
- Benchmarking Go vs. Node vs. Elixir8 people · 8 mentions · first linked 2019-02-05
- The Curious Case of Beam CPU Usage (2019)7 people · 7 mentions · first linked 2019-02-14
- Webserver Benchmark: Erlang vs. Go vs. Java vs. Node.js4 people · 4 mentions · first linked 2020-01-07
- Packets-per-Second Limits in EC23 people · 3 mentions · first linked 2019-04-24
- Survey of Cowboy Webserver Performance – Part 23 people · 3 mentions · first linked 2019-12-11
- Achieving 100k connections per second with Elixir3 people · 3 mentions · first linked 2019-03-05
What Hacker News says?
As far as from my tests and what I've seen reported online, Go and Rust have a substantial lead (20% ish) over Erlang for high throughput servers. EDIT: I believe this is partially due to Go being a lot more CPU efficient overall than Erlang (see below). So for simple servers, Go and Erlang will match performance, but for slightly more complex web servers that need to crunch some data, Go [and Rust] will outperform…
Comment linking /blog/benchmarking_go_vs_node_vs_elixir/
on “Achieving 100k connections per second with Elixir”Submitted Achieving 100k connections per second with Elixir as a story · 544 points
HN discussionErlang/Elixir's VM is gear toward high uptime, low latency, and highly concurrent. https://stressgrid.com/blog/100k_cps_with_elixir/ What it's not good at is numerical computation. As for the others I have no clue but I am sure jvm won't be as low latency as Elixir's VM since it's not a preemptive scheduler.
Comment linking /blog/100k_cps_with_elixir/
on “Elixir, Phoenix, Absinthe, GraphQL, React, and Apollo”Submitted Benchmarking Go vs. Node vs. Elixir as a story · 75 points
HN discussionI have commented this in other places but the main explanation for the benchmark you linked is that Phoenix (and its underlying Cowboy webserver) are not optimized for this particular workflow. For a plain-text benchmark, you are ultimately measuring the ability of sitting on top of a socket and reading/writing to that socket as fast as you can. However, Phoenix/Cowboy, whenever there is an HTTP connection, spawns a…
Comment linking /blog/cowboy_performance_part_2/
on “Phoenix LiveDashboard”Submitted The Curious Case of Beam CPU Usage (2019) as a story · 36 points
HN discussion> I picked up _Programming Erlang_ because I like Joe. I'm trying to understand why the platform, and the accompanying language(s), aren't more widely used? People seem to speak very highly about Elixir, BEAM, and OTP. It all seems really great... Watching videos of Joe talk super impressed me. He kept the same enthusiasm for programming as any college age programmer. That's impressive! > From @hajile >>BEAM is abou…
Comment linking /blog/webserver_benchmark/response_lat90.png
on “Elixir v1.10”Submitted Webserver Benchmark: Erlang vs. Go vs. Java vs. Node.js as a story · 35 points
HN discussionElixir and Go both have similar performance (although Elixir tends to use a lot more CPU). Here's a pretty good blog post comparing Go, Node and Elixir: https://stressgrid.com/blog/benchmarking_go_vs_node_vs_elixi...
Comment linking /blog/benchmarking_go_vs_node_vs_elixir/
on “Ask HN: Who regrets choosing Elixir?”Submitted Benchmarking Go vs. Node vs. Elixir (2020) as a story · 6 points
HN discussionhuh. that seems like a lot of waste for no measurable benefit: https://stressgrid.com/blog/beam_cpu_usage/ maybe it's beneficial to someone, but I don't think that should be the default. either way, it doesn't change the picture painted by the TechEmpower benchmarks.
Comment linking /blog/beam_cpu_usage/
on “Why I Don't Like Golang (2016)”Submitted Webserver Benchmark: Erlang vs Go vs Java vs NodeJS as a story · 4 points
HN discussionI feel like that article just supports the comment you're replying to. I mean, look at this: https://stressgrid.com/blog/benchmarking_go_vs_node_vs_elixi... If the article had gone up to 250K connections, Elixir would have fallen down similarly to what happened to Node... although the reasons for Node being unable to keep up were unclear in the article, and I think warranted further investigation that the article di…
Comment linking /blog/benchmarking_go_vs_node_vs_elixir/100K-cpu.png
on “Why I Don't Like Golang (2016)”Submitted Packets-per-Second Limits in EC2 as a story · 4 points
HN discussionFor what purpose? See: https://stressgrid.com/blog/benchmarking_go_vs_node_vs_elixi...
Comment linking /blog/benchmarking_go_vs_node_vs_elixir/
on “Why I Don't Like Golang (2016)”Submitted The Curious Case of BEAM CPU Usage as a story · 4 points
HN discussionYour comment: > "the stressgrid benchmarks look bad because they forgot to turn off the "spin your cpus" setting" stressgrid blog post: > "When running HTTP workloads with Cowboy on dedicated hardware, it would make sense to leave the default—busy waiting enabled—in place. When running BEAM on an OS kernel shared with other software, it makes sense to turn off busy waiting, to avoid stealing time from non-BEAM proce…
Comment linking /blog/beam_cpu_usage/
on “An Elixir adoption success story”Submitted Benchmarking Go vs. Node vs. Elixir as a story · 2 points
HN discussionbusy wait spins your cpus. I don't know for sure, but the benchmarks you linked do some more RCA, which involves looking into why cowboy2 is not great (tl;dr HTTP2 support is hard) also, here is how stressgrid can POC (possibly too dangerous for prod?) to 100k cps (which is on par with what Go can do in the article you linked), you could recompile kernel and configure ranch differently, would probably need to be pro…
Comment linking /blog/100k_cps_with_elixir/
on “An Elixir adoption success story”Submitted Survey of Cowboy Webserver Performance – Part 2 as a story · 2 points
HN discussionthe stressgrid benchmarks look bad because they forgot to turn off the "spin your cpus" setting. That optimization is really important for some lower-performing platforms of yesteryear (which the erlang VM does need to continue supporting) but basically irrelevant for modern platforms, and actually bad, if you're getting charged CPU credits. However, it's a command line switch away. I don't know if the default has b…
Comment linking /blog/beam_cpu_usage/
on “An Elixir adoption success story”Submitted The Curious Case of Beam CPU Usage as a story · 2 points
HN discussionSo many people talk Erlang / Elixir insane concurrency … but I’m struggling to reconcile the talk with what I find in stress testing and benchmarks results. Can you comment on why so many benchmarks show Erlang / Elixir performing significantly worse than other languages like Go. https://stressgrid.com/blog/webserver_benchmark/ https://stressgrid.com/blog/cowboy_performance/ https://www.techempower.com/benchmarks/ E…
Comment linking /blog/cowboy_performance/
on “An Elixir adoption success story”Submitted Stressgrid: Stress-test your backend by simulating millions of users as a story · 1 points
HN discussionIt is explained in the blog post after that benchmark - https://stressgrid.com/blog/beam_cpu_usage/ . Essentially in order to optimise responsiveness the BEAM uses busy waiting, which in reality is not actually utilising the CPU as much as is reported by the OS, which results in misleading CPU usage being reported by the operating system.
Comment linking /blog/beam_cpu_usage/
on “Lovely Week with Elixir”Submitted Show HN: Packets-per-Second Limits in EC2 as a story · 1 points
HN discussionWe can't compare about CPU values Can you explain more why we can't compare? Looking at this chart... https://stressgrid.com/blog/benchmarking_go_vs_node_vs_elixi... ...shows pretty clearly how the CPU utilization grows linearly (ignoring some sawtooth) as the load increases, plateaus once the load remains constant, and then comes down linearly as the load decreases on the other end. Looks like a very clear mapping…
Comment linking /blog/benchmarking_go_vs_node_vs_elixir/10K-cpu.png
on “Lovely Week with Elixir”Submitted Packets-per-Second Limits in EC2 as a story · 1 points
HN discussionI have assumed BEAM has similar latency to Go and is garbage collected? Here is some benchmarks where Erlang beats Go in throughput: https://timyang.net/programming/c-erlang-java-performance/ https://stressgrid.com/blog/benchmarking_go_vs_node_vs_elixi...
Comment linking /blog/benchmarking_go_vs_node_vs_elixir/
on “Lovely Week with Elixir”Here's a good comparison between Elixir, Go, and Node: https://stressgrid.com/blog/benchmarking_go_vs_node_vs_elixi... Some of the things I like better about Elixir and Erlang vs. Go and Java are: - In Elixir/Erlang, all processes are stored in private memory and can only be accessed via defined message interfaces. In both Go and Java, processes are stored in public memory. - Elixir/Erlang processes are a lot smalle…
Comment linking /blog/benchmarking_go_vs_node_vs_elixir/
on “Erlang/OTP 25.0 Release”