aife/lib/aife/drone/supervisor.ex

17 lines
376 B
Elixir

defmodule Aife.Drone.Supervisor do
use Supervisor
def start_link(_) do
Supervisor.start_link(__MODULE__, [])
end
def init(_) do
children = [
{Registry, name: Aife.Drone.Registry, keys: :unique},
{DynamicSupervisor, name: Aife.Drone.DynamicSupervisor, strategy: :one_for_one}
]
Supervisor.init(children, strategy: :one_for_one)
end
end