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

a NoClassDefFoundError org/spearce/jgit/lib/ObjectId is raised when building from gerrit / gerrit trigger

    XMLWordPrintable

Details

    Description

      Using
      Jenkins 1.509
      Jenkins GIT client plugin 1.0.5
      Jenkins GIT plugin 1.3.0
      Gerrit Trigger 2.9.0

      The following error is thrown:
      Retriggered by user anonymous for Gerrit: http://172.18.48.95/1
      Building in workspace /home/ggargiulo/.jenkins/workspace/destination-management-gerrit
      Checkout:destination-management-gerrit / /home/ggargiulo/.jenkins/workspace/destination-management-gerrit - hudson.remoting.LocalChannel@2a081f8f
      Using strategy: Gerrit-Plugin
      Fetching changes from 1 remote Git repository
      Fetching upstream changes from origin
      FATAL: org/spearce/jgit/lib/ObjectId
      java.lang.NoClassDefFoundError: org/spearce/jgit/lib/ObjectId
      at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.parseCommit(GerritBuildChooser.java:111)
      at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.sortRevList(GerritBuildChooser.java:90)
      at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.getCandidateRevisions(GerritBuildChooser.java:46)
      at hudson.plugins.git.util.BuildChooser.getCandidateRevisions(BuildChooser.java:81)
      at hudson.plugins.git.util.BuildChooser.getCandidateRevisions(BuildChooser.java:71)
      at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:1044)
      at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:942)
      at hudson.FilePath.act(FilePath.java:865)
      at hudson.FilePath.act(FilePath.java:838)
      at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:942)
      at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1101)
      at hudson.model.AbstractProject.checkout(AbstractProject.java:1364)
      at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:670)
      at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88)
      at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:575)
      at hudson.model.Run.execute(Run.java:1575)
      at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
      at hudson.model.ResourceController.execute(ResourceController.java:88)
      at hudson.model.Executor.run(Executor.java:237)
      Caused by: java.lang.ClassNotFoundException: org.spearce.jgit.lib.ObjectId
      at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
      at java.security.AccessController.doPrivileged(Native Method)
      at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
      ... 19 more

      Attachments

        Activity

          dayeolee Dayeol Lee added a comment -

          anyone knows the solution of this problem?

          I have the same problem at Gerrit Plugin(0.7) at Jenkins 1.570

          FATAL: org/spearce/jgit/lib/ObjectId
          java.lang.NoClassDefFoundError: org/spearce/jgit/lib/ObjectId
          at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.parseCommit(GerritBuildChooser.java:111)
          at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.sortRevList(GerritBuildChooser.java:90)
          at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.getCandidateRevisions(GerritBuildChooser.java:46)
          at hudson.plugins.git.util.BuildChooser.getCandidateRevisions(BuildChooser.java:84)
          at hudson.plugins.git.util.BuildChooser.getCandidateRevisions(BuildChooser.java:74)
          at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:786)
          at hudson.plugins.git.GitSCM.checkout(GitSCM.java:873)
          at hudson.model.AbstractProject.checkout(AbstractProject.java:1387)
          at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:676)
          at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88)
          at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:581)
          at hudson.model.Run.execute(Run.java:1593)
          at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
          at hudson.model.ResourceController.execute(ResourceController.java:88)
          at hudson.model.Executor.run(Executor.java:247)

          dayeolee Dayeol Lee added a comment - anyone knows the solution of this problem? I have the same problem at Gerrit Plugin(0.7) at Jenkins 1.570 FATAL: org/spearce/jgit/lib/ObjectId java.lang.NoClassDefFoundError: org/spearce/jgit/lib/ObjectId at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.parseCommit(GerritBuildChooser.java:111) at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.sortRevList(GerritBuildChooser.java:90) at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.getCandidateRevisions(GerritBuildChooser.java:46) at hudson.plugins.git.util.BuildChooser.getCandidateRevisions(BuildChooser.java:84) at hudson.plugins.git.util.BuildChooser.getCandidateRevisions(BuildChooser.java:74) at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:786) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:873) at hudson.model.AbstractProject.checkout(AbstractProject.java:1387) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:676) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:581) at hudson.model.Run.execute(Run.java:1593) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:247)
          rin_ne rin_ne added a comment -

          GerritBuildChooser class is not included in this plugin (also Git/Git client plugin). Similar class this plugin has is GerritTriggerBuildChooser class.

          Seems you have installed other plugin (perhaps Gerrit plugin: https://wiki.jenkins-ci.org/display/JENKINS/Gerrit+Plugin). You should remove Gerrit Plugin or post this issue to Gerrit Plugin.

          rin_ne rin_ne added a comment - GerritBuildChooser class is not included in this plugin (also Git/Git client plugin). Similar class this plugin has is GerritTriggerBuildChooser class. Seems you have installed other plugin (perhaps Gerrit plugin: https://wiki.jenkins-ci.org/display/JENKINS/Gerrit+Plugin ). You should remove Gerrit Plugin or post this issue to Gerrit Plugin.

          Same issue with:

          • jenkins 1.515
          • Jenkins GIT client plugin 1.0.6
          • Jenkins GIT plugin 1.4.0

          Building in workspace /home/tomcat6/jenkins/jobs/demo-project/workspace
          Checkout:workspace / /home/tomcat6/jenkins/jobs/demo-project/workspace - hudson.remoting.LocalChannel@16a2135
          Using strategy: Gerrit-Plugin
          Fetching changes from 1 remote Git repository
          Fetching upstream changes from ssh://jenkins@****/demo-project
          FATAL: org/spearce/jgit/lib/ObjectId
          java.lang.NoClassDefFoundError: org/spearce/jgit/lib/ObjectId
          at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.parseCommit(GerritBuildChooser.java:111)
          at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.sortRevList(GerritBuildChooser.java:90)
          at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.getCandidateRevisions(GerritBuildChooser.java:46)
          at hudson.plugins.git.util.BuildChooser.getCandidateRevisions(BuildChooser.java:70)
          at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:1089)
          at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:978)
          at hudson.FilePath.act(FilePath.java:904)
          at hudson.FilePath.act(FilePath.java:877)
          at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:978)
          at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1134)
          at hudson.model.AbstractProject.checkout(AbstractProject.java:1369)
          at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:676)
          at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88)
          at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:581)
          at hudson.model.Run.execute(Run.java:1575)
          at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:486)
          at hudson.model.ResourceController.execute(ResourceController.java:88)
          at hudson.model.Executor.run(Executor.java:241)

          gdegani Giancarlo Degani added a comment - Same issue with: jenkins 1.515 Jenkins GIT client plugin 1.0.6 Jenkins GIT plugin 1.4.0 Building in workspace /home/tomcat6/jenkins/jobs/demo-project/workspace Checkout:workspace / /home/tomcat6/jenkins/jobs/demo-project/workspace - hudson.remoting.LocalChannel@16a2135 Using strategy: Gerrit-Plugin Fetching changes from 1 remote Git repository Fetching upstream changes from ssh://jenkins@****/demo-project FATAL: org/spearce/jgit/lib/ObjectId java.lang.NoClassDefFoundError: org/spearce/jgit/lib/ObjectId at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.parseCommit(GerritBuildChooser.java:111) at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.sortRevList(GerritBuildChooser.java:90) at hudson.plugins.gerrit.buildchoosers.GerritBuildChooser.getCandidateRevisions(GerritBuildChooser.java:46) at hudson.plugins.git.util.BuildChooser.getCandidateRevisions(BuildChooser.java:70) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:1089) at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:978) at hudson.FilePath.act(FilePath.java:904) at hudson.FilePath.act(FilePath.java:877) at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:978) at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1134) at hudson.model.AbstractProject.checkout(AbstractProject.java:1369) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:676) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:581) at hudson.model.Run.execute(Run.java:1575) at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:486) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:241)
          phinguyen Phi Nguyen added a comment -

          Does anyone has a workaround for this yet?

          phinguyen Phi Nguyen added a comment - Does anyone has a workaround for this yet?

          People

            jyrkiput jyrkiput
            nemo83 Giovanni Gargiulo
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated: