Ambient.Supervisor (Ambient v0.1.0)

Copy Markdown View Source

Supervises the per-table Ambient.ProcessOverride.Server processes.

Started (and populated) by Ambient.start_servers/1. Running the servers under a supervisor means a Server crash is restarted and logged rather than silently dropping its ETS table (which would make every override for that table fall through to real values with no test failure). The supervisor also contains the crash, so it doesn't propagate to the test runner.

A restart recreates an empty table – in-flight overrides for that table are lost, but the table is immediately available again for subsequent tests.

Summary

Functions

Returns a specification to start this module under a supervisor.

Functions

child_spec(arg)

Returns a specification to start this module under a supervisor.

See Supervisor.

start_link(init_arg \\ [])

@spec start_link(term()) :: Supervisor.on_start()