Ruby vs Elixir – Panel discussion at Wroc_love.rb [video]
1–10 of 50 posts
Re: Ruby vs Elixir – Panel discussion at Wroc_love.rb [video]
#2- Elixir runs on a battle-tested virtual machine, and stuff like supervisor behavior (e.g. auto-restart of crashing processes) is built right in
- Elixir is a functional language, which makes the code you write more testable
- State in Elixir is immutable, which greatly reduces the side effects of running code
I used to develop in Ruby circa 2014-2015. It will always have a special place in my heart, but to be frank, I don't really miss it. Elixir, as a language, is better in almost every way. And once the ecosystem becomes a bit more mature, it will be unstoppable (OK maybe not really, but it's definitely here to stay).
Re: Ruby vs Elixir – Panel discussion at Wroc_love.rb [video]
#3I think it comes down to this: with Elixir, you gain a lot over Ruby and lose very little. Any Elixir app will be significantly more performant and reliable than its Ruby counterpart. This is due to several reasons: - Elixir runs on a battle-tested virtual machine, and stuff like supervisor behavior (e.g. auto-restart of crashing processes) is built right in - Elixir is a functional language, which makes the code you…
Re: Ruby vs Elixir – Panel discussion at Wroc_love.rb [video]
#4Sure, they may be able to cut and paste a Phoenix demo to get something sort-of working, but they have No Idea how everything works.
Re: Ruby vs Elixir – Panel discussion at Wroc_love.rb [video]
#5I think it comes down to this: with Elixir, you gain a lot over Ruby and lose very little. Any Elixir app will be significantly more performant and reliable than its Ruby counterpart. This is due to several reasons: - Elixir runs on a battle-tested virtual machine, and stuff like supervisor behavior (e.g. auto-restart of crashing processes) is built right in - Elixir is a functional language, which makes the code you…
Re: Ruby vs Elixir – Panel discussion at Wroc_love.rb [video]
#6I think it comes down to this: with Elixir, you gain a lot over Ruby and lose very little. Any Elixir app will be significantly more performant and reliable than its Ruby counterpart. This is due to several reasons: - Elixir runs on a battle-tested virtual machine, and stuff like supervisor behavior (e.g. auto-restart of crashing processes) is built right in - Elixir is a functional language, which makes the code you…
The one use case where Ruby still wins for me, though, is a little one-off script. Last time I had occasion to do that, I found you couldn't use any Elixir hex packages without generating a whole mix application. In ruby you could just globally install the gem and require it right into your script.
I forget why this came up, but I think it was something like just wanting to download a web page and parse out a certain bit of it into a CSV file or something like that. Pretty trivial in Elixir with HTTPoison and Floki, but no real way to use those in a one-off .exs file (I don't think?). Whereas in ruby, I've already got HTTParty and Nokogiri in there somewhere, and you can toss it together in a minute.
Re: Ruby vs Elixir – Panel discussion at Wroc_love.rb [video]
#7I think it comes down to this: with Elixir, you gain a lot over Ruby and lose very little. Any Elixir app will be significantly more performant and reliable than its Ruby counterpart. This is due to several reasons: - Elixir runs on a battle-tested virtual machine, and stuff like supervisor behavior (e.g. auto-restart of crashing processes) is built right in - Elixir is a functional language, which makes the code you…
> 4.even?
=> true
That's not to say that what Elixir provides is (or is not) worth giving up everything-is-an-object because Erlang's design does what it is supposed to do very very well.Re: Ruby vs Elixir – Panel discussion at Wroc_love.rb [video]
#8I think it comes down to this: with Elixir, you gain a lot over Ruby and lose very little. Any Elixir app will be significantly more performant and reliable than its Ruby counterpart. This is due to several reasons: - Elixir runs on a battle-tested virtual machine, and stuff like supervisor behavior (e.g. auto-restart of crashing processes) is built right in - Elixir is a functional language, which makes the code you…
Re: Ruby vs Elixir – Panel discussion at Wroc_love.rb [video]
#9I think it comes down to this: with Elixir, you gain a lot over Ruby and lose very little. Any Elixir app will be significantly more performant and reliable than its Ruby counterpart. This is due to several reasons: - Elixir runs on a battle-tested virtual machine, and stuff like supervisor behavior (e.g. auto-restart of crashing processes) is built right in - Elixir is a functional language, which makes the code you…
Playing around with Elixir, it seems like it loses Ruby's Smalltalk like "everything is an object" that allows things like: > 4.even? => true That's not to say that what Elixir provides is (or is not) worth giving up everything-is-an-object because Erlang's design does what it is supposed to do very very well.
It's a deep subject but one of the biggest things is that it's virtually impossible to end up with the untenable monolith that many ruby apps eventually grow into. Since you aren't dealing with crazy inheritance trees attached to data separating things out really just becomes moving code around.
I do both Ruby and Elixir code right now. There are times when I like the convenience of Ruby for command line scripts or monkey patching a quick modification for a 3rd party library...but there are other times when you hit problems that you just can't solve effectively without rewriting in something else and that gets annoying. That's one of the reasons you see so many posts about moving from Ruby to Go or Elixir because both languages are much better at Ruby's weakest points.
But it's always worth noting that Ruby got those projects to market with maturity and helped them grow customer bases with enough traffic to JUSTIFY a rewrite. What gets people so excited about Elixir is that you lose very little in the development time department for full stack while avoiding the long term complications due to the language rules. All that said, it makes you think about problems differently which will be a challenge for people at first.
Re: Ruby vs Elixir – Panel discussion at Wroc_love.rb [video]
#10Earlier quoted context omitted.
Playing around with Elixir, it seems like it loses Ruby's Smalltalk like "everything is an object" that allows things like: > 4.even? => true That's not to say that what Elixir provides is (or is not) worth giving up everything-is-an-object because Erlang's design does what it is supposed to do very very well.
There's basically data and functions, so 4 wouldn't really have any methods attached to it and instead you'd just call Number.even?(4). Purely psuedo code example. It's a deep subject but one of the biggest things is that it's virtually impossible to end up with the untenable monolith that many ruby apps eventually grow into. Since you aren't dealing with crazy inheritance trees attached to data separating things out…
4 |> Integer.is_even
Above can be even shortened if you import Integer module: import Integer
(...)
4 |> is_even