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

java.lang.LinkageError when installing - DashboardPortlet not present

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      After installation of Delivery Pipeline 1.0.1 (the latest at this time), I've got this error in Jenkins Logs and Delivery Pipeline doesn't work as expected.

      The complete stack trace is the following :

      May 25, 2017 7:20:25 AM jenkins.InitReactorRunner$1 onAttained
      INFO: Listed all plugins
      May 25, 2017 7:20:28 AM hudson.ExtensionFinder$GuiceFinder$SezpozModule configure
      WARNING: Failed to load se.diabol.jenkins.pipeline.portlet.DeliveryPipelineViewPortlet$DescriptorImpl
      java.lang.LinkageError: Failed to resolve class se.diabol.jenkins.pipeline.portlet.DeliveryPipelineViewPortlet$DescriptorImpl
      {{ at hudson.ExtensionFinder$GuiceFinder$SezpozModule.resolve(ExtensionFinder.java:489)}}
      {{ at hudson.ExtensionFinder$GuiceFinder$SezpozModule.configure(ExtensionFinder.java:506)}}
      {{ at com.google.inject.AbstractModule.configure(AbstractModule.java:62)}}
      {{ at com.google.inject.spi.Elements$RecordingBinder.install(Elements.java:340)}}
      {{ at com.google.inject.spi.Elements.getElements(Elements.java:110)}}
      {{ at com.google.inject.internal.InjectorShell$Builder.build(InjectorShell.java:138)}}
      {{ at com.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:104)}}
      {{ at com.google.inject.Guice.createInjector(Guice.java:96)}}
      {{ at com.google.inject.Guice.createInjector(Guice.java:73)}}
      {{ at hudson.ExtensionFinder$GuiceFinder.<init>(ExtensionFinder.java:280)}}
      {{ at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)}}
      {{ at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)}}
      {{ at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)}}
      {{ at java.lang.reflect.Constructor.newInstance(Constructor.java:423)}}
      {{ at java.lang.Class.newInstance(Class.java:442)}}
      {{ at net.java.sezpoz.IndexItem.instance(IndexItem.java:181)}}
      {{ at hudson.ExtensionFinder$Sezpoz._find(ExtensionFinder.java:634)}}
      {{ at hudson.ExtensionFinder$Sezpoz.find(ExtensionFinder.java:609)}}
      {{ at hudson.ClassicPluginStrategy.findComponents(ClassicPluginStrategy.java:472)}}
      {{ at hudson.ExtensionList.load(ExtensionList.java:365)}}
      {{ at hudson.ExtensionList.ensureLoaded(ExtensionList.java:303)}}
      {{ at hudson.ExtensionList.getComponents(ExtensionList.java:168)}}
      {{ at jenkins.model.Jenkins$8.onInitMilestoneAttained(Jenkins.java:1120)}}
      {{ at jenkins.InitReactorRunner$1.onAttained(InitReactorRunner.java:82)}}
      {{ at org.jvnet.hudson.reactor.ReactorListener$Aggregator.onAttained(ReactorListener.java:104)}}
      {{ at org.jvnet.hudson.reactor.Reactor$1.run(Reactor.java:176)}}
      {{ at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:117)}}
      {{ at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)}}
      {{ at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)}}
      {{ at java.lang.Thread.run(Thread.java:745)}}
      Caused by: java.lang.TypeNotPresentException: Type hudson.plugins.view.dashboard.DashboardPortlet not present
      {{ at sun.reflect.generics.factory.CoreReflectionFactory.makeNamedType(CoreReflectionFactory.java:117)}}
      {{ at sun.reflect.generics.visitor.Reifier.visitClassTypeSignature(Reifier.java:125)}}
      {{ at sun.reflect.generics.tree.ClassTypeSignature.accept(ClassTypeSignature.java:49)}}
      {{ at sun.reflect.generics.visitor.Reifier.reifyTypeArguments(Reifier.java:68)}}
      {{ at sun.reflect.generics.visitor.Reifier.visitClassTypeSignature(Reifier.java:138)}}
      {{ at sun.reflect.generics.tree.ClassTypeSignature.accept(ClassTypeSignature.java:49)}}
      {{ at sun.reflect.generics.repository.ClassRepository.getSuperclass(ClassRepository.java:90)}}
      {{ at java.lang.Class.getGenericSuperclass(Class.java:777)}}
      {{ at hudson.ExtensionFinder$GuiceFinder$SezpozModule.resolve(ExtensionFinder.java:470)}}
      {{ ... 29 more}}
      Caused by: java.lang.ClassNotFoundException: hudson.plugins.view.dashboard.DashboardPortlet
      {{ at jenkins.util.AntClassLoader.findClassInComponents(AntClassLoader.java:1373)}}
      {{ at jenkins.util.AntClassLoader.findClass(AntClassLoader.java:1326)}}
      {{ at jenkins.util.AntClassLoader.loadClass(AntClassLoader.java:1079)}}
      {{ at java.lang.ClassLoader.loadClass(ClassLoader.java:357)}}
      {{ at java.lang.Class.forName0(Native Method)}}
      {{ at java.lang.Class.forName(Class.java:348)}}
      {{ at sun.reflect.generics.factory.CoreReflectionFactory.makeNamedType(CoreReflectionFactory.java:114)}}
      {{ ... 37 more}}

        Attachments

          Activity

          jmcollin Jean-Marc Collin created issue -
          Hide
          jmcollin Jean-Marc Collin added a comment -

          Same error with 2.64.2 (non Alpine) docker image.

          Show
          jmcollin Jean-Marc Collin added a comment - Same error with 2.64.2 (non Alpine) docker image.
          Hide
          danielbeck Daniel Beck added a comment -
          Show
          danielbeck Daniel Beck added a comment - Delivery Pipeline Plugin seems to have a mandatory dependency on Dashboard Plugin but declares it optional. Bug in Delivery Pipeline, unrelated to Jenkins core etc. https://github.com/Diabol/delivery-pipeline-plugin/blob/8b9bdc10cfaf5a4c9e41c4801d7f9ea38e2a3362/src/main/java/se/diabol/jenkins/pipeline/portlet/DeliveryPipelineViewPortlet.java#L32 https://github.com/Diabol/delivery-pipeline-plugin/blob/master/pom.xml#L499  
          Hide
          danielbeck Daniel Beck added a comment -

          Notably, nothing but what appears to be this optional feature seems affected, so should be safe to ignore.

          Show
          danielbeck Daniel Beck added a comment - Notably, nothing but what appears to be this optional feature seems affected, so should be safe to ignore.
          tommysdk Tommy Tynjä made changes -
          Field Original Value New Value
          Assignee Patrik Boström [ patbos ] Tommy Tynjä [ tommysdk ]
          Hide
          tommysdk Tommy Tynjä added a comment -

          As Daniel Beck mentions above, it's unfortunately required although the intention was to keep the dependency optional. This should only affect views used through the dashboard-view plugin. Workaround to avoid the error is to install the dashboard-view plugin.

          Community contribution to address this appreciated.

          Show
          tommysdk Tommy Tynjä added a comment - As Daniel Beck mentions above, it's unfortunately required although the intention was to keep the dependency optional. This should only affect views used through the dashboard-view plugin. Workaround to avoid the error is to install the dashboard-view plugin. Community contribution to address this appreciated.
          Hide
          danielbeck Daniel Beck added a comment -

          Tommy Tynjä Any reason you didn't mark the @Extension(optional = true) ? That would indicate that loading errors are to be expected, so doesn't get a full stack trace.

          Show
          danielbeck Daniel Beck added a comment - Tommy Tynjä Any reason you didn't mark the @Extension(optional = true) ? That would indicate that loading errors are to be expected, so doesn't get a full stack trace.
          Hide
          tommysdk Tommy Tynjä added a comment -

          Daniel Beck It was probably missed by the contributor of that feature. I am currently looking into this issue atm with the @Extension(optinal = true) approach.

          Show
          tommysdk Tommy Tynjä added a comment - Daniel Beck It was probably missed by the contributor of that feature. I am currently looking into this issue atm with the @Extension(optinal = true) approach.
          tommysdk Tommy Tynjä made changes -
          Status Open [ 1 ] In Progress [ 3 ]
          tommysdk Tommy Tynjä made changes -
          Summary java.lang.LinkageError when installing 1.0.1 - DahsboardPortlet not present java.lang.LinkageError when installing 1.0.1 - DashboardPortlet not present
          Hide
          tommysdk Tommy Tynjä added a comment -
          Show
          tommysdk Tommy Tynjä added a comment - Pull request with proposed solution: https://github.com/Diabol/delivery-pipeline-plugin/pull/258
          Hide
          tommysdk Tommy Tynjä added a comment -

          Pull request merged to master.

          Will be featured in next release.

          Show
          tommysdk Tommy Tynjä added a comment - Pull request merged to master. Will be featured in next release.
          tommysdk Tommy Tynjä made changes -
          Resolution Fixed [ 1 ]
          Status In Progress [ 3 ] Resolved [ 5 ]
          tommysdk Tommy Tynjä made changes -
          Environment Dockerized Jenkins 1.42-alpine release Delivery Pipeline plugin 1.0.1, 1.0.2, 1.0.3
          Summary java.lang.LinkageError when installing 1.0.1 - DashboardPortlet not present java.lang.LinkageError when installing - DashboardPortlet not present
          Hide
          tommysdk Tommy Tynjä added a comment -

          Released in Delivery Pipeline plugin 1.0.4.

          Show
          tommysdk Tommy Tynjä added a comment - Released in Delivery Pipeline plugin 1.0.4.
          tommysdk Tommy Tynjä made changes -
          Status Resolved [ 5 ] Closed [ 6 ]

            People

            Assignee:
            tommysdk Tommy Tynjä
            Reporter:
            jmcollin Jean-Marc Collin
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: