Hourglass.NamespaceEnsurer (hourglass v0.1.0)

Copy Markdown View Source

Boot-time supervisor child that ensures the configured Temporal namespace exists. Returns :ignore from start_link/0 so no process is kept around after the check; the supervisor's child-startup ordering guarantees later children (notably Hourglass.Subsystem, which hosts Workers) don't start until this succeeds.

Crashes the boot supervisor on connect failure or namespace-register failure. Operators see the real error instead of silently-broken workers spinning on :worker_not_registered.

Reads :target_url and :namespace from Application.get_env(:hourglass, Hourglass.Client), falling back to the same defaults as Hourglass.Client.connect/1.

Summary

Functions

child_spec(opts)

@spec child_spec(term()) :: Supervisor.child_spec()

start_link()

@spec start_link() :: :ignore | {:error, term()}