[erlang-questions] one-for-one supervisor with concurrent start/shutdown
Sat Sep 21 21:57:03 CEST 2019
OTP implements sequential start/shutdown procedure for rest_for_one
and all_for_one supervisors, assuming there are dependencies between
children. It requires startup/termination order.
simple_one_for_one implements concurrent shutdown. Startup is
sequential due to the dynamic nature of this strategy.
one_for_one supervisor implements sequential startup and shutdown. Is
there any way to do it concurrently? Children are supposed to be
independent of each other.
Concurrent shutdown is easy to add, it's already done for
simple_one_for_one. But startup is implemented as MFA callback, with
no message protocol.
proc_lib has message protocol internally, but not all children may follow it.
Would it make sense to have yet another restart strategy (I'd name it
More information about the erlang-questions