Packages
SuperWorker is a powerful Elixir library for working with supervisors and background jobs. It provides a much simpler approach than traditional supervisors. This library is currently under development and is unstable, so it is not recommended for production use.
Current section
Files
Jump to
Current section
Files
lib/sup_manager/sup_manager.ex
defmodule SuperWorker.Supervisor.Manager do
@doc false
use GenServer
alias __MODULE__
require Logger
### Public API
def start_link(opts \\ []) do
GenServer.start_link(Manager, opts, name: __MODULE__)
end
### Callbacks
@impl true
def init(_elements) do
Logger.info("SuperWorker, Manager, init")
{:ok, %{}}
end
@impl true
def terminate(_reason, _state) do
Logger.info("SuperWorker, Manager, terminate")
:ok
end
end