Search⌘ K
AI Features

Start the Supervision Tree

Explore how to start a supervision tree in Elixir by configuring the top-level supervisor to manage GameSupervisor and Registry processes. Understand how supervision trees enable process recovery and keep your application reliable as new games start dynamically.

Looking into GameSupervisor

Supervisor processes can do their job only if they are running. We can’t know in advance when a player is going to start a new game, so we need to make sure that the GameSupervisor is running as soon as the application starts. That’s what we’ll focus on in this section.

We mentioned that since supervisors can supervise both workers and other supervisors, they can form trees of supervised processes. This ...