Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-33428

Unable to kill JNLP process

XMLWordPrintable

      I am launching JNLP slave in tests and wants to kill it once done. In same cases the testsuite can get stuck in following situation:

      master:

      "main" prio=10 tid=0x00007f2628008800 nid=0x7f70 in Object.wait() [0x00007f26302e1000]
         java.lang.Thread.State: WAITING (on object monitor)
      	at java.lang.Object.wait(Native Method)
      	- waiting on <0x000000008745d530> (a java.lang.UNIXProcess)
      	at java.lang.Object.wait(Object.java:503)
      	at java.lang.UNIXProcess.waitFor(UNIXProcess.java:263)
      	- locked <0x000000008745d530> (a java.lang.UNIXProcess)
      	at hudson.Proc$LocalProc.join(Proc.java:319)
      	at hudson.Proc$LocalProc.kill(Proc.java:372)
      	at jenkins.plugins.openstack.PluginTestRule$3.evaluate(PluginTestRule.java:227)
      	at org.junit.rules.RunRules.evaluate(RunRules.java:20)
      	at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271)
      	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70)
      	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)
      	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238)
      	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63)
      	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236)
      	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53)
      	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229)
      	at org.junit.runners.ParentRunner.run(ParentRunner.java:309)
      	at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:264)
      	at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:153)
      	at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:124)
      	at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:200)
      	at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:153)
      	at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103)
      

      slave:

      "main" prio=10 tid=0x00007fda4c009000 nid=0x2ba waiting on condition [0x00007fda559d7000]
         java.lang.Thread.State: TIMED_WAITING (sleeping)
      	at java.lang.Thread.sleep(Native Method)
      	at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:338)
      	at hudson.remoting.Launcher.run(Launcher.java:218)
      	at hudson.remoting.Launcher.main(Launcher.java:192)
      

      LocalProc.join waits forever, though it is enough to send kill -15 to the slave to recover.

            Unassigned Unassigned
            olivergondza Oliver Gondža
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: