Elixir by Example
A hands-on tour of Elixir, OTP and
distributed systems through small, annotated programs, from your first
IO.puts
to supervised, concurrent services.
Core Elixir
The language itself: data, pattern matching, functions, modules and protocols.
- Hello World
- Values
- Atoms
- Strings
- Binaries and Bitstrings
- Lists and Tuples
- Maps
- Keyword Lists
- Pattern Matching
- case, cond and if
- Anonymous Functions
- Modules and Named Functions
- Guards
- Recursion
- The Pipe Operator
- Enum
- Comprehensions
- Streams
- Erlang Data Structures
- Structs
- Typespecs and Types
- Protocols and Behaviours
- with
- Errors and Exceptions
- Sigils
- From Source to BEAM
- Mix Projects
- Testing with ExUnit
Processes and OTP
Concurrency the BEAM way: lightweight processes, messages, and supervision.
Distributed Elixir
Many machines, one system: connected nodes, cluster-wide names and process groups.
Deployment
From your laptop to servers: releases, runtime configuration, containers and clusters.
Production
Running it: look inside a live node, find what is slow or leaking, read crash dumps, and change code without a restart.
- Hot Code Loading
- Tracing
- Memory: Copies and Binaries
- Mailboxes and Slow Consumers
- Load Shedding
- Schedulers and Reductions
- Profiling
- Crash Dumps
- Letting Agents Debug Production
Project Operate the store
Reliability
Keeping data right when steps fail: transactions, the outbox pattern and sagas, and a store that protects itself under load.