DEV Community

Discussion on: How I Built an API with Mux, Go, PostgreSQL, and GORM

Collapse
 
assertnotnull profile image
Patrice Gauthier

Great article!
I want to point though things to consider though, specially related to web development.
Node or Javascript in general is not made for computational work so the benchmark test doesn't reflect the general problem faced by web development. WebAssembly will help a lot with computational load. To be fair, Node has more of a memory problem when handling a lot of data, I'm facing exponential memory usage at work but this is a different problem.
I think that Golang is really suited for fast and easy to develop portable shell apps (Docker is based on it) and a better contender for web app would be Elixir because of the high availability of 99.9999999% since it's running on Erlang. Think Elixir as Ruby functional programming style. Both Elixir and Go uses a scheduler for concurrency and Elixir Processes are similar to Go routines. Since it's running on Erlang, Elixir processes are made to crash and recover and allows hot swapping of code.

I've looked at both of them in the need of designing a better global distributed high availability service than the current one we have.

References:
smashingboxes.com/blog/choosing-yo...
blog.codeship.com/comparing-elixir...
thecodebarbarian.com/getting-start...