Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8276204

java/nio/file/Files/InterruptCopy.java test fails due to thread cleanup issue

    XMLWordPrintable

Details

    • x86_64
    • windows_10

    Description

      intermittent failure on Windows during MACH5 Windows SBR test runs

      test has launched a copy thread (via ScheduledExecutor) and a background has been launched to execute the copy, while the executor thread waits for completion.
      The copy is cancelled by invoking cancel on the returned Future.
      The tested scenarios appear to be successful.

      but the cancel doesn't seem to have reached the background threads involved in the copy waltz, for the cancel and interrupt don't seem to have terminated those threads or they are not being reaped.




      JavaTest Message: Test complete.


      JavaTest Message: Problem cleaning up the following threads:
      pool-3-thread-1
        at java.base@18-ea/java.lang.Object.wait(Native Method)
        at java.base@18-ea/java.lang.Thread.join(Thread.java:1304)
        at java.base@18-ea/java.lang.Thread.join(Thread.java:1372)
        at java.base@18-ea/sun.nio.fs.Cancellable.runInterruptibly(Cancellable.java:125)
        at java.base@18-ea/sun.nio.fs.WindowsFileCopy.copy(WindowsFileCopy.java:197)
        at java.base@18-ea/sun.nio.fs.WindowsFileSystemProvider.copy(WindowsFileSystemProvider.java:284)
        at java.base@18-ea/java.nio.file.Files.copy(Files.java:1305)
        at InterruptCopy$2.call(InterruptCopy.java:139)
        at InterruptCopy$2.call(InterruptCopy.java:134)
        at java.base@18-ea/java.util.concurrent.FutureTask.run(FutureTask.java:264)
        at java.base@18-ea/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304)
        at java.base@18-ea/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
        at java.base@18-ea/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
        at java.base@18-ea/java.lang.Thread.run(Thread.java:833)

      NIO-Task
        at java.base@18-ea/sun.nio.fs.WindowsNativeDispatcher.CopyFileEx0(Native Method)
        at java.base@18-ea/sun.nio.fs.WindowsNativeDispatcher.CopyFileEx(WindowsNativeDispatcher.java:314)
        at java.base@18-ea/sun.nio.fs.WindowsFileCopy$1.implRun(WindowsFileCopy.java:189)
        at java.base@18-ea/sun.nio.fs.Cancellable.run(Cancellable.java:95)
        at java.base@18-ea/java.lang.Thread.run(Thread.java:833)

      ----------System.out:(9/265)----------
      Checking space ((C:))
      Creating source file...
      Source file created.
      Copying file at 1635437763359 ms...
      Interrupting at 1635437763410 ms...
      Copy failed (this is expected).
      Copying file at 1635437770936 ms...
      Cancelling at 1635437770951 ms...
      Copy cancelled.
      result: Error. Error while cleaning up threads after test


      test result: Error. Error while cleaning up threads after test

      Attachments

        Activity

          People

            msheppar Mark Sheppard
            msheppar Mark Sheppard
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated: