Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Although not in Erlang, Discord uses Elixir which runs on the BEAM VM to much success as well for our real time distributed system as well as VOIP signaling components. Looking back years later - it’s safe to say we wouldn’t have chosen anything else.


They link to a form at the bottom of the article where you can submit your own story, if you'd like to contribute: https://docs.google.com/forms/d/e/1FAIpQLScZnppXbZLz-vVfS8Mr...


What was the reason to choose Elixir over Erlang? Just familiarity with the language?


Not OP, but have used Elixir pretty extensively; the major selling points for me are the friendlier syntax and more active community support, plus with rebar3 + Elixir's seamless Erlang interop you really don't give up anything, you can use any existing Erlang/Elixir libraries with a single syntax. It's pretty great.


Haven't touched Erlang but has an entry level knowledge on Elixir. I often heard how easy it is to write macros on Elixir. Can you elaborate on this?


One of the big differences between Erlang and Elixir is indeed that Elixir allows you to write macros in the language itself, using quote / unquote constructs just like lisps.

This makes it easy to generate code on compile time, which is then executed in runtime without any performance penalty.

A large part of Elixir itself is actually implemented as macros. For instance, the "unless" construct:

  defmacro unless(condition, do: do_clause, else: else_clause) do
    quote do
      if(unquote(condition), do: unquote(else_clause), else: unquote(do_clause))
    end
  end

(code simplified for clarity)


And the if-else construct is also a macro. The whole thing ends up being a case I think.


Imho You shouldn't really write macros, they are there for libraries to make it easy to do the right thing with less boilerplate.


[flagged]


Your question is very vague. What exactly do you mean by "the same results"? And which "alternative tools"? How do those tools provide "an alternative"?


They're not obligated to write an entire book in passing response to a thread on HN.


They have blogged quite extensively about it, for several years. Check their blog.


[flagged]


> But please downvote away :)

I don't think you're getting downvoted because you're not praising a piece of technology; you're getting downvoted because your tone seems rude, arrogant, and like you're on a witch-hunt rather than an honest inquiry. While tech fan-clubs do exist on HN, in my experience they respond quite constructively to reasoned criticism--if it's not phrased in an unkind way.


I'm not for or against Erlang. While honestly attempting to learn something new today, I became frustrated with how devoid of content most of the comments in this thread are. "I'm {senior title}, and {tech name} is great" is as far as most of the comments go. That's just extremely mediocre.


A comment section isn't the place to look for detailed content so why get frustrated about the brevity here? There are plenty of places to deep dive in the internet.


> What does "running to much success" mean exactly?

When you ask questions like this, you sound combative, rather than curious - because the success of Discord is rather well documented.

> Why could you not have achieved the same results using alternative tools?

How can this be answered without trialling every other tool? Again, you sound combative.


[flagged]


Feel free to read the Discord engineering blogs instead of demanding answers on HN mate.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: