JMH 1.4.2

Aleksey Shipilev aleksey.shipilev at oracle.com
Thu Jan 15 11:01:27 UTC 2015


Hi,

JMH 1.4.2 is released and available at Maven Central (thanks to Evgeny,
as usual). This is a minor patch release, and it fixes a few issues
reported over Christmas break. Some of these fixes are non-trivial, so
you may run into issues, please try to update and report back if
anything is broken for you.

Summary of changes:

 * Stray threads in StackProfiler may have prevented forked VM from
exiting when benchmark experienced failure. Fixed:
   https://bugs.openjdk.java.net/browse/CODETOOLS-7901234

 * Result formatters had weird interaction with non-US locales. For
example, LaTeXResultFormatter was failing with Russian locale:
   https://bugs.openjdk.java.net/browse/CODETOOLS-7901235

 * As the follow-up, we have retrofitted all other result formatters to
play nicely with locales, and done more tests:
   https://bugs.openjdk.java.net/browse/CODETOOLS-7901236

 * Benchmark lists were corrupted when IDEs were partially recompiling
the project. E.g. saving a single benchmark compilation unit erased the
metadata about all other benchmarks, and saving an unrelated file was
obliterating the benchmark metadata file completely. Make sure you have
an recent IDE to make this work. JMH side of fix:
   https://bugs.openjdk.java.net/browse/CODETOOLS-7901237

 * Normally, we expect users to shutdown all their threads at the end of
the benchmark, because forked VM would not exit if non-daemon threads
are still running. However, there are semi-legitimate use cases when
users do not control all the threads, and this precludes the use of JMH.
We have implemented a shutdown timeout to cover for these cases:
   https://bugs.openjdk.java.net/browse/CODETOOLS-7901238

 * As the follow-up for introducing a shutdown timeout, we strengthened
the recovery from other types of stuck user code, like stuck shutdown
hooks, finalizers, etc:
   https://bugs.openjdk.java.net/browse/CODETOOLS-7901239

Enjoy!

Thanks,
-Aleksey




More information about the jmh-dev mailing list