Arcana.TaskSupervisor (Arcana v3.0.1)

Copy Markdown View Source

Deprecated alias for ArcanaWeb.TaskSupervisor.

The task supervisor only serves the dashboard's async operations, so it lives under the ArcanaWeb namespace now. Update your children list to ArcanaWeb.TaskSupervisor.

Two things carried the old name. Only the first one still works:

  • listing this module in a supervision tree, via child_spec/1 here, which keeps working for the deprecation window
  • Task.Supervisor.start_child(Arcana.TaskSupervisor, fun), which resolves the atom as a registered process name rather than calling anything on this module, and does not work and cannot be made to

A process may hold only one registered name, and the supervisor already holds the new one, so it cannot answer to the old one as well:

Process.register(pid, ArcanaWeb.TaskSupervisor)
true

Process.register(pid, Arcana.TaskSupervisor)
** (ArgumentError) could not register #PID<...> ... it has already been
   given another name

Update those call sites to ArcanaWeb.TaskSupervisor. This module going away in a future release only affects the supervision-tree usage.

Summary

Functions

child_spec(opts)

This function is deprecated. Use ArcanaWeb.TaskSupervisor instead.

start_child(fun)

This function is deprecated. Use ArcanaWeb.TaskSupervisor.start_child/1 instead.

See ArcanaWeb.TaskSupervisor.start_child/1.