Squidie.Runtime.Routing (squidie v0.3.4)

Copy Markdown View Source

Resolves public runtime/read-model choices into journal boundary options.

The public Squidie facade owns workflow operations. This module owns the lower-level routing rules that turn host configuration and explicit overrides into validated runtime, read-model, and journal option sets.

Summary

Functions

Builds journal options for child workflow starts.

Builds journal options for control commands such as cancel, resume, and replay.

Builds journal options for claiming and executing visible work.

Builds journal projection options used by run listing.

Builds journal options for runtime-authored workflow spec starts.

Builds journal options for module-authored workflow starts.

Resolves the journal storage adapter from overrides or inferred config.

Builds journal projection options used by single-run inspection.

Validates public child-start overrides before they reach the journal boundary.

Validates public dynamic-work overrides before they reach the journal boundary.

Validates public execution overrides.

Resolves the configured read model from explicit overrides or app config.

Rejects internal-only start options from public manual-start APIs.

Resolves the configured runtime from explicit overrides or app config.

Functions

journal_child_start_options(overrides)

@spec journal_child_start_options(keyword()) :: keyword()

Builds journal options for child workflow starts.

journal_control_options(overrides)

@spec journal_control_options(keyword()) :: keyword()

Builds journal options for control commands such as cancel, resume, and replay.

journal_execute_options(overrides)

@spec journal_execute_options(keyword()) :: keyword()

Builds journal options for claiming and executing visible work.

journal_list_options(overrides)

@spec journal_list_options(keyword()) :: keyword()

Builds journal projection options used by run listing.

journal_spec_start_options(overrides)

@spec journal_spec_start_options(keyword()) :: keyword()

Builds journal options for runtime-authored workflow spec starts.

journal_start_options(overrides)

@spec journal_start_options(keyword()) :: keyword()

Builds journal options for module-authored workflow starts.

journal_storage(overrides)

@spec journal_storage(keyword()) :: {:ok, term()} | {:error, term()}

Resolves the journal storage adapter from overrides or inferred config.

projection_snapshot_options(overrides)

@spec projection_snapshot_options(keyword()) :: keyword()

Builds journal projection options used by single-run inspection.

public_child_start_options(opts)

@spec public_child_start_options(keyword()) :: :ok | {:error, term()}

Validates public child-start overrides before they reach the journal boundary.

public_dynamic_work_options(opts)

@spec public_dynamic_work_options(keyword()) :: :ok | {:error, term()}

Validates public dynamic-work overrides before they reach the journal boundary.

public_execute_options(opts)

@spec public_execute_options(keyword() | term()) :: :ok | {:error, term()}

Validates public execution overrides.

read_model(overrides)

@spec read_model(keyword()) :: {:ok, :read_model} | {:error, term()}

Resolves the configured read model from explicit overrides or app config.

reject_public_start_options(overrides)

@spec reject_public_start_options(keyword()) :: :ok | {:error, term()}

Rejects internal-only start options from public manual-start APIs.

runtime(overrides)

@spec runtime(keyword()) :: {:ok, :journal} | {:error, term()}

Resolves the configured runtime from explicit overrides or app config.