Defines the stable, typed failures returned by Periodical.
Every failure carries a machine-readable :code, a fixed human-readable
:message, and free-form :details describing the specific occurrence. The
code is the stable part: match on it rather than on message text.
Each code has a constructor of the same name:
iex> error = Periodical.Error.overloaded(%{limit: 100})
iex> {error.code, error.details}
{:overloaded, %{limit: 100}}
Summary
Functions
Returns every code this module defines, for exhaustiveness checks.
Builds the :dependency_unavailable error: A configured optional dependency is unavailable.
Builds the :drain_timeout error: Scheduler drain deadline expired.
Builds the :duplicate_name error: A schedule with this name already exists.
Builds the :invalid_config error: Periodical configuration is invalid.
Builds the :invalid_schedule error: Schedule definition is invalid.
Builds the :overloaded error: Schedule capacity has been reached.
Builds the :schedule_not_found error: Schedule was not found.
Builds the :shutting_down error: Scheduler is shutting down.
Types
Functions
@spec codes() :: [atom()]
Returns every code this module defines, for exhaustiveness checks.
Builds the :drain_timeout error: Scheduler drain deadline expired.
Builds the :duplicate_name error: A schedule with this name already exists.
Builds the :invalid_config error: Periodical configuration is invalid.
Builds the :invalid_schedule error: Schedule definition is invalid.
Builds the :overloaded error: Schedule capacity has been reached.
Builds the :schedule_not_found error: Schedule was not found.
Builds the :shutting_down error: Scheduler is shutting down.