Regc.Error exception (regc v0.0.2)

View Source

Structured failure returned by generalized registry and storage operations.

Expected protocol and registry failures are returned as {:error, error} tuples rather than raised.

Summary

Types

t()

@type t() :: %Regc.Error{
  __exception__: term(),
  cause: term(),
  code: atom() | nil,
  details: map(),
  digest: String.t() | nil,
  message: String.t() | nil,
  metadata: map(),
  method: atom() | nil,
  operation: atom() | nil,
  reference: term(),
  retryable?: boolean(),
  stage: atom() | nil,
  status: non_neg_integer() | nil,
  url: String.t() | nil
}

Functions

new(stage, code, message, opts \\ [])

@spec new(atom(), atom(), String.t(), keyword()) :: t()

result(stage, code, message, opts \\ [])

@spec result(atom(), atom(), String.t(), keyword()) :: {:error, t()}