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

Mina ssh plugin 2.8.0-30.vf9df64641cb_d has a cyclic dependency, breaks Jenkins plugin loading

      Jenkins fails to load plugins due to a cyclic dependency in the mina ssh plugins (core and common) 2.8.0-30.vf9df64641cb_d.

      Message that is reported in the log is

      2022-07-18 14:45:47.783+0000 [id=32]    INFO    jenkins.InitReactorRunner$1#onAttained: Listed all plugins
      2022-07-18 14:45:48.198+0000 [id=34]    SEVERE  jenkins.InitReactorRunner$1#onTaskFailed: Failed Loading plugin Support Core Plugin v1201.v8d1f54a_6ec7c (support-core)
      java.io.IOException: Failed to load: Support Core Plugin (support-core 1201.v8d1f54a_6ec7c)
       - Required plugin is disabled: Credentials Plugin (credentials)
              at hudson.PluginWrapper.resolvePluginDependencies(PluginWrapper.java:1018)
              at hudson.PluginManager$2$1$1.run(PluginManager.java:542)
              at org.jvnet.hudson.reactor.TaskGraphBuilder$TaskImpl.run(TaskGraphBuilder.java:175)
              at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:305)
              at jenkins.model.Jenkins$5.runTask(Jenkins.java:1158)
              at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:222)
              at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:121)
              at jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:68)
              at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
              at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
              at java.base/java.lang.Thread.run(Thread.java:829)
      2022-07-18 14:45:48.199+0000 [id=29]    SEVERE  jenkins.InitReactorRunner$1#onTaskFailed: Failed Loading plugin Pipeline: Input Step v449.v77f0e8b_845c4 (pipeline-input-step)
      java.io.IOException: Failed to load: Pipeline: Input Step (pipeline-input-step 449.v77f0e8b_845c4)
       - Required plugin is disabled: Credentials Plugin (credentials)
              at hudson.PluginWrapper.resolvePluginDependencies(PluginWrapper.java:1018)
              at hudson.PluginManager$2$1$1.run(PluginManager.java:542)
              at org.jvnet.hudson.reactor.TaskGraphBuilder$TaskImpl.run(TaskGraphBuilder.java:175)
              at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:305)
              at jenkins.model.Jenkins$5.runTask(Jenkins.java:1158)
              at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:222)
              at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:121)
              at jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:68)
              at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
              at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
              at java.base/java.lang.Thread.run(Thread.java:829)
      2022-07-18 14:45:48.200+0000 [id=29]    SEVERE  jenkins.InitReactorRunner$1#onTaskFailed: Failed Loading plugin Pipeline Graph Analysis Plugin v195.v5812d95a_a_2f9 (pipeline-graph-analysis)
      java.io.IOException: Failed to load: Pipeline Graph Analysis Plugin (pipeline-graph-analysis 195.v5812d95a_a_2f9)
       - Failed to load: Pipeline: Input Step (pipeline-input-step 449.v77f0e8b_845c4)
              at hudson.PluginWrapper.resolvePluginDependencies(PluginWrapper.java:1018)
              at hudson.PluginManager$2$1$1.run(PluginManager.java:542)
              at org.jvnet.hudson.reactor.TaskGraphBuilder$TaskImpl.run(TaskGraphBuilder.java:175)
              at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:305)
              at jenkins.model.Jenkins$5.runTask(Jenkins.java:1158)
              at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:222)
              at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:121)
              at jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:68)
              at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
              at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
              at java.base/java.lang.Thread.run(Thread.java:829)
      

      Steps to duplicate the problem

      1. Download the attached plugins.txt
      2. Run the following shell script:
        if [ ! -f ../jenkins-plugin-manager-2.12.8.jar ]; then
          wget https://github.com/jenkinsci/plugin-installation-manager-tool/releases/download/2.12.8/jenkins-plugin-manager-2.12.8.jar
          mv jenkins-plugin-manager-2.12.8.jar ..
        fi
        if [ ! -d plugins ]; then
          mkdir plugins
        fi
        java -jar ../jenkins-plugin-manager-2.12.8.jar --jenkins-version 2.346.2 --latest false --plugin-download-directory plugins --plugin-file plugins.txt
        
        if [ ! -f ../jenkins-2.346.2.war ]; then
          wget https://get.jenkins.io/war-stable/2.346.2/jenkins.war
          mv jenkins.war ../jenkins-2.346.2.war
        fi
        JENKINS_HOME=. java -jar ../jenkins-2.346.2.war
        

      Expected results

      Jenkins starts with all plugins enabled.

      Actual results

      Jenkins reports that plugins were not enabled. and is missing functionality from those plugins.

      Workaround

      Use the previous releases of the mina plugins:

      In your plugins.txt file

      mina-sshd-api-common:latest:https://get.jenkins.io/plugins/mina-sshd-api-common/2.8.0-21.v493b_6b_db_22c6/mina-sshd-api-common.hpi
      mina-sshd-api-core:latest:https://get.jenkins.io/plugins/mina-sshd-api-core/2.8.0-21.v493b_6b_db_22c6/mina-sshd-api-core.hpi
      

      From the plugin manager page

      Use the Advanced tab of the plugin manager to upload a plugin from the following URLs:

      Restart Jenkins after uploading both plugins.

          [JENKINS-69034] Mina ssh plugin 2.8.0-30.vf9df64641cb_d has a cyclic dependency, breaks Jenkins plugin loading

          Puja Dube created issue -

          I have the same problem, adding some more infos.

          Jenkins LTS, 2.346.2, installed from docker image. As soon as I update plugins to latest version, jenkins stop working properly.

          The main message from the dashboard says:

          The following plugins are deactivated because of cyclic dependencies, most likely you can resolve the issue by updating these to a newer version

          commons-lang3 v3.x Jenkins Api Plugin v3.12.0.0

          commons-text API Plugin v1.9-9.v39a_53e2e0343

          Configuration as Code Plugin v1466.v2d4119502006

          Credentials Plugin v1139.veb_9579fca_33b_

          Mina SSHD API :: Core v2.8.0-30.vf9df64641cb_d

          SSH Credentials Plugin v291.v8211e4f8efb_c

          SSH server v3.242.va_db_9da_b_26a_c3

          During startup logs complain about the same problem:

          2022-07-18 13:24:18.375+0000 [id=23]    INFO    winstone.Logger#logInternal: Winstone Servlet Engine running: controlPort=disabled
          2022-07-18 13:24:18.619+0000 [id=29]    INFO    jenkins.InitReactorRunner$1#onAttained: Started initialization
          2022-07-18 13:24:20.581+0000 [id=29]    SEVERE  hudson.PluginManager$1$3$2$1#reactOnCycle: found cycle in plugin dependencies: (root=Plugin:sshd, deactivating all involved) Plugin:sshd -> Plugin:mina-sshd-api-core -> Plugin:ssh-credentials -> Plugin:credentials -> Plugin:configuration-as-code -> Plugin:commons-text-api -> Plugin:commons-lang3-api -> Plugin:sshd
          2022-07-18 13:24:20.589+0000 [id=29]    INFO    jenkins.InitReactorRunner$1#onAttained: Listed all plugins
          2022-07-18 13:24:20.945+0000 [id=29]    SEVERE  jenkins.InitReactorRunner$1#onTaskFailed: Failed Loading plugin Plain Credentials Plugin v1.8 (plain-credentials)
          java.io.IOException: Failed to load: Plain Credentials Plugin (plain-credentials 1.8)
           - Required plugin is disabled: Credentials Plugin (credentials)
                  at hudson.PluginWrapper.resolvePluginDependencies(PluginWrapper.java:1018)
                  at hudson.PluginManager$2$1$1.run(PluginManager.java:542)
                  at org.jvnet.hudson.reactor.TaskGraphBuilder$TaskImpl.run(TaskGraphBuilder.java:175)
                  at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:305)
                  at jenkins.model.Jenkins$5.runTask(Jenkins.java:1158)
                  at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:222)
                  at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:121)
                  at jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:68)
                  at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
                  at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
                  at java.base/java.lang.Thread.run(Thread.java:829)

          Rolling back to previous version solves the problem.

          Giancarlo Rosso added a comment - I have the same problem, adding some more infos. Jenkins LTS, 2.346.2, installed from docker image. As soon as I update plugins to latest version, jenkins stop working properly. The main message from the dashboard says: The following plugins are deactivated because of cyclic dependencies, most likely you can resolve the issue by updating these to a newer version commons-lang3 v3.x Jenkins Api Plugin v3.12.0.0 commons-text API Plugin v1.9-9.v39a_53e2e0343 Configuration as Code Plugin v1466.v2d4119502006 Credentials Plugin v1139.veb_9579fca_33b _ Mina SSHD API :: Core v2.8.0-30.vf9df64641cb_d SSH Credentials Plugin v291.v8211e4f8efb_c SSH server v3.242.va_db_9da_b_26a_c3 During startup logs complain about the same problem: 2022-07-18 13:24:18.375+0000 [id=23]    INFO    winstone.Logger#logInternal: Winstone Servlet Engine running: controlPort=disabled 2022-07-18 13:24:18.619+0000 [id=29]    INFO    jenkins.InitReactorRunner$1#onAttained: Started initialization 2022-07-18 13:24:20.581+0000 [id=29]    SEVERE  hudson.PluginManager$1$3$2$1#reactOnCycle: found cycle in plugin dependencies: (root=Plugin:sshd, deactivating all involved) Plugin:sshd -> Plugin:mina-sshd-api-core -> Plugin:ssh-credentials -> Plugin:credentials -> Plugin:configuration-as-code -> Plugin:commons-text-api -> Plugin:commons-lang3-api -> Plugin:sshd 2022-07-18 13:24:20.589+0000 [id=29]    INFO    jenkins.InitReactorRunner$1#onAttained: Listed all plugins 2022-07-18 13:24:20.945+0000 [id=29]    SEVERE  jenkins.InitReactorRunner$1#onTaskFailed: Failed Loading plugin Plain Credentials Plugin v1.8 (plain-credentials) java.io.IOException: Failed to load: Plain Credentials Plugin (plain-credentials 1.8)  - Required plugin is disabled: Credentials Plugin (credentials)         at hudson.PluginWrapper.resolvePluginDependencies(PluginWrapper.java:1018)         at hudson.PluginManager$2$1$1.run(PluginManager.java:542)         at org.jvnet.hudson.reactor.TaskGraphBuilder$TaskImpl.run(TaskGraphBuilder.java:175)         at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:305)         at jenkins.model.Jenkins$5.runTask(Jenkins.java:1158)         at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:222)         at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:121)         at jenkins.security.ImpersonatingExecutorService$1.run(ImpersonatingExecutorService.java:68)         at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)         at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)         at java.base/java.lang.Thread.run(Thread.java:829) Rolling back to previous version solves the problem.
          Mark Waite made changes -
          Component/s New: mina-sshd-api-plugin [ 28925 ]
          Component/s Original: credentials-plugin [ 16523 ]

          Mark Waite added a comment -

          Thanks for reporting it. The issue appears to be in the https://plugins.jenkins.io/mina-sshd-api-common/ or https://plugins.jenkins.io/mina-sshd-api-core/ plugins (or both).

          I've changed the assigned component.

          Mark Waite added a comment - Thanks for reporting it. The issue appears to be in the https://plugins.jenkins.io/mina-sshd-api-common/ or https://plugins.jenkins.io/mina-sshd-api-core/ plugins (or both). I've changed the assigned component.
          Mark Waite made changes -
          Summary Original: its not working New: Mina ssh plugin 2.8.0-30.vf9df64641cb_d has a cyclic dependency, breaks Jenkins plugin loading

          Mark Waite added a comment -

          jamsdeni I failed to read the original (missing) description of this issue. puja123_user reported "its not working" and provided no other information in the issue report. puja123_user also reported "its not working" in JENKINS-68982 a week ago. After no response, I closed it.

          I don't object to using this issue to track the Apache mina plugin dependency issue, but that may not be the issue that puja123_user was originally trying to report. Are you OK if we continue to use this issue to track the Apache mina problem or would you prefer that another issue is opened that starts with the description of the problem and how to duplicate it?

          Mark Waite added a comment - jamsdeni I failed to read the original (missing) description of this issue. puja123_user reported "its not working" and provided no other information in the issue report. puja123_user also reported "its not working" in JENKINS-68982 a week ago. After no response, I closed it. I don't object to using this issue to track the Apache mina plugin dependency issue, but that may not be the issue that puja123_user was originally trying to report. Are you OK if we continue to use this issue to track the Apache mina problem or would you prefer that another issue is opened that starts with the description of the problem and how to duplicate it?

          Henry Borchers added a comment - - edited

          This is broke Jenkins for me too but i'm not getting the option to roll back. 

           

          Edit: I got it to roll back. 

          Henry Borchers added a comment - - edited This is broke Jenkins for me too but i'm not getting the option to roll back.    Edit: I got it to roll back. 

          I can't load the Credentials Plugin after updating.

          Cycle detected: Plugin:sshd -> Plugin:mina-sshd-api-core -> Plugin:ssh-credentials -> Plugin:credentials -> Plugin:configuration-as-code -> Plugin:commons-text-api -> Plugin:commons-lang3-api -> Plugin:sshd  

          Henry Borchers added a comment - I can't load the Credentials Plugin after updating. Cycle detected: Plugin:sshd -> Plugin:mina-sshd-api-core -> Plugin:ssh-credentials -> Plugin:credentials -> Plugin:configuration-as-code -> Plugin:commons-text-api -> Plugin:commons-lang3-api -> Plugin:sshd  

          Daniel Beck added a comment - - edited

          The best solution is probably for commons-lang3-api to get a core dependency bump, so it doesn't have the implied dependency on sshd (i.e., depend on 2.289.x or newer).

          (Assuming there's a good reason for the feature introducing the dependency in mina-sshd-api-core.)

          Daniel Beck added a comment - - edited The best solution is probably for commons-lang3-api to get a core dependency bump, so it doesn't have the implied dependency on sshd (i.e., depend on 2.289.x or newer). (Assuming there's a good reason for the feature introducing the dependency in mina-sshd-api-core .)

          Jesse Glick added a comment -

          Could probably be solved more readily in, say, commons-lang3-api.

          Jesse Glick added a comment - Could probably be solved more readily in, say, commons-lang3-api .

            jglick Jesse Glick
            puja123_user Puja Dube
            Votes:
            0 Vote for this issue
            Watchers:
            12 Start watching this issue

              Created:
              Updated:
              Resolved: