SquidMesh.Config (squid_mesh v0.1.0-alpha.3)

Copy Markdown View Source

Loads and validates host application configuration for Squid Mesh.

This contract is intentionally small so application teams only configure the runtime boundary once, while workflow authors stay focused on declarative workflow definitions and public API usage.

Summary

Types

config_error()

@type config_error() :: {:missing_config, [atom()]} | {:invalid_config, keyword()}

execution_option()

@type execution_option() ::
  {:name, module() | atom()}
  | {:queue, atom()}
  | {:stale_step_timeout, stale_step_timeout()}

raw_config()

@type raw_config() :: [repo: module(), execution: [execution_option()] | nil]

stale_step_timeout()

@type stale_step_timeout() :: non_neg_integer() | :disabled

t()

@type t() :: %SquidMesh.Config{
  execution_name: module() | atom(),
  execution_queue: atom(),
  repo: module(),
  stale_step_timeout: stale_step_timeout()
}

Functions

load(overrides \\ [])

@spec load(keyword()) :: {:ok, t()} | {:error, config_error()}

load!(overrides \\ [])

@spec load!(keyword()) :: t()