Search code examples
eclipsetomcatubuntuunsupported-class-version

java.lang.UnsupportedClassVersionError: org/openbravo/base/ConnectionProviderContextListener : Unsupported major.minor version 52.0


I am using Eclipse Indigo running on Ubuntu and I am trying to set up a Tomcat server following the last part of this guide:

http://wiki.openbravo.com/wiki/How_to_setup_Eclipse_IDE

My problem is that when I try to boot the Tomcat server I get this error (Server Tomcat v6.0 Server at localhost failed to start.):

enter image description here

My console looks like this:

Caused by: java.lang.UnsupportedClassVersionError: org/openbravo/base/ConnectionProviderContextListener : Unsupported major.minor version 52.0 (no puedo cargar clase org.openbravo.base.ConnectionProviderContextListener)
    at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2822)
    at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1159)
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1647)
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1526)
    at org.apache.catalina.startup.WebAnnotationSet.loadClassAnnotation(WebAnnotationSet.java:145)
    at org.apache.catalina.startup.WebAnnotationSet.loadApplicationListenerAnnotations(WebAnnotationSet.java:73)
    at org.apache.catalina.startup.WebAnnotationSet.loadApplicationAnnotations(WebAnnotationSet.java:56)
    at org.apache.catalina.startup.ContextConfig.applicationAnnotationsConfig(ContextConfig.java:297)
    at org.apache.catalina.startup.ContextConfig.start(ContextConfig.java:1078)
    at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:261)
    at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:142)
    at org.apache.catalina.core.StandardContext.start(StandardContext.java:4611)
    at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
    at org.apache.catalina.core.StandardHost.start(StandardHost.java:840)
    at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
    at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:463)
    at org.apache.catalina.core.StandardService.start(StandardService.java:525)
    at org.apache.catalina.core.StandardServer.start(StandardServer.java:754)
    at org.apache.catalina.startup.Catalina.start(Catalina.java:595)
    ... 6 more

What can I do? I tryed adding tomcat-juli.jar to my server classpath, which is the main solution I have found but it didn't work.

Thanks in advance.


EDIT:

Thanks to the answer Tomcat starts but does not make the resource available. There are compilation errors in the Openbravo projects as well.

Eclipse Openbravo Project

Resource not available at localhost:8080/openbravo/

Tomcat Configuration in Eclipse


2nd EDIT:

enter image description here

Deploy Tree


Solution

  • Update your JDK version. The classes were probably compiled in a JDK version higher to yours.

    Edit: Probably it is JDK/JRE 8.