Reactor.Process.Step.StartChild (reactor_process v0.4.2)

View Source

Adds a child specification to a supervisor and starts that child.

See the documentation for Supervisor.start_child/2 for more information.

Arguments

  • :supervisor - Required. The supervisor to query

  • :child_spec - Required. The child spec

Options

  • :module (module/0) - The module to use. Must export count_children/1 The default value is Supervisor.

  • :fail_on_already_present? (boolean/0) - Whether the step should fail if the child spec is already present in the supervisor The default value is true.

  • :fail_on_already_started? (boolean/0) - Whether the step should fail if the start function returns an already started error The default value is true.

  • :terminate_on_undo? (boolean/0) - Whether to terminate the started process when the Reactor is undoing changes The default value is true.

  • :termination_reason (term/0) - The reason to give to the process when terminating it The default value is :kill.

  • :termination_timeout (timeout/0) - How long to wait for a process to terminate The default value is 5000.