Live data from Hacker News

Ask HN: Are you satisfied with Elixir or do you regret choosing Elixir?

news.ycombinator.com

281–290 of 297 posts

Re: Ask HN: Are you satisfied with Elixir or do you regret choosing Elixir?

#281
post #246

Earlier quoted context omitted.

Rails is very productive but it has problems of its own. Many companies move away from Rails once they reach certain growth milestones. Erlang (and by extension Elixir) is a concurrent language. You use it when you have non-trivial concurrency challenges. When tackling the right problems, the language shines. Implementing a simple CRUD application with Elixir is overkill, because you can make your servers stateless a…

In my personal experience (the last bunch of companies I've been at) that milestone you mention is more like what is the current fashion and what the new hires want to work on because of the latest blog post they've read. At my previous job we had * ALL* of them. Each service or project you opened you could guess the date it was started because of how it was built. Rails -> Node -> Elixir -> Go -> Next.js and the fro…

Next.js is node-based.

Re: Ask HN: Are you satisfied with Elixir or do you regret choosing Elixir?

#282

Earlier quoted context omitted.

I am bummed out to see that this is the top comment. I don't doubt your experiences but I hope that other people do not latch on to this and use it as a strong argument against using Elixir. All of these complaints are skin deep and kinda petty, to be honest. > Tooling is just terrible. The VSCode plugin is crap, kills the CPU unless you disable features. There is no IDE from jetbrains. This is a bizarre criticism of…

> I would never complain about a language just because an IDE does not exist for it. I think their complaint is valid, especially in light of their finding it difficult to find experienced coders who are in their salary range. New coders can lean heavily on a good IDE to help: code completion, breakpoints, step wise debugging, one click links to the docs, easy code navigation, and more. Senior coders can and should u…

I haven't used elixir but used erlang for a while, with emacs. It did have a learning curve, but I don't think an IDE would have helped.

Re: Ask HN: Are you satisfied with Elixir or do you regret choosing Elixir?

#283

Earlier quoted context omitted.

Rails is very productive but it has problems of its own. Many companies move away from Rails once they reach certain growth milestones. Erlang (and by extension Elixir) is a concurrent language. You use it when you have non-trivial concurrency challenges. When tackling the right problems, the language shines. Implementing a simple CRUD application with Elixir is overkill, because you can make your servers stateless a…

I really don't see any reason to move from Rails other than a new CTO trying to shake things up with a tech he's more familiar with. If Shopify/Github/Gitlab/ can build it on Rails so can you. If the monolith is too big you can break it down with engines or to separate apps. Now I like Rails but I would say the same about PHP/Node or most popular stacks. Rewrites to another language are almost always unnecessary.

For many years Github ran on a fork of Ruby and a fork of Rails. Recently they upgraded to Ruby 2.7 and that's what they use now.

https://github.blog/2020-08-25-upgrading-github-to-ruby-2-7/

Re: Ask HN: Are you satisfied with Elixir or do you regret choosing Elixir?

#284

Earlier quoted context omitted.

I really don't see any reason to move from Rails other than a new CTO trying to shake things up with a tech he's more familiar with. If Shopify/Github/Gitlab/ can build it on Rails so can you. If the monolith is too big you can break it down with engines or to separate apps. Now I like Rails but I would say the same about PHP/Node or most popular stacks. Rewrites to another language are almost always unnecessary.

For many years Github ran on a fork of Ruby and a fork of Rails. Recently they upgraded to Ruby 2.7 and that's what they use now. https://github.blog/2020-08-25-upgrading-github-to-ruby-2-7/

It says right in your link "Many years ago, we ran GitHub on a fork of Ruby (and Rails!) and while that hasn’t been the case for some time". So that was a long time ago, what is your point?

Re: Ask HN: Are you satisfied with Elixir or do you regret choosing Elixir?

#285
post #196

Earlier quoted context omitted.

The core insight of Erlang is that having lots of little processes communicating over a message bus is a great way to design code. It also proves by demonstration a statement that many programmers, especially in the past decades, would have found hard to believe, that you can structure code as a whole bunch of relatively small self-contained services. Many programmers, perhaps even today, would not believe how far yo…

This comment sold Elixir for me more than anything. On a small team, each of those are massive headaches. Using Elixir I can have all of that with a unified vocabulary, documentation, deployment, syntax, repository, etc. Sure, each might be slightly worse that the best thing on offer today, but I don’t have to glue them together.

And you can swap a built-in feature for an external component later, if the need arises.

Re: Ask HN: Are you satisfied with Elixir or do you regret choosing Elixir?

#286

Earlier quoted context omitted.

Yes, but the difference is that OOP can scale indefinitely but FP cannot. If you don't co-locate related state and logic, ensuring that each piece of state reaches the correct components becomes a logistical nightmare at scale (either needs to traverse many intermediate components or needs to be exposed globally to all components). If you don't allow components to mutate state locally, you need a strategy to distribu…

>> If you don't allow components to mutate state locally, Code mutation is, in my personal experience, a shit show. With Elixir, you I have to worry about some random process mutating your data because it can't, as it's literally immutable. I have never, not a single time, wished I could mutate a data structure in Elixir, because I can think of no case where it makes my life easier. Even quasi-objects, in the C++/Jav…

State mutations are safe and easy to handle if the state is fully contained inside a blackbox (a class) and you only return copies of the state but never the actual references.

A blackbox should never expose object references (its internal state) to its parent components. It should also avoid passing object references to child components unless it's sure that the child component will never mutate this state in an unexpected way.

Re: Ask HN: Are you satisfied with Elixir or do you regret choosing Elixir?

#287

Earlier quoted context omitted.

I don't think I'm gonna stop soon, sorry. For one I really do think Elixir is a horrible career choice and I wanna save young average developers who still have time to correct that mistake (the superstars will do fine no matter what). And second every time I see "Elixir is better Ruby" I get more and more pissed off. If I ever stop reading those things I may slow down about Elixir but you guys just keep me going.

I have read your comments in this thread and your remarks push me more away from Ruby/Rails than Elixir/Phoenix. My first thought was: "wow, some Ruby developers are so insecure about their tech stack that they feel they must criticize other technologies in programming forums to get by". It looks very unprofessional and immature. So think carefully on what you want to achieve, because if your goal is to drag another…

I don't think my comments have anything to do with you wanting to do Elixir, please go ahead with that sir, I don't know you and don't care honestly. I think it's not the greatest decision career-wise but as I said if you're a top 10% developer you'll do fine no matter what tech you choose. If you're not you are most likely to regret it eventually. Elixir is actually a great place for superstars now since it's so small; you can much more easily make a name for yourself there than with php/go/ruby. But for your average web developer Elixir brings very little value. As for insecurity - Elixir as a community started to count page views(!) on ElixirForum to show how the community is thriving. Any other metric - Tiobe index, Stackoverflow, Redmonk, amount of jobs, they're all ignored or gaslighted. So who is insecure? Us Rubyists already took the blowback hit, we know we aren't cool anymore. Elixir is facing that now and in the coming years. And again, if I wouldn't have read countless posts about how Elixir is superior to Ruby (always to Ruby, not to other stacks), though the 2 languages don't have much in common at all, I wouldn't have had such an axe to grind, but I got sick of it.

Re: Ask HN: Are you satisfied with Elixir or do you regret choosing Elixir?

#288
I am super happy with Erlang/Elixir, having build and run game backends, Kafka replicators, an ML platform (models in Python) and several social apps over the years. My story is a bit different but maybe interesting to contrast: I used to work with Ruby for years when I switched to Erlang 9 years ago. So for me the syntax was unfamiliar and the actor model was completely new. Elixir and Phoenix where not around so I started with processes, messages, gen_server and the like. I started building an Erlang-process load balancer, learning about mailboxes and supervision in the process. Later I switched to Elixir and felt reminded of the Ruby syntax, really liking it plus new things like the pipe operator. For me the biggest learning that needs to happen (apart from general FP) is on structuring applications. One way to think about it is having long-running micro services within the VM along with short-lived processes for small tasks like serving a single http request. I can see that coming from Ruby today and using Phoenix can give you a cozy feeling where you build stuff without thinking too much about OTP, processes and how the VM does things (scheduling, mailboxes, monitoring, GC, supervision, distribution). And I think that's totally fine unless you want to step outside the framework and really make use of all the things that set Erlang/Elixir apart. So maybe one way to get started today is looking at Erlang first, explicitly because it's unfamiliar.

Re: Ask HN: Are you satisfied with Elixir or do you regret choosing Elixir?

#289
post #219

We adopted it 4 years ago and love it. As for training people, I taught my non-technical co-founder Elixir for some backend scripts he needed to write. He found it much simpler to pick up then Javascript or Ruby and his code was idiomatic rather quickly. As for the IDE support in VSCode, I've found ElixirLS[1] great. I do have to restart it sometimes (delete the .elixir_ls folder), but that's a small cost to pay for…

Another vote for ElixirLS, I haven’t had much issue with it.

for me it works okay-ish.

I still have to occasionally grab my laptop to keep its fans from taking it airborne, it still crashes occasionally, requiring nuking .elixir_ls (and holding onto the laptop again), and while it hasn't happened recently, I've had situations where I'd get weird errors for code that should be fine, also requiring me to delete .elixir_ls to get rid of the warnings.

That said, I don't really mind, but then I perhaps don't care as much about IDE-ish features. I've also been doing more and more work inside LiveBooks, and those don't even have vim keybinding!

Re: Ask HN: Are you satisfied with Elixir or do you regret choosing Elixir?

#290
post #189
post #166

Earlier quoted context omitted.

>One of the reasons I make a bit of an accusation that the people bedazzled by Erlang/Elixir may be not very experienced is that a common take away from the community I have repeatedly noticed is the belief that if another language doesn't have exactly what Erlang has, warts and all, it doesn't have what Erlang has. On one level yes, they have constructs that you can use to accomplish some of the same goals as the to…

"The concurrency characteristics of the systems I hack on every day would be much harder to model without GenServers. It's not particularly surprising that Erlang is not the only way to solve a problem in software engineering, there is no silver bullet." Erlang was at one point the only way to get this sort of structure, though. Now it isn't. Multiple languages like Go have lightweight coroutine-y type things; if the…

> you can fix it with programming discipline

You can write distributed coroutines in assembly with enough programming discipline. What is interesting in a language is not what it lets you do, it's what it prevents you from doing.

Post reply on HN