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

SSHD plugin throws an exception during shutdown

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • cli
    • None
    • Jenkins 2.89.2 (this has happened also with previous LTS versions)
      Java(TM) SE Runtime Environment (build 1.8.0_151-b12)

      I have a test that tries if a programmatically managed Jenkins installation can start again after a shutdown and it naturally involves shutting down Jenkins immediately after it's been started. I'm getting quite often following types of stack backtraces in this test:

      11:50:48 INFO: Jenkins stopped
      11:50:48 Dec 12, 2017 10:49:08 AM hudson.cli.declarative.CLIRegisterer$1 main
      11:50:48 WARNING: Unexpected exception occurred while performing shutdown command.
      11:50:48 java.lang.RuntimeException: Unexpected issues encountered during cleanUp: null
      11:50:48 at jenkins.model.Jenkins.cleanUp(Jenkins.java:3270)
      11:50:48 at jenkins.model.Jenkins.doExit(Jenkins.java:4268)
      11:50:48 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      11:50:48 at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      11:50:48 at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      11:50:48 at java.lang.reflect.Method.invoke(Method.java:498)
      11:50:48 at hudson.cli.declarative.MethodBinder.call(MethodBinder.java:114)
      11:50:48 at hudson.cli.declarative.CLIRegisterer$1.main(CLIRegisterer.java:225)
      11:50:48 at org.jenkinsci.main.modules.sshd.CLICommandAdapter$1.run(CLICommandAdapter.java:37)
      11:50:48 at org.jenkinsci.main.modules.sshd.AsynchronousCommand$1.run(AsynchronousCommand.java:112)
      11:50:48 at java.lang.Thread.run(Thread.java:748)
      11:50:48 Caused by: java.lang.InterruptedException
      11:50:48 at java.util.concurrent.locks.AbstractQueuedSynchronizer.tryAcquireSharedNanos(AbstractQueuedSynchronizer.java:1326)
      11:50:48 at java.util.concurrent.CountDownLatch.await(CountDownLatch.java:277)
      11:50:48 at jenkins.model.Jenkins._cleanUpShutdownTriggers(Jenkins.java:3453)
      11:50:48 at jenkins.model.Jenkins.cleanUp(Jenkins.java:3241)
      11:50:48 ... 10 more

      Unfortunately I can't say if successful shutdowns include this exception, but all failures do.

            Unassigned Unassigned
            ejusjud Jussi Judin
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: