RFR: JDK-8202788: Explicitly reclaim cached thread-local direct buffers at thread exit

Tony Printezis tprintezis at twitter.com
Tue May 8 15:07:08 UTC 2018


Hi all,

Following the discussion on this a few weeks ago, here’s the first version
of the change:

http://cr.openjdk.java.net/~tonyp/8202788/webrev.0/

I think the consensus was that it’d be easier if the exit hooks were only
available within java.base. Is it enough that I added the functionality to
the jdk.internal.misc package? (And is jdk.internal.misc the best place for
this?)

I’ll also add a test for the new functionality. But let’s first come up
with an approach that everyone is happy with. :-)

One additional question: I put the new functionality conditional on a
property (jdk.nio.freeBuffersAtThreadExit) and it’s off by default. Should
I make it on by default? Or just not add the property all-together?

Tony


—————
Tony Printezis | @TonyPrintezis | tprintezis at twitter.com


More information about the core-libs-dev mailing list