RFR: 8373439: Deadlock between flight recorder & VMDeath [v2]
Erik Gahlin
egahlin at openjdk.org
Tue Dec 16 09:41:03 UTC 2025
On Mon, 15 Dec 2025 10:53:21 GMT, Erik Gahlin <egahlin at openjdk.org> wrote:
>>> A third alternative is to avoid destroying native JFR at shutdown
>>
>> I think for this option it's better to wait on Markus as you mentioned
>>
>> -------
>>
>> For the other options, I don't like the first option of `isInShutdown` as some APIs, are designed to run fine after the flag is set, such as the `stop` API
>>
>> As for the internal checked exception, the exception by it self won't be sufficient, as the recoding also needs to be transformed into a "dummy recording" as from a user perspective the application continued normally so the recording "started", otherwise this recording becomes a deadlock hazard
>>
>> Now the aspect of a "dummy recording" is interesting, what do you think about adding a new `RecordingState` we call it dummy, which we add checks for where is needed within the various APIs
>
> I thought about it, but it doesn't solve the underlying problem and may break things for API users. We might as well use RUNNING and some internal flag.
I don't think it makes sense to implement anything until we have resolved the design, which is best done after New Year's. Also, I will be on vacation, so my time for reviews will be limited.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/28767#discussion_r2622512926
More information about the hotspot-jfr-dev
mailing list