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
|