class Concurrent::Supervisor
def rest_for_one
def rest_for_one restart = false @workers.each do |context| if restart terminate_worker(context) elsif context.needs_restart? raise MaxRestartFrequencyError if exceeded_max_restart_frequency? restart = true end end one_for_one if restart end