SuperWorker.Supervisor.Chain (SuperWorker v0.3.6)
View SourceDocumentation for SuperWorker.Supervisor.Chain.
Summary
Types
@type t() :: %SuperWorker.Supervisor.Chain{ finished_callback: nil | {:fun, fun()} | {module(), atom(), [any()]}, id: any(), partition_pid: term(), queue_length: non_neg_integer(), restart_strategy: atom(), send_type: :broadcast | :random | :partition | :round_robin, supervisor: atom(), table: atom() }
Functions
@spec add_worker(t(), SuperWorker.Supervisor.Worker.t()) :: {:error, :already_exists} | {:ok, t()}
@spec get_all_workers(t()) :: {:ok, [SuperWorker.Supervisor.Worker.t()]}
@spec get_worker(t(), any()) :: {:error, :worker_not_found} | {:ok, SuperWorker.Supervisor.Worker.t()}