Questions tagged [simple-one-for-one]

simple_one_for_one is a Supervisor strategy used in Erlang/Elixir to allow dynamically added instances of the same process

A supervisor with restart strategy simple_one_for_one is a simplified one_for_one supervisor, where all child processes are dynamically added instances of the same process.

see simple_one_for_one

2 questions
10
votes
1 answer

simple_one_for_one start_child() returns already_started

I have a supervisor which should start simple_one_for_one workers. When I call start_child() for the first time, everything goes excellent. But, when I do it the second time, I get {error,{already_started,<0.71.0>}}. Why would simple_one_for_one…
dijxtra
  • 2,681
  • 4
  • 25
  • 37
3
votes
2 answers

Simple_one_for_one application

I have a supervisor which starts simple_one_for_one children. Each child is in fact a supervisor which has its own tree. Each child is started with an unique ID, so I can distinguish them. Each gen_server is then started with start_link(Id),…
dijxtra
  • 2,681
  • 4
  • 25
  • 37