[crac] RFR: Ensure all notifications finish even if only daemon threads remain [v5]
    Radim Vansa 
    duke at openjdk.org
       
    Thu May 11 06:25:09 UTC 2023
    
    
  
On Wed, 10 May 2023 14:50:53 GMT, Anton Kozlov <akozlov at openjdk.org> wrote:
>> If as a result of beforeCheckpoint() no more non-daemon threads remain, it's possible that VM exits prematurely, before one of afterRestore() get a chance to create another non-daemon thread that will keep VM alive. Triggering checkpoint via jcmd (so checkpointRestore() method is executed on daemon attach-listener thread), increases probability to step in the problem.
>> 
>> The change ensures all notifications are done while there is at least one non-daemon thread. The notification methods are still called from the original thread.
>
> Anton Kozlov has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Move KeepAlive to separate class, handle interrupts
I am practically approving my own changes, but ok.
-------------
Marked as reviewed by rvansa at github.com (no known OpenJDK username).
PR Review: https://git.openjdk.org/crac/pull/62#pullrequestreview-1421830947
    
    
More information about the crac-dev
mailing list