fogus
fogus

Reputation: 6236

Advantages of Erlang over (something like) node.js?

I realize that they are different beast used to solve different problems, but I would like to ask for an enumerated list of advantages of Erlang over node.js (and vice-versa). When would you use one over the other?

Upvotes: 12

Views: 4259

Answers (3)

dingo sky
dingo sky

Reputation: 1445

Don't discount the power of Erlang pattern matching. As much as I like JavaScript, this addictive language feature is simply not baked in. It also seems the JS community doesn't quite appreciate the no shared state paradigm. Finally, multi-instances to utilize multi-cores seems retrograde to me.

Upvotes: 4

Eric
Eric

Reputation: 2706

Erlang is 20 years old, and has been battle-tested many times. Uses all cores on your systems and makes clustering easy.

node.js is still very young, will only use one core per runtime.

And all what Jeremy Wall says.

Upvotes: 11

Jeremy Wall
Jeremy Wall

Reputation: 25237

Erlang is a language and a runtime. I'm assuming you wish a comparison of the erlang runtime with node.js

First I'll list the similarities:

  • Both lend themselves to event driven programming.
  • Both focus on highly asynchronous programming.

And then then the advantages Erlang has:

  • Erlangs message passing abstracts the differences between local and distributed processes making distributed programming easier.
  • Erlangs hot code loading allows for in place releases on running services without disrupting any current activity.
  • Erlang has superior tools for packaging and deployment.
  • Erlangs supervisor and gen_server behviors provide a superior framework for building extremely robust and fault tolerant systems.

Upvotes: 15

Related Questions