<story><title>Unpacking Elixir: Concurrency</title><url>https://underjord.io/unpacking-elixir-concurrency.html</url></story><parent_chain><item><author>fndex</author><text>This is coming from someone who likes Elixir. Not much for its distributed systems features, but mostly because of the language design. I keep hearing everyone talk about how Erlang&amp;#x2F;Elixir gives everything out of the box and you don&amp;#x27;t need to worry about Queues, RPC or whatever... But in reality, people don&amp;#x27;t really recommend using Distributed Erlang that much, on most Elixir gigs I worked, they didn&amp;#x27;t use Distributed Elixir at all, just plain old Kubernetes, Kafka, Redis and GRPC.</text></item><item><author>tombert</author><text>Disckaimer: I have never used Elixir in any serious capacity, but I have done a good chunk of Erlang.&lt;p&gt;Concurrency in Erlang sort of frustrates me...not because it&amp;#x27;s bad, but because when I use it I start getting pissed at how annoying concurrency is in nearly every other language.  So much of distributed systems tooling in 2023 is basically just there to port over Erlang constructs to more mainstream languages.&lt;p&gt;Obviously you can get a working distributed system by gluing together caches and queues and busses and RPC, but Erlang gives you all that out of the box, and it all works.</text></item></parent_chain><comment><author>josevalim</author><text>&amp;gt; I keep hearing everyone talk about how Erlang&amp;#x2F;Elixir gives everything out of the box and you don&amp;#x27;t need to worry about Queues, RPC or whatever...&lt;p&gt;Many companies are using Distributed Erlang but not the way you described: they are using it to exchange messages between nodes running the same version of the software. Imagine that you are building a web application, you can directly exchange live messages between nodes without Redis&amp;#x2F;RabbitMQ [1]. If you are deploying a machine learning model, you can route requests through multiple nodes and GPUs without additional deps [2]. If you want to see which users are connected to your app, you can exchange this information directly between nodes [3].&lt;p&gt;In other words, there is a subset of distributed problems that Distributed Erlang solves very well out of the box: homogeneous systems working on ephemeral data. And some of the scenarios above are very common.&lt;p&gt;If you need to communicate between different systems or you need to persist data, then I 100% agree with you, I would not use Distributed Erlang (at best it would be one part of the solution). I think this distinction gets lost in many conversations and sometimes it leads to false dichotomies: &amp;quot;why Erlang when I have k8s&amp;#x2F;grpc&amp;#x2F;redis?&amp;quot; while in practice there is not a lot of overlap. I have written about Erlang&amp;#x2F;Elixir vs Redis [4] and vs k8s [5] for those interested.&lt;p&gt;[1]: &lt;a href=&quot;https:&amp;#x2F;&amp;#x2F;hexdocs.pm&amp;#x2F;phoenix_pubsub&amp;#x2F;Phoenix.PubSub.html&quot; rel=&quot;nofollow noreferrer&quot;&gt;https:&amp;#x2F;&amp;#x2F;hexdocs.pm&amp;#x2F;phoenix_pubsub&amp;#x2F;Phoenix.PubSub.html&lt;/a&gt;
[2]: &lt;a href=&quot;https:&amp;#x2F;&amp;#x2F;news.livebook.dev&amp;#x2F;distributed2-machine-learning-notebooks-with-elixir-and-livebook---launch-week-1---day-2-1aIlaw&quot; rel=&quot;nofollow noreferrer&quot;&gt;https:&amp;#x2F;&amp;#x2F;news.livebook.dev&amp;#x2F;distributed2-machine-learning-note...&lt;/a&gt;
[3]: &lt;a href=&quot;https:&amp;#x2F;&amp;#x2F;hexdocs.pm&amp;#x2F;phoenix&amp;#x2F;Phoenix.Presence.html&quot; rel=&quot;nofollow noreferrer&quot;&gt;https:&amp;#x2F;&amp;#x2F;hexdocs.pm&amp;#x2F;phoenix&amp;#x2F;Phoenix.Presence.html&lt;/a&gt;&lt;p&gt;[4]: &lt;a href=&quot;https:&amp;#x2F;&amp;#x2F;dashbit.co&amp;#x2F;blog&amp;#x2F;you-may-not-need-redis-with-elixir&quot; rel=&quot;nofollow noreferrer&quot;&gt;https:&amp;#x2F;&amp;#x2F;dashbit.co&amp;#x2F;blog&amp;#x2F;you-may-not-need-redis-with-elixir&lt;/a&gt;
[5]: &lt;a href=&quot;https:&amp;#x2F;&amp;#x2F;dashbit.co&amp;#x2F;blog&amp;#x2F;kubernetes-and-the-erlang-vm-orchestration-on-the-large-and-the-small&quot; rel=&quot;nofollow noreferrer&quot;&gt;https:&amp;#x2F;&amp;#x2F;dashbit.co&amp;#x2F;blog&amp;#x2F;kubernetes-and-the-erlang-vm-orchest...&lt;/a&gt;</text></comment>
<story><title>Unpacking Elixir: Concurrency</title><url>https://underjord.io/unpacking-elixir-concurrency.html</url></story><parent_chain><item><author>fndex</author><text>This is coming from someone who likes Elixir. Not much for its distributed systems features, but mostly because of the language design. I keep hearing everyone talk about how Erlang&amp;#x2F;Elixir gives everything out of the box and you don&amp;#x27;t need to worry about Queues, RPC or whatever... But in reality, people don&amp;#x27;t really recommend using Distributed Erlang that much, on most Elixir gigs I worked, they didn&amp;#x27;t use Distributed Elixir at all, just plain old Kubernetes, Kafka, Redis and GRPC.</text></item><item><author>tombert</author><text>Disckaimer: I have never used Elixir in any serious capacity, but I have done a good chunk of Erlang.&lt;p&gt;Concurrency in Erlang sort of frustrates me...not because it&amp;#x27;s bad, but because when I use it I start getting pissed at how annoying concurrency is in nearly every other language.  So much of distributed systems tooling in 2023 is basically just there to port over Erlang constructs to more mainstream languages.&lt;p&gt;Obviously you can get a working distributed system by gluing together caches and queues and busses and RPC, but Erlang gives you all that out of the box, and it all works.</text></item></parent_chain><comment><author>weatherlight</author><text>Well, in big orgs, that adopt Elixir&amp;#x2F;Erlang, along with other technologies with poor concurrency stories, those other ecosystems still need Kubernetes, Kafka, Redis and GRPC, to get by. elixir isn&amp;#x27;t going to make ruby or python apps magically  concurrent. So that make sense.&lt;p&gt;However, in orgs that are primarily Elixir shops, I don&amp;#x27;t see a lot of Kafka or gRPC. (Redis is just useful, its more than just a queue and K8s and Elixir&amp;#x2F;Erlang compliment each other, btw.)</text></comment>