Join us on:

T16. Practical Erlang Programming

Francesco Cesarini, ErlangTraining and Consulting

Practical Erlang Programming covers the basic, sequential and concurrent aspects of the Erlang programming language. You will learn the basics of how to read, write and structure Erlang programs. The target audience are software developers and engineers with an interest in server side applications and massively concurrent systems.

The goal of this tutorial is a hands-on introduction to the theory and concepts behind sequential and concurrent Erlang programming, explaining the Erlang syntax, semantics and concurrency model. We conclude with an overview of the error handling mechanisms used to build fault tolerant systems with five nines availability.

In order to get the most out of this tutorial, you must have a good grasp of other programming languages.


The contents of the tutorial will include:

Basic Erlang 1 hour

This section deals with Erlang data types and pattern matching. Functions, modules, and BIFs are discussed. Before the exercises, the Erlang shell, useful shell commands as well as Emacs and its Erlang mode are introduced.

Sequential Programming 1 hour

The Sequential Programming section comprehends conditional evaluations, guards and scope of variables. It then introduces recursion, with a special emphasis on different recursive patterns, tail recursion, and space saving optimizations. Before the exercises, libraries and their manual pages, possible run time errors and the debugger are demonstrated.

Concurrent Programming 1 hour

This section describes the creation of processes and their life span. It looks at sending and receiving messages, selective reception, and passing data in the messages. It continues with the various uses of time outs and registering processes, and terminates by showing the generic process code structure. Before the exercises, a demonstration of the Process Manager tool is given.

Process Error Handling 30 minutes

This section introduces the simple but powerful error handling mechanisms in processes. It looks at process links, exit signals and their propagation semantics. How robust systems are built in Erlang are discussed, and an example from the Process Design Patterns section is re-implemented, making it robust.


This will be a hands on tutorial. Make sure you come with your laptop having installed Erlang and your favourite editor.

Audience: Practitioners
Please email any questions to . This e-mail address is being protected from spambots. You need JavaScript enabled to view it