java.lang.NoClassDefFoundError: Failed to get fields for class [org.xwiki.git.internal.GitScriptService] because the class [org/eclipse/jgit/lib/Repository] couldn't be found in the ClassLoader.

XWiki.org JIRA | Vincent Massol | 5 years ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    I've tried to install an extension defined on e.x.o that was missing a dependency (jgit). The installation stopped in mid-flight because of this error (in the console, not in the UI): {noformat} 2012-07-13 18:19:43,588 [http://localhost:8080/xwiki/bin/view/Main/] INFO .HibernateDataMigrationManager - No storage migration required since current version is [40001] Exception in thread "Thread-17" java.lang.NoClassDefFoundError: Failed to get fields for class [org.xwiki.git.internal.GitScriptService] because the class [org/eclipse/jgit/lib/Repository] couldn't be found in the ClassLoader. at org.xwiki.component.util.ReflectionUtils.getAllFields(ReflectionUtils.java:70) at org.xwiki.component.annotation.ComponentDescriptorFactory.createComponentDescriptor(ComponentDescriptorFactory.java:132) at org.xwiki.component.annotation.ComponentDescriptorFactory.createComponentDescriptors(ComponentDescriptorFactory.java:105) at org.xwiki.component.annotation.ComponentAnnotationLoader.register(ComponentAnnotationLoader.java:164) at org.xwiki.component.annotation.ComponentAnnotationLoader.initialize(ComponentAnnotationLoader.java:139) at org.xwiki.extension.jar.internal.handler.JarExtensionHandler.loadComponents(JarExtensionHandler.java:145) at org.xwiki.extension.jar.internal.handler.JarExtensionHandler.install(JarExtensionHandler.java:102) at org.xwiki.extension.handler.internal.DefaultExtensionHandlerManager.install(DefaultExtensionHandlerManager.java:80) at org.xwiki.extension.job.internal.InstallJob.installExtension(InstallJob.java:208) at org.xwiki.extension.job.internal.InstallJob.applyAction(InstallJob.java:263) at org.xwiki.extension.job.internal.InstallJob.start(InstallJob.java:161) at org.xwiki.job.AbstractJob.start(AbstractJob.java:134) at org.xwiki.job.internal.DefaultJobManager.run(DefaultJobManager.java:156) at java.lang.Thread.run(Thread.java:680) {noformat}

    XWiki.org JIRA | 5 years ago | Vincent Massol
    java.lang.NoClassDefFoundError: Failed to get fields for class [org.xwiki.git.internal.GitScriptService] because the class [org/eclipse/jgit/lib/Repository] couldn't be found in the ClassLoader.

    Root Cause Analysis

    1. java.lang.NoClassDefFoundError

      Failed to get fields for class [org.xwiki.git.internal.GitScriptService] because the class [org/eclipse/jgit/lib/Repository] couldn't be found in the ClassLoader.

      at org.xwiki.component.util.ReflectionUtils.getAllFields()
    2. org.xwiki.component
      ComponentAnnotationLoader.initialize
      1. org.xwiki.component.util.ReflectionUtils.getAllFields(ReflectionUtils.java:70)
      2. org.xwiki.component.annotation.ComponentDescriptorFactory.createComponentDescriptor(ComponentDescriptorFactory.java:132)
      3. org.xwiki.component.annotation.ComponentDescriptorFactory.createComponentDescriptors(ComponentDescriptorFactory.java:105)
      4. org.xwiki.component.annotation.ComponentAnnotationLoader.register(ComponentAnnotationLoader.java:164)
      5. org.xwiki.component.annotation.ComponentAnnotationLoader.initialize(ComponentAnnotationLoader.java:139)
      5 frames
    3. org.xwiki.extension
      InstallJob.start
      1. org.xwiki.extension.jar.internal.handler.JarExtensionHandler.loadComponents(JarExtensionHandler.java:145)
      2. org.xwiki.extension.jar.internal.handler.JarExtensionHandler.install(JarExtensionHandler.java:102)
      3. org.xwiki.extension.handler.internal.DefaultExtensionHandlerManager.install(DefaultExtensionHandlerManager.java:80)
      4. org.xwiki.extension.job.internal.InstallJob.installExtension(InstallJob.java:208)
      5. org.xwiki.extension.job.internal.InstallJob.applyAction(InstallJob.java:263)
      6. org.xwiki.extension.job.internal.InstallJob.start(InstallJob.java:161)
      6 frames
    4. org.xwiki.job
      DefaultJobManager.run
      1. org.xwiki.job.AbstractJob.start(AbstractJob.java:134)
      2. org.xwiki.job.internal.DefaultJobManager.run(DefaultJobManager.java:156)
      2 frames
    5. Java RT
      Thread.run
      1. java.lang.Thread.run(Thread.java:680)
      1 frame