Re:Add detailed message to NullPointerException describing w...
by bunderbunder on Tuesday March 26, 2019 @03:33PM
(#19495254)
The fact that anyone ever thought it would be worthwhile to implement an optimization like this is very telling.
I'm not exactly sure what it tells us, but it definitely tells us something.
Unfortunately, the JVM has special code to detect this case (!) and stop recording the stack trace after a while (!!). Then when you go look at your log to see why the system isn't working, you see only `NullPointerException` without the expected stack trace, and you have to guess where it's coming from (after wondering for a few hours why the stack trace went missing, only to find the explanation at https://stackoverflow.com/questions/2411487/nullpointerexcep...).