RFR: JDK-8202788: Explicitly reclaim cached thread-local direct buffers at thread exit
Alan Bateman
Alan.Bateman at oracle.com
Fri Jun 22 09:50:21 UTC 2018
On 21/06/2018 18:29, Peter Levart wrote:
>
>
> On 06/21/2018 07:01 PM, Tony Printezis wrote:
>> I’m trying exactly that. :-)
>
> Sorry, I didn't know. Here's my attempt:
>
> http://cr.openjdk.java.net/~plevart/jdk-dev/DBBCache_Cleanup/webrev.07/
>
> I also added @run main/othervm to TempDirectBuffersReclamation test.
Right, tests depending on BufferPoolMXBean::getXXX do need to be
/othervm to avoid interference from free'ing buffers that were used by
previous tests in the same VM. If the name of the direct buffer pool is
changed then it would be useful for this test to fail so that it can be
updated. For that reason, I think it should fail if "direct" is not
found, maybe just add orElseThrow to the pipeline.
The rest looks okay to me (and although it took many iterations, I think
we got it to a good place).
-Alan
More information about the core-libs-dev
mailing list