Ambient.ProcessOverride.Server (Ambient v0.1.0)

Copy Markdown View Source

Owns one ETS table for Ambient.ProcessOverride and monitors every PID that writes an override into it. On :DOWN, the owning rows and any {:allow, …} rows pointing at the dead PID are cleared.

Start one instance per override table from test/test_helper.exs – usually via Ambient.start_servers/1 rather than calling this directly. Not part of the production supervision tree.

{:ok, _} = Ambient.ProcessOverride.Server.start_link(table: :ambient_clock_overrides)

Summary

Functions

Returns a specification to start this module under a supervisor.

Start a Server that owns :table and registers itself under ProcessOverride.server_name(table).

Functions

child_spec(init_arg)

Returns a specification to start this module under a supervisor.

See Supervisor.

start_link(opts)

@spec start_link(keyword()) :: GenServer.on_start()

Start a Server that owns :table and registers itself under ProcessOverride.server_name(table).

Raises in builds that didn't opt into overrides – creating the table is what makes them reachable, so it's gated at compile time along with the writers. See Ambient.ProcessOverride.