News for hackers. Stuff that matters.
Re:Cloudflare outage on November 18, 2025 post mortem by never_inline on Tuesday November 18, 2025 @11:57PM (#45976011)
The dislike is probably because of 2 reasons.

1. in most cases they don't want to handle `InterruptedException` or `IOException` and yet need to bubble them up. In that case the code is very verbose.

2. it makes lambdas and functions incompatible. So eg: if you're passing a function to forEach, you're forced to wrap it in runtime exception.

3. Due to (1) and (2), most people become lazy and do `throws Exception` which negates most advantages of having exceptions in the first place.

In line-of-business apps (where Java is used the most), an uncaught exception is not a big deal. It will bubble up and gets handled somewhere far up the stack (eg: the server logger) without disrupting other parts of the application. This reduces the utility of having every function throw InterruptedException / IOException when those hardly ever happen.

Re:Cloudflare outage on November 18, 2025 post mortem by dehrmann on Wednesday November 19, 2025 @01:55AM (#45976600)
> 2. it makes lambdas and functions incompatible.

This is true, but the hate predated lambdas in Java.

Re:Cloudflare outage on November 18, 2025 post mortem by ErikCorry on Wednesday November 19, 2025 @04:34AM (#45977593)
You could always manually build the same thing as lambda with a class and you had the same problem.
Re:Cloudflare outage on November 18, 2025 post mortem by frumplestlatz on Wednesday November 19, 2025 @04:30AM (#45977560)
> an uncaught exception is not a big deal

In my experience, it actually is a big deal, leaving a wake of indeterminant state behind after stack unrolling. The app then fails with heisenbugs later, raising more exceptions that get ignored, compounding the problem.

People just shrug off that unreliability as an unavoidable cost of doing business.

Re:Cloudflare outage on November 18, 2025 post mortem by loglog on Wednesday November 19, 2025 @07:06AM (#45978582)
Java checked exceptions suffer from a lack of generic exception types ("throws T", where T can be e.g. "Exception", "Exception1|Exception2", or "never") This would also require union types and a bottom type. Without generics, higher order functions are very hard to use.