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
Phoenix for Rubyists
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
Doug Goldie
August 26, 2018
Programming
32
0
Share
Phoenix for Rubyists
Introduction to Elixir and Phoenix
Doug Goldie
August 26, 2018
More Decks by Doug Goldie
See All by Doug Goldie
Phoenix for Rubyists with notes
dgoldie
0
41
Other Decks in Programming
See All in Programming
開発とはなにか、Essenceカーネルで見えるもの
ukin0k0
0
140
Lightning-Fast Method Calls with Ruby 4.1 ZJIT / RubyKaigi 2026
k0kubun
3
2.8k
実用!Hono RPC2026
yodaka
2
310
Back to the roots of date
jinroq
0
800
WebAssembly を読み込むベストプラクティス 2026年春版 / Best Practices for Loading WebAssembly (Spring 2026)
petamoriken
5
1.1k
空間オーディオの活用
objectiveaudio
0
150
ふにゃっとしない名前の付け方 〜哲学で茹で上げる、コシのあるソフトウェア設計〜
shimomura
0
120
SREに優しいTerraform構成 modulesとstateの組み方
hiyanger
2
170
Spec Driven Development | AI Summit Vilnius
danielsogl
PRO
1
150
【ディップ|26年新卒研修資料】OpenAPI/Swagger REST API研修
dip_tech
PRO
0
150
When benchmarks go bad - what I learned from measuring performance wrong
hollycummins
0
380
要はバランスからの卒業 #yumemi_grow
kajitack
0
130
Featured
See All Featured
How to Align SEO within the Product Triangle To Get Buy-In & Support - #RIMC
aleyda
2
1.5k
How GitHub (no longer) Works
holman
316
150k
Ten Tips & Tricks for a 🌱 transition
stuffmc
0
110
VelocityConf: Rendering Performance Case Studies
addyosmani
333
25k
Side Projects
sachag
455
43k
Prompt Engineering for Job Search
mfonobong
0
300
Leo the Paperboy
mayatellez
7
1.8k
Lightning Talk: Beautiful Slides for Beginners
inesmontani
PRO
1
540
Visual Storytelling: How to be a Superhuman Communicator
reverentgeek
2
530
Testing 201, or: Great Expectations
jmmastey
46
8.1k
How to build an LLM SEO readiness audit: a practical framework
nmsamuel
1
740
Amusing Abliteration
ianozsvald
1
160
Transcript
Phoenix for Rubyists Concurrency and Scalability with Productivity by Doug
Goldie Code Cauldron
Bunny Trails Learning something new…. Why are you here?
New Language/Framework Scalability Concurrency Multicore machines Productivity of Rails
Moore’s Law is Dead! number of transistors in a dense
integrated circuit doubles approximately every two years. We are seeing more multi-core machines with more cores.
What do we build? Any Web Applications Distributed Systems But
we still want productivity
Today Phoenix Elixir Erlang
Web Applications Classic CRUD monolith Single page app (SPA) -
with any frontend Realtime app productivity and performance.
Distributed Systems Large-Scale distributed, fault-tolerant system Phoenix as the Web
component Elixir for the other components. Small distributed apps. productivity and performance.
Agenda Elixir in 10 minutes Basic Phoenix app Real-time app
Distributed systems Some really contrarian, disruptive ideas !!
Elixir
Elixir in 10 minutes placeholder
Basic Web Application
Phoenix demo Classic Rails example
Real-time Application
Real-time Features Phoenix Channels Topics Elixir & Erlang Massive concurrency
Actor model Processes
Processes • lightweight, small memory, fast to create and terminate
• message passing • no shared data • links and monitors • error handling Erlang is designed for massive concurrency
None
Chat demo Classic real-time example Phoenix channels / topics presence
http://work.stevegrossi.com/2016/07/11/building-a- chat-app-with-elixir-and-phoenix-presence/
Distributed Systems
HTTP Server Nginx and Phusion Passenger Request processing Ruby on
Rails Long-running requests Go Server-wide state Redis Persistable data Redis / MongoDB Background jobs Cron, Bash scripts, and Ruby Service crash recovery Upstart Erlang Erlang Erlang Erlang Erlang Erlang Erlang Server A Server B
None
Hard Problem to Solve
with only 10 engineers! In 2014, sold for $19 Billion.
465 million users 550 servers
Erlang History Developed over 25 years ago by Ericsson for
building Telcom products Released as open source in 1998.
Requirements • high concurrency • distribution • fault tolerant •
soft realtime • high availability • external interfaces • hot code upgrade
Processes • lightweight, small memory, fast to create and terminate
• message passing • no shared data • links and monitors • error handling Erlang is designed for massive concurrency
Scheduler
OTP Library of Design Patterns Behaviors Client Server Supervisors and
Workers
Gen Server
Lifecycle of GenServer
Fault-tolerance
None
Quotes “Best kept secret in software” - Evan Miller,
author of Chicago Boss “Erlang is about building Systems” - Robert Virding “Erlang makes the easy things hard and the hard things easy”
Umbrella demo Phoenix and Elixir have Umbrella apps. Separate Applications
in one repo.
Disruptive Ideas Service-Oriented Architectures MicroServices Web Services: json Front-end Frameworks?
Are there better ways?
Review
Erlang review • massive concurrency • Processes • OTP •
Virtual Machine (BEAM)
Elixir review • BEAM (Erlang VM) • modern syntax •
macros • tooling • community • documentation
Phoenix review • pipelines • changesets • contexts • channels/topics
• umbrella apps