
Elixir and Phoenix – hands-on introduction - dudul
http://phoenix.thefirehoseproject.com/
======
jhgg
For anyone jumping into Elixir/Erlang, here's a few great books you should
look into:

    
    
        * Learn You Some Erlang  http://learnyousomeerlang.com/
        * Erlang in Anger http://www.erlang-in-anger.com/
        * Programming Elixir 1.2 https://pragprog.com/book/elixir12/programming-elixir-1-2
    

For working with larger scale Elixir apps, a working knowledge on the erlang
vm/beam.smp & OTP is vital to your success!

~~~
vegabook
Actually, while I appreciate that "Programming Elixir" gets a lot of airtime,
owning both books I believe that "Elixir in Action" is a much better resource
than the former. "Programming Elixir" takes a pedantic, cover-all-bases, step-
by-step approach with many of the gotchas not obvious at first, while the
latter just dives in with idiomatic code and gets much more quickly to the
"jewels" of the language, namely that which benefits from BEAM/OTP.

Not to denigrate Dave Thomas, just to say that being first is not always best.
My personal experience, from an imperative background, is that the "Action"
book is more terse, but ultimately offers a cleaner schema of the language.

Side note: I love Elixir.

~~~
dudul
True enough, I have read both (actually the 1st edition of "Programming
Elixir"), and "Elixir in Action" is more hands-on. The reader ends up working
on an actual project along the book, adding new functionalities.

However, since Elixir 1.2, some of "Elixir in Action" is now outdated,
especially the use of HashDict replaced by Map.

I have not read the second edition of "Programming Elixir" though. Based on
the table of contents it seems to be a bit more "applied" than the previous
edition.

~~~
pselbert
There is a post from the author that documents what has diverged between
Elixir in Action and Elixir 1.2. More than simply updating code examples, it
actually gives context around all of the changes.

[http://theerlangelist.com/article/eia_elixir_12](http://theerlangelist.com/article/eia_elixir_12)

------
rafaqueque
After 2 months using Elixir in a big project for a big company, I must say
that I'm really enjoying what's going on. Some libraries are still young, but
other than that, the main ones work as expected.

~~~
dudul
It's really awesome to see that Elixir is actually being used in the "real
world". Do you mind sharing how you guys started using it? Did you start from
scratch or were you an erlang shop prior to using Elixir?

~~~
hnbroseph
there's a game company called undead labs that uses Elixir in production (per
[https://www.youtube.com/watch?v=iSTspCGn8C8](https://www.youtube.com/watch?v=iSTspCGn8C8)
)

~~~
shadeless
Here is a list of companies who are currently using Elixir in production:
[https://github.com/doomspork/elixir-
companies](https://github.com/doomspork/elixir-companies)

------
pmarreck
Elixir @ Pinterest, for anyone who missed it

[https://engineering.pinterest.com/blog/introducing-new-
open-...](https://engineering.pinterest.com/blog/introducing-new-open-source-
tools-elixir-community)

Also, just noticed that a relatively new but nice-seeming screen sharing app
called CrankWheel put out a talk covering their realtime Erlang/Elixir-backed
architecture:
[https://www.youtube.com/watch?v=6RGCPkdJBjI](https://www.youtube.com/watch?v=6RGCPkdJBjI)

~~~
sinatra
Thank you for sharing this. If you are open to some constructive feedback, I'd
say - The best help that Elixir can get at this moment is endorsements /
detailed-examples from large and respected companies. That will help a lot of
developers convince themselves and their teams that Elixir is ready to be
considered seriously. So, although the brief mention (and some data) that
Pinterest is using Elixir for Pinterest API and Ads API was helpful, more
details about how Pinterest is using it and more details about what benefits
it's getting because of that would help Elixir and its future users a lot!

~~~
pmarreck
The advantages are quite tangible, apparently (the best kind of argument,
frankly). To excerpt some metrics from that link:

"So, we like Elixir and have seen some pretty big wins with it. The system
that manages rate limits for both the Pinterest API and Ads API is built in
Elixir. Its 50 percent response time is around 500 microseconds with a 90
percent response time of 800 microseconds. Yes, microseconds (millionths of a
second). ...We’ve also seen an improvement in code clarity. We’re converting
our notifications system from Java to Elixir. The Java version used an Actor
system and weighed in at around 10,000 lines of code. The new Elixir system
has shrunk this to around 1000 lines. The Elixir based system is also faster
and more consistent than the Java one and runs on half the number of servers."

I'm not the kind of person to regularly use the exclamation, but I couldn't
help saying "holy shit!" aloud when I first read that.

~~~
nuggien
Are you referring to the LOC or the response times? If you're talking about
the response times, then it totally depends on what the system was doing.
Microsecond response times are achievable in any language, if e.g. you never
had to talk to any external resources.

~~~
pmarreck
I guess it was for all of it. From a Rails background, those response times
are quite impressive, but you are correct.

------
eggy
I am studying Elixir/Phoenix, and I am paralleling this with LFE (Lisp
Flavored Erlang), a lisp front end to the Erlang compiler, created by Robert
Virding, co-creator of Erlang. It seems like Elixir has the lion's share of
popularity for the foreseeable future, but there are some differences to the
approaches taken between the two besides syntax, and I am not choosing for
work, since I do not make my living coding. See this response by Robert on
being able to change the meaning of the Elixir constructs, but not actually
add new functions, operators, etc... as can be done with a lisp, and therefore
LFE [1]. I am also excited about how Pony for concurrency and messaging may
address similar solutions[2].

    
    
      [1]  https://groups.google.com/forum/#!topic/lisp-flavoured-erlang/ensAkzcEDQQ
      [2]  http://www.ponylang.org/

------
yumaikas
This is a pretty nice tutorial, but it's for an out of date version of phoenix
(0.8), and phoenix is currently on version 1.1.4

~~~
jdp23
I had the same reaction. Are there any newer tutorials people would recommend?

~~~
chrismccord
The guides at phoenixframework.org and the just finished Programming Phoenix
book are your best bets:

* (free) [http://www.phoenixframework.org/](http://www.phoenixframework.org/)

* (paid) [https://pragprog.com/book/phoenix/programming-phoenix](https://pragprog.com/book/phoenix/programming-phoenix)

~~~
jdp23
Thanks!

------
rossta
Anyone interested in learning/speaking about Elixir and/or Phoenix should
check out Empire City Elixir Conf, coming to New York City in May
[http://empex.co](http://empex.co) (I'm a co-organizer)

------
fishnchips
Just as I was starting an Elixir study group at work ;) Looks like this will
be a very useful resource. Thanks!

