What are the most important features Elixir has for you and why?

Background

Imagine someone asks you to evaluate someone regarding their level of Elixir knowledge. You know some stuff, but you are not the smartest guy in the block and you want to make pertinent questions that can give you a clear understanding of someones knowledge level in Elixir.

My understanding is that everyone thinks differently, so what I see as being important for an Elixir developer may be seen as irrelevant by someone else.

So I would like to know for you, personally, what and the 3 things you think people claiming to know Elixir should know, and why do you think those 3 things are important.

Question

What are the top 3 most important Elixir features for you and why do you think everyone should know them?

It is an open question, everyone is welcome to share their opinion !

Can’t decide the top 3, but the most important feature for me: It solves concurrency. I find it quite astonishing, Erlang introduced a perfect solution 33 years ago, for problems that are still a huge issue in many modern programming language. There are even frameworks trying to rebuild something similar in other languages, like https://getakka.net/ for c#.

Hmm, so maybe this is already 3: The lightweight processes, the supervisors, the process communication via messages.

2 Likes

I like fault tolerance. Trying to explain to non-erlang/elixir programmers how your software can fix itself when it fails is fun.

You can connect to a live system, debug, repair without stopping the service.

You can play with processes, and see what happens when You kill them :slight_smile:

So my list is

  • Concurrency
  • Fault tolerance
  • (Soft) Real time

The last one being more personal, and more Phoenix, as I can build reactive web with channels.

3 Likes
  • Immutability, i.e.
    old_a = a
    foo(a)
    a == old_a
    
    This is enormous help when analysing and reading code, as “what I see is what I get” and I know that (in most cases) there will be no magic behind scenes that could change behaviour of my code.
  • Application servers done right. I can run multiple (OTP) applications within the same VM without problems. So I get everything what is best in application servers and at the same time I get hell lot of different nice properties, like proper fault tolerance.
  • Distribution of the system - I can easily configure VMs on different machines to be transparently treated as one. No need for external tooling (except epmd replacement).
3 Likes
  • Immutability. Reduces bugs and frees you from safeguarding by deep copying or the likes.
  • Pattern matching. Makes it much more convenient to extract values e.g. deep inside a JSON structure.
  • Simple and consistent language core. Relatively small set of language concepts. It won’t take you a lifetime to be productive in the language.

The runtime’s support for concurrency and fault-tolerance is an added bonus of course.

5 Likes
  1. Not really related to the language per se, but I do think that asking how involved with the community a candidate is is really telling. Have been to any conference or meetup ? So you participate in forums ? Have you ever wrote or publish something on the subject ? I think that shows you how commited they are.

  2. How Elixir / Erlang solve concurrency

  3. What sets Elixir and functional programming apart from other languages and paradigms

1 Like