elixir-todo-list/lib/todo/system.ex

20 lines
304 B
Elixir
Raw Permalink Normal View History

2024-08-07 08:21:57 +02:00
defmodule Todo.System do
use Supervisor
def start_link do
Supervisor.start_link(__MODULE__, nil)
end
2024-08-07 10:03:31 +02:00
@impl Supervisor
2024-08-07 08:21:57 +02:00
def init(_) do
Supervisor.init(
2024-08-07 10:03:31 +02:00
[
Todo.ProcessRegistry,
Todo.Database,
Todo.Cache
],
2024-08-07 08:21:57 +02:00
strategy: :one_for_one
)
end
end