Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
A Brief Introduction to Elixir
Search
Iuri Fernandes
March 11, 2016
Technology
0
99
A Brief Introduction to Elixir
Lightning talk presented in DaWanda
Iuri Fernandes
March 11, 2016
Tweet
Share
More Decks by Iuri Fernandes
See All by Iuri Fernandes
Comredis
iurifq
1
95
Phoenix channels introduction
iurifq
0
110
Git - Dicas e boas práticas
iurifq
0
740
Vim
iurifq
1
140
Other Decks in Technology
See All in Technology
Proxmox × HCP Terraformで始めるお家プライベートクラウド
lamaglama39
1
200
Claude Code 10連ガチャ
uhyo
3
680
それでは聞いてください「Impeller導入に失敗しました」 #FlutterKaigi #skia
tacck
PRO
0
110
[mercari GEARS 2025] Keynote
mercari
PRO
0
230
JAWS-UG SRE支部 #14 LT
okaru
0
100
仕様は“書く”より“語る” - 分断を超えたチーム開発の実践 / 20251115 Naoki Takahashi
shift_evolve
PRO
1
810
Pythonで構築する全国市町村ナレッジグラフ: GraphRAGを用いた意味的地域検索への応用
negi111111
8
3.5k
データとAIで未来を創るDatabricks - 君の可能性を加速させるプラットフォーム
taka_aki
0
110
エンタープライズ企業における開発効率化のためのコンテキスト設計とその活用
sergicalsix
1
390
ユーザーストーリー x AI / User Stories x AI
oomatomo
0
190
QAを"自動化する"ことの本質
kshino
1
120
X-Ray SDKとDaemonのサポート終了と移⾏ガイド
o11yfes2023
0
100
Featured
See All Featured
Producing Creativity
orderedlist
PRO
348
40k
How to Ace a Technical Interview
jacobian
280
24k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
21
1.2k
Learning to Love Humans: Emotional Interface Design
aarron
274
41k
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.5k
Bootstrapping a Software Product
garrettdimon
PRO
307
110k
Intergalactic Javascript Robots from Outer Space
tanoku
273
27k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
10
660
Navigating Team Friction
lara
190
15k
GraphQLの誤解/rethinking-graphql
sonatard
73
11k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
33
1.8k
Build The Right Thing And Hit Your Dates
maggiecrowley
38
2.9k
Transcript
Iuri Fernandes A Brief Introduction to Elixir
Elixir! • Runs on Erlang VM • Cool language •
But before…
The problem • Telecommunications • Fast • Fault tolerant •
Distributed
Erlang and Telecom • Designed for telecom problems • OTP(Open
Telecom Platform)
Slide from José Valim’s presentations
Slide from José Valim’s presentations
BEAM • Erlang VM • Processes are units of computation
• Message passing FTW
Image from “Learn you some Erlang for great good” licensed
under Creative Commons Messages
OTP • Framework • Concurrent and distributed applications • Models
behaviors for processes • And much more …
OTP Examples Image from “Learn you some Erlang for great
good” licensed under Creative Commons
Image from “Learn you some Erlang for great good” licensed
under Creative Commons OTP Examples
Image from “Learn you some Erlang for great good” licensed
under Creative Commons OTP Examples
Elixir • Created in 2012 by José Valim • Functional
(Immutability) • Dynamically typed • Metaprogramming • Fresh life to Erlang ecosystem • BEAM VM
Drops of Elixir defmodule MyModule do def increment(argument) do argument
+ 1 end end defmodule PatternMatching do def head([]), do: nil def head([head | _]), do: head end
Drops of Elixir defmodule MyModule do def increment(x) when is_integer(x)
do x + 1 end end defmodule PatternMatching do def head([]), do: nil def head([head | _]), do: head end
Drops of Elixir parent = self() # Spawns an Elixir
process (not an operating system one!) spawn_link(fn -> send parent, {:msg, "hello world"} end) # Block until the message is received receive do {:msg, contents} -> IO.puts contents end
Drops of Elixir defmodule Stack do use GenServer # Callbacks
def handle_call(:pop, _from, [h|t]) do {:reply, h, t} end def handle_cast({:push, item}, state) do {:noreply, [item|state]} end end
Drops of Elixir # Start the server {:ok, pid} =
GenServer.start_link(Stack, [:hello]) # This is the client GenServer.call(pid, :pop) #=> :hello GenServer.cast(pid, {:push, :world}) #=> :ok GenServer.call(pid, :pop) #=> :world
Applications • Chat web app with Phoenix • Embedded systems
with Nerves • Pusher app replacement with Poxa
https://github.com/doomspork/elixir-companies Who uses it
None
None
Questions?