Live data from Hacker News

Elixir 1.5 released

github.com

121–130 of 167 posts

Re: Elixir 1.5 released

#121

Is Elixir being used exclusively for web development? If not, what else are people using it for?

I use it for everything from bots to interacting with and controlling Java and Python programs and a lot more. The concurrency abilities of the BEAM have a lot of applications.

Re: Elixir 1.5 released

#122

What frontend stack fits Elixir most symmetrically? Is there a "ClojureScript" to Elixir's "Clojure"?

Bucklescript works fantastic in the Elixir system (I have a bucklescript-tea library that maps Elm code 'almost' verbatum to Bucklescript code too).

There is an ElixirScript project in current dev, still early but usable, that compiles Elixir code to javascript too.

Re: Elixir 1.5 released

#123

Earlier quoted context omitted.

Well first, Elixir isn't purely functional. It's got side effects all over the place, it just doesn't have mutable variables. Second... While I love static typing as much as the next guy, there's definitely value in immutable data in a dynamic language. You also get Dialyzer in Elixir/Erlang, which is an interesting alternative to the usual type systems you find in Haskell/Rust/etc. in that it focusses on finding pla…

> there's definitely value in immutable data in a dynamic language. Sure, but there's even more value in immutable data in a statically typed language, because of all the advantages that come with such a language (automated refactoring, better performances, tooling, etc...).

I've been working with the BEAM (via Erlang) for over a decade, and with Elixir for almost 1.5 years, and I'd still give up, well, probably my current job if I could get a fully Hindley-Milner Typed Elixir...

Re: Elixir 1.5 released

#124
post #108

Earlier quoted context omitted.

For an improvement of 2 orders of magnitude while maintaining the same level of developer complexity, I'm hard pressed to think of any other web framework besides Phoenix that can deliver this.

Java and C# easily outclass Phoenix i performances, if only because they are statically typed, but also because they run on VM's that are more advanced (and admittedly older, so more optimized) than BEAM.

Java and C# outclass performance in raw CPU work certainly. Phoenix does not do raw CPU work however, it is primarily a web dispatcher on top of cowboy and the BEAM will run circles around both Java and C# systems if they are programmed to anywhere near the same quality of failure handling that the BEAM implicitly supplies (/me has worked with both Java and the BEAM for over 10 years).

Also, the Erlang VM is older than the JVM, initially created in the late 1980's. The JVM, according to wikipedia, was introduced in 1994. Also the BEAM has significantly better GC handling that both the JVM and .NET both since it has a segmented memory model (each actor has segmented memory) unlike the JVM and .NET's monolithic Heap's, this allows it to perform vast optimizations that ensure that the GC is almost never called yet memory is properly and fully reclaimed due to the bounds of the individual Actor heaps, and even when the GC is called it does not stop-the-world or anything of the sort and has multiple layers of GC's that run for specific cases, the system stays running even as the GC's (rarely) runs. The average GC run time even when it does run is measured in the single-digit 'micro'seconds. If anything the BEAM VM is not only just much older than the JVM and .NET VM's, but also more advanced.

Re: Elixir 1.5 released

#125

Earlier quoted context omitted.

Elm works very well with Elixir[0] [0] https://www.dailydrip.com/topics/elixirsips/drips/phoenix-an...

In what way does Elm work better with Phoenix than, say, with Rails or Django?

Not really any 'build' way, but the 'patterns' of it are more similar in that being immutable, functional, and single-owner languages.

Re: Elixir 1.5 released

#126

Is Elixir being used exclusively for web development? If not, what else are people using it for?

I'm at Tinfoil Security, and we use Elixir for dynamic security scanning of web applications and APIs. We also have some Phoenix apps, but the bulk of our Elixir use isn't in web development.

It's a very IO-bound problem (how many requests I can make while staying within rate limits / not taking down a service), so Elixir is a great fit for coordinating all of the concurrent work involved in security scanning.

Re: Elixir 1.5 released

#127

I highly recommend playing with Elixir or another purely functional language. I've only gone through the Programming Elixir book[1], but it has fundamentally challenged how I think about solving problems in other languages. [1]( https://pragprog.com/book/elixir13/programming-elixir-1-3 )

If you are interested in learning a purely functional language, I'd recommend against picking a dynamically typed language like Elixir. Functional programming only starts to show its power with types and parametric polymorphism (higher kinds, etc...). Without type annotations, all you get is a watered down, crippled version of what a functional language can achieve.

Yes, mis-typed when I typed purely functional. My intent was to lean closer towards mostly-functional languages than languages which _can_ be written in a functional style (a la JS or Ruby).

I should know better than to use the word "pure" on the internet, someone will always correct how inaccurate my usage is :)

Re: Elixir 1.5 released

#128

I highly recommend playing with Elixir or another purely functional language. I've only gone through the Programming Elixir book[1], but it has fundamentally challenged how I think about solving problems in other languages. [1]( https://pragprog.com/book/elixir13/programming-elixir-1-3 )

I've tried functional languages (Haskell) before and found them fun, but couldn't find a good project I can use them in. Can someone suggest a fun project, which can showcase the features of functional programming?

I don't like to think of a lot of these languages in terms of "functional". Haskell specifically does follow a functional paradigm, but Erlang/Elixir is more about the actor model and the functional aspects support that.

Re: Elixir 1.5 released

#129
post #30

Earlier quoted context omitted.

I wonder how the popularity trend of Elixir has been lately. I know you can try to see it through GitHub or Google Trends, but as many members of the Elixir community use Slack I don't know if it's the best way to do it. One thing I'd like to see would be the evolution of downloads of the language and on Hex.

Indeed.com trends[1] show Elixir interest (though not yet jobs) surpassing both Haskell and Clojure right about now, which I found surprising especially given how much newer it is [1] https://www.indeed.com/jobtrends/q-Erlang-q-Elixir-q-Haskell... (scroll down to 2nd chart)

on StackOveflow there are more Elixir jobs than Erlang but not Clojure

http://www.reallyhyped.com/?keywords=elixir%2Cerlang%2Ccloju...

Re: Elixir 1.5 released

#130

Elixir is truly an under-appreciated language. I've only toyed with it, and I'm really impressed with the whole ecosystem. Elixir, Phoenix, Ecto, Hex, etc all make a great ecosystem, and the awesomeness that is BEAM/OTP is just amazing. I loved the hot code deploys, and updating a system while it's running is something I've never seen before in action. Also Rustler is a great way to write CPU intensive NIF code too.

+1 for rustler. Writing NIFs (native implemented functions) in Rust can speed up your Elixir apps significantly. I think Rust & Elixir are a great duo.

I am super-stoked about the potential of Rust and Elixir, but there are some definite gotchas to be aware of. Especially if your Rust code is pretty expensive. Sonny Scroggin's talk about Rustler is really informative. https://www.youtube.com/watch?v=lSLTwWqTbKQ
Post reply on HN