RFR 9: 8086208 : java/lang/ProcessHandle/OnExitTest.java: IllegalThreadStateException: process hasn't exited
Roger Riggs
Roger.Riggs at Oracle.com
Mon Jun 15 21:21:24 UTC 2015
Hi Martin,
Since the function is called from the FJ pool; what would result from
propagating the interrupt?
The FJPool reports the interrupted to the task but otherwise just clears it.
It does not affect the completion status.
Since it is known that the process has terminated and is only waiting
for the
Thread in ProcessImpl to post the status; it cannot/should not proceed
until the
exitValue is valid.
The webrev has been updated to propagate the interrupted status but it will
likely be ignored/discarded.
Roger
On 6/15/2015 4:46 PM, Martin Buchholz wrote:
> if you do get interrupted, the interrupt is swallowed, which seems wrong.
>
> Other waiting methods have "uninterruptible" variants, that restore
> the interrupt status, like Semaphore.acquireUninterruptibly. Should
> there be a Process.waitForUninterruptibly?
>
> On Mon, Jun 15, 2015 at 1:37 PM, Roger Riggs <Roger.Riggs at oracle.com
> <mailto:Roger.Riggs at oracle.com>> wrote:
>
> Please review a fix for a (Unix) race condition for the exit
> status of Process.onExit.
> And some source cleanup of OnExitTest.
>
> Webrev:
> http://cr.openjdk.java.net/~rriggs/webrev-race-8086208/
> <http://cr.openjdk.java.net/%7Erriggs/webrev-race-8086208/>
>
> Issue:
> https://bugs.openjdk.java.net/browse/JDK-8086208
>
> Roger
>
>
More information about the core-libs-dev
mailing list