RFR: 8066859: java/lang/ref/OOMEInReferenceHandler.java failed with java.lang.Exception: Reference Handler thread died

Doug Lea dl at openjdk.org
Mon Jul 11 15:02:06 UTC 2022


On Fri, 8 Jul 2022 11:44:53 GMT, Doug Lea <dl at openjdk.org> wrote:

> 8066859 : java/lang/ref/OOMEInReferenceHandler.java failed with java.lang.Exception: Reference Handler thread died

Thanks to @AlanBateman for suggesting to disable possibly misleading stack traces in pre-allocated exceptions; now updated

I keep trying but failing to change commit message to something jcheck likes?

The idea here is that a non-OOME-throwing condition wait might be required for (some) memory to be reclaimed. This is not too farfetched for InterruptedException (if serving as a cancellation), so we allow it to be thrown (instead of OOME) in hopes that a catch of IE will free memory. It IS farfetched to think this might be the case for IllegalMonitorStateException, but I did it the same way for consistency.

-------------

PR: https://git.openjdk.org/jdk/pull/9427


More information about the core-libs-dev mailing list