39 ms·
A lot of opinions about error handling in this thread, but I don't see the main thing mentioned: difference in requirements of different projects and subsequent
by golergka 10y ago
A lot of opinions about error handling in this thread, but I don't see the main thing mentioned: difference in requirements of different projects and subsequent difference in technical strategies.
Some applications need to fail fast, fail hard, and restart automatically.
Some applications need to present any failure or error condition to the user and give him power to decide.
Some applications need to be restored to some sensible state at all cost.
Needless to say, all possible error handling strategies, from C return codes to Java checked exceptions, have their fair use cases; discussing which one is better and which one is worse without specific project in mind, at least as an example, is completely pointless.