RFR: 8265261: java/nio/file/Files/InterruptCopy.java fails with java.lang.RuntimeException: Copy was not interrupted [v4]
Brian Burkhalter
bpb at openjdk.java.net
Sat Aug 21 00:05:26 UTC 2021
On Fri, 20 Aug 2021 17:39:46 GMT, Brian Burkhalter <bpb at openjdk.org> wrote:
>> This proposal suggests to change the timing of testing whether a file copy is terminated by an interrupt.
>
> Brian Burkhalter has updated the pull request incrementally with one additional commit since the last revision:
>
> 8265261: Drop countdown latch and repeats of interrupts
I have another version in progress and it would be worth waiting to review that one once it is published. The new version succeeded in 539 of 540 runs on four platforms (135 runs per platform). The failed case printed this information:
```Creating source file...
Source file created.
Copying file at 1629496891924ms...
Interrupting at 1629496891934ms...
Done copying at 1629496892261ms...
----------System.err:(13/761)----------
java.lang.RuntimeException: Copy was not interrupted
at InterruptCopy.doTest(InterruptCopy.java:110)
at InterruptCopy.main(InterruptCopy.java:60)
The interrupt call was made 10ms after the copy started, but the copy nonetheless ran another 327ms somehow without catching the interrupt. At present this is baffling.
-------------
PR: https://git.openjdk.java.net/jdk/pull/5154
More information about the nio-dev
mailing list