<div dir="ltr"><div>Thanks for the clarification!</div><div><br></div><div>I understand that delayed results can't solve all cases. The question is if the amount of cases they do solve are plenty and if they are an appropriate solution. I am worried that a limited solution will give a false sense of security. Say your processes crash because of system overload. Then you add the delayed restart to give the system some time to recover. Are we sure it is going to be any effective without back-offs or jitters? When I faced similar issues, the answer was no.<br></div><div><br></div><div>So going with the lists:foldl/3 analogy, lists:foldl/3 is helpful because there is a huge variety of cases of where it does work. I am not personally convinced that's the case for delayed restarts. I am aware I am just one datapoint though. :)<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Jun 17, 2021 at 5:03 PM Maria Scott <<a href="mailto:maria-12648430@hnc-agency.org" target="_blank">maria-12648430@hnc-agency.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi Jose :)<br>
<br>
> I have to say, however, that I agree with Fred on this topic. Especially with the considerations that a restart_delay as an integer value is not enough. I would even say jitter is more important than backoff in many cases, and supporting both exponential backoffs and jitter will require more configuration and more complexity to be added to supervisors, while I also believe it belongs in the worker, as you gain a lot more flexibility. As one additional example to what Fred said, what if you want to accumulate requests while you wait for the connection to be established, and then issue the commands once it is ready? There are many other considerations that are only fully realizable in the worker.<br>
<br>
Well, yes, in those cases you simply can't do it with delayed restarts and they are a poor fit for the case at hand ^^;<br>
<br>
I guess what I'm trying to say is... as an analogy off the top of my head, there are many list-related things you can do with lists:foldl and foldr, but you can't do _everything_ with them, and you shouldn't _try_ to do everything with them for the only reason that they exist. For some things it is simply better to use explicit recursion, some things can't be done any other way. But that is not an argument for not having foldl/foldr, is it?<br>
<br>
Kind regards,<br>
Maria<br>
</blockquote></div>