Uploaded image for project: 'Infinispan'
  1. Infinispan
  2. ISPN-1114

TestingUtil.sleepThread that throws back InterruptedException is needed

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 5.0.0.CR3
    • None
    • Test Suite
    • None

    Description

      There should be an alternative TestingUtil.sleepThread() that throws backe the interrupted exception back up to show that something went wrong, otherwise if a test times out (configured via @Test(timeOut=X)), the interruption might be lost and as you can see in the attached thread dump of the testsuite that's been going on for over 50 minutes,

      "TestNGInvoker-testPutRemove()" Id=10572 Group=main TIMED_WAITING
      	at java.lang.Thread.sleep(Native Method)
      	at org.infinispan.test.TestingUtil.sleepThread(TestingUtil.java:401)
      	at org.infinispan.loaders.decorators.AsyncTest.doTestRemove(AsyncTest.java:432)
      	at org.infinispan.loaders.decorators.AsyncTest.testPutRemove(AsyncTest.java:94)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      	at java.lang.reflect.Method.invoke(Method.java:597)
      	at org.testng.internal.MethodHelper.invokeMethod(MethodHelper.java:644)
      	at org.testng.internal.InvokeMethodRunnable.runOne(InvokeMethodRunnable.java:49)
      	at org.testng.internal.InvokeMethodRunnable.run(InvokeMethodRunnable.java:40)
      	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
      	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
      	at java.lang.Thread.run(Thread.java:662)

      Attachments

        Activity

          People

            rh-ee-galder Galder Zamarreño
            rh-ee-galder Galder Zamarreño
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: