java.lang.NoClassDefFoundError: org/springframework/roo/project/Dependency

Spring JIRA | Scott Murphy | 6 years ago
  1. 0

    When I hit this line of code: if (!(project.getDependenciesExcludingVersion(new Dependency("org.codeconsole", "webapp-analytics", "0.5.9")).size() == 0)) { I get the following exception: Exception in thread "Spring Roo JLine Shell" java.lang.NoClassDefFoundError: org/springframework/roo/project/Dependency at org.codeconsole.roo.addon.webappanalytics.AnalyticsOperationsImpl.isInstallAnalyticsAvailable(AnalyticsOperationsImpl.java:68) at org.codeconsole.roo.addon.webappanalytics.AnalyticsCommands.analyticsInfo(AnalyticsCommands.java:48) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.springframework.roo.support.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:191) at org.springframework.roo.process.manager.ProcessManagerHostedExecutionStrategy$1.callback(ProcessManagerHostedExecutionStrategy.java:49) at org.springframework.roo.process.manager.internal.DefaultProcessManager.doTransactionally(DefaultProcessManager.java:180) at org.springframework.roo.process.manager.internal.DefaultProcessManager.execute(DefaultProcessManager.java:143) at org.springframework.roo.process.manager.ProcessManagerHostedExecutionStrategy.execute(ProcessManagerHostedExecutionStrategy.java:47) at org.springframework.roo.shell.AbstractShell.executeCommand(AbstractShell.java:165) at org.springframework.roo.shell.jline.JLineShell.promptLoop(JLineShell.java:358) at org.springframework.roo.shell.jline.JLineShell.run(JLineShell.java:132) at java.lang.Thread.run(Thread.java:680) This only happens in 1.1.2. I do not get the exception <= 1.1.1 I have <dependency> <groupId>org.springframework.roo</groupId> <artifactId>org.springframework.roo.project</artifactId> <version>${roo.version}</version> <type>bundle</type> </dependency> specified in my pom file.

    Spring JIRA | 6 years ago | Scott Murphy
    java.lang.NoClassDefFoundError: org/springframework/roo/project/Dependency
  2. 0

    When I hit this line of code: if (!(project.getDependenciesExcludingVersion(new Dependency("org.codeconsole", "webapp-analytics", "0.5.9")).size() == 0)) { I get the following exception: Exception in thread "Spring Roo JLine Shell" java.lang.NoClassDefFoundError: org/springframework/roo/project/Dependency at org.codeconsole.roo.addon.webappanalytics.AnalyticsOperationsImpl.isInstallAnalyticsAvailable(AnalyticsOperationsImpl.java:68) at org.codeconsole.roo.addon.webappanalytics.AnalyticsCommands.analyticsInfo(AnalyticsCommands.java:48) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.springframework.roo.support.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:191) at org.springframework.roo.process.manager.ProcessManagerHostedExecutionStrategy$1.callback(ProcessManagerHostedExecutionStrategy.java:49) at org.springframework.roo.process.manager.internal.DefaultProcessManager.doTransactionally(DefaultProcessManager.java:180) at org.springframework.roo.process.manager.internal.DefaultProcessManager.execute(DefaultProcessManager.java:143) at org.springframework.roo.process.manager.ProcessManagerHostedExecutionStrategy.execute(ProcessManagerHostedExecutionStrategy.java:47) at org.springframework.roo.shell.AbstractShell.executeCommand(AbstractShell.java:165) at org.springframework.roo.shell.jline.JLineShell.promptLoop(JLineShell.java:358) at org.springframework.roo.shell.jline.JLineShell.run(JLineShell.java:132) at java.lang.Thread.run(Thread.java:680) This only happens in 1.1.2. I do not get the exception <= 1.1.1 I have <dependency> <groupId>org.springframework.roo</groupId> <artifactId>org.springframework.roo.project</artifactId> <version>${roo.version}</version> <type>bundle</type> </dependency> specified in my pom file.

    Spring JIRA | 6 years ago | Scott Murphy
    java.lang.NoClassDefFoundError: org/springframework/roo/project/Dependency
  3. 0

    At the moment we are using org/springframework/roo/support/util/ReflectionUtils (in TextHandler.publish, for example). Since Spring Roo has replaced this class and is using (and shipping) commons-lang3 libs for that, we should adapt to those libs as well (to allow Roo to remove that old ReflectionUtils class). This should be done for the Spring Roo 1.3.0 adapter only, not for 1.2.1 or previous Roo versions. Here are some details from Alan: Can I please request that for future STS releases that you change the code to remove STS's dependency on this class? The same functionality is available in the commons-lang3 FieldUtils, MethodUtils, and ClassUtils classes. java.lang.NoClassDefFoundError: org/springframework/roo/support/util/ReflectionUtils at org.springframework.roo.shell.eclipse.TextHandler.publish(TextHandler.java:51) at java.util.logging.Logger.log(Logger.java:478) at java.util.logging.Logger.doLog(Logger.java:500) at java.util.logging.Logger.log(Logger.java:523) at java.util.logging.Logger.info(Logger.java:1042) at org.springframework.roo.shell.eclipse.EclipseShell.init(EclipseShell.java:139) at sun.reflect.GeneratedMethodAccessor238.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.springframework.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:191) at org.springframework.ide.eclipse.core.java.ClassUtils.invokeMethod(ClassUtils.java:136) at org.springframework.roo.shell.eclipse.Bootstrap.initShell(Bootstrap.java:557) at org.springframework.roo.shell.eclipse.Bootstrap.access$2(Bootstrap.java:545) at org.springframework.roo.shell.eclipse.Bootstrap$RooShellStartupMonitor.run(Bootstrap.java:619) at java.lang.Thread.run(Thread.java:680)

    SpringSource Issue Tracker | 5 years ago | Martin Lippert
    java.lang.NoClassDefFoundError: org/springframework/roo/support/util/ReflectionUtils
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    At the moment we are using org/springframework/roo/support/util/ReflectionUtils (in TextHandler.publish, for example). Since Spring Roo has replaced this class and is using (and shipping) commons-lang3 libs for that, we should adapt to those libs as well (to allow Roo to remove that old ReflectionUtils class). This should be done for the Spring Roo 1.3.0 adapter only, not for 1.2.1 or previous Roo versions. Here are some details from Alan: Can I please request that for future STS releases that you change the code to remove STS's dependency on this class? The same functionality is available in the commons-lang3 FieldUtils, MethodUtils, and ClassUtils classes. java.lang.NoClassDefFoundError: org/springframework/roo/support/util/ReflectionUtils at org.springframework.roo.shell.eclipse.TextHandler.publish(TextHandler.java:51) at java.util.logging.Logger.log(Logger.java:478) at java.util.logging.Logger.doLog(Logger.java:500) at java.util.logging.Logger.log(Logger.java:523) at java.util.logging.Logger.info(Logger.java:1042) at org.springframework.roo.shell.eclipse.EclipseShell.init(EclipseShell.java:139) at sun.reflect.GeneratedMethodAccessor238.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.springframework.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:191) at org.springframework.ide.eclipse.core.java.ClassUtils.invokeMethod(ClassUtils.java:136) at org.springframework.roo.shell.eclipse.Bootstrap.initShell(Bootstrap.java:557) at org.springframework.roo.shell.eclipse.Bootstrap.access$2(Bootstrap.java:545) at org.springframework.roo.shell.eclipse.Bootstrap$RooShellStartupMonitor.run(Bootstrap.java:619) at java.lang.Thread.run(Thread.java:680)

    SpringSource Issue Tracker | 5 years ago | Martin Lippert
    java.lang.NoClassDefFoundError: org/springframework/roo/support/util/ReflectionUtils
  6. 0

    NoClassDefFoundError in Spark Submit

    Stack Overflow | 10 months ago | Alok
    java.lang.NoClassDefFoundError: org/springframework/util/StringUtils

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.NoClassDefFoundError

      org/springframework/roo/project/Dependency

      at org.codeconsole.roo.addon.webappanalytics.AnalyticsOperationsImpl.isInstallAnalyticsAvailable()
    2. org.codeconsole.roo
      AnalyticsCommands.analyticsInfo
      1. org.codeconsole.roo.addon.webappanalytics.AnalyticsOperationsImpl.isInstallAnalyticsAvailable(AnalyticsOperationsImpl.java:68)
      2. org.codeconsole.roo.addon.webappanalytics.AnalyticsCommands.analyticsInfo(AnalyticsCommands.java:48)
      2 frames
    3. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      4. java.lang.reflect.Method.invoke(Method.java:597)
      4 frames
    4. org.springframework.roo
      JLineShell.run
      1. org.springframework.roo.support.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:191)
      2. org.springframework.roo.process.manager.ProcessManagerHostedExecutionStrategy$1.callback(ProcessManagerHostedExecutionStrategy.java:49)
      3. org.springframework.roo.process.manager.internal.DefaultProcessManager.doTransactionally(DefaultProcessManager.java:180)
      4. org.springframework.roo.process.manager.internal.DefaultProcessManager.execute(DefaultProcessManager.java:143)
      5. org.springframework.roo.process.manager.ProcessManagerHostedExecutionStrategy.execute(ProcessManagerHostedExecutionStrategy.java:47)
      6. org.springframework.roo.shell.AbstractShell.executeCommand(AbstractShell.java:165)
      7. org.springframework.roo.shell.jline.JLineShell.promptLoop(JLineShell.java:358)
      8. org.springframework.roo.shell.jline.JLineShell.run(JLineShell.java:132)
      8 frames
    5. Java RT
      Thread.run
      1. java.lang.Thread.run(Thread.java:680)
      1 frame