RFR: 8373439: Deadlock between flight recorder & VMDeath

Bara' Hasheesh duke at openjdk.org
Fri Dec 12 13:37:09 UTC 2025


On Thu, 11 Dec 2025 15:44:48 GMT, Francesco Andreuzzi <fandreuzzi at openjdk.org> wrote:

>> A simple `PlatformRecorder.isInShutDown` check is added to `PlatformRecording.start` to prevent any new recording from start after the JVM initiates it's shutdown hooks  
>> 
>> A new test was added that fails without the change & passes with it 
>> 
>> I also ran `tier1`, `tier2` as well as `jdk_jfr` on Linux x86
>
> test/jdk/jdk/jfr/api/recording/deadlock/TestShutdownDeadLock.java line 43:
> 
>> 41:         Recording r = new Recording();
>> 42:         r.start();
>> 43:         r.stop();
> 
> Are these two lines needed for the reproducer?

These calls they are made to guarantee that the entire JFR components are fully initialized (internals threads & other structures) & fully functional as recordings are able to be processed normally. 

While not needed as only `new Recording` is needed to start that creation process, but I would personally vote to keep them

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

PR Review Comment: https://git.openjdk.org/jdk/pull/28767#discussion_r2611162129


More information about the hotspot-jfr-dev mailing list