logoalt Hacker News

ramchiplast Sunday at 4:42 AM2 repliesview on HN

I recommend https://ferd.ca/the-zen-of-erlang.html starting from "if my configuration file is corrupted, restarting won't fix anything". The tl;dr is it helps with transient bugs.


Replies

bccdeelast Sunday at 3:30 PM

> if you feel that your well-understood regular failure case is viable, then all your error handling can fall-through to that case.

This is my favourite line, because it generalizes the underlying principle beyond the specific BEAM/OTP model in a way that carries over well to the more common sort of database-backed services that people tend to write.

kimilast Sunday at 7:13 AM

...and does no harm for unfixable bugs. It's the logical equivalent of "switch off and on again" that as we know fixes most issues by itself, but happening only on a part of your software deployment, so most of it will keep running.