Results 1 to 2 of 2

Thread: RC3: bad version numer in scripts

  1. #1
    Join Date
    Oct 2009
    Location
    Munich, Germany
    Posts
    103

    Exclamation RC3: bad version numer in scripts

    Hi,

    i tried the example script vote and wedding with the RC3, but I always get an exception:

    java.lang.UnsupportedClassVersionError: Bad version number in .class file

    Any java version issues around? I tried both compiling with 1.5 and 1.6 but no success. Any ideas?

    Code:
    Caused by: java.lang.UnsupportedClassVersionError: Bad version number in .class file
            at java.lang.ClassLoader.defineClass1(Native Method)
            at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
            at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
            at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
            at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
            at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
            at java.security.AccessController.doPrivileged(Native Method)
            at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
            at org.mortbay.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:366)
            at org.mortbay.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:337)
            at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
            at java.lang.Class.forName0(Native Method)
            at java.lang.Class.forName(Class.java:242)
            at org.hibernate.util.ReflectHelper.classForName(ReflectHelper.java:112)
            at org.hibernate.ejb.Ejb3Configuration.classForName(Ejb3Configuration.java:1008)
            at org.hibernate.ejb.Ejb3Configuration.addNamedAnnotatedClasses(Ejb3Configuration.java:1080)
            at org.hibernate.ejb.Ejb3Configuration.addClassesToSessionFactory(Ejb3Configuration.java:871)
            at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:758)
            at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:425)
            at org.hibernate.ejb.HibernatePersistence.createContainerEntityManagerFactory(HibernatePersistence.java:131)
            at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalCont
    ainerEntityManagerFactoryBean.java:225)
            at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryB
    ean.java:288)
    ...
    Cheers,
    Fireball

  2. #2
    Join Date
    Mar 2009
    Location
    Munich. Germany
    Posts
    15

    Default

    If you run through the eclipse then check the maven jdk path. You get the exception because you are trying to run the application through the lower version jdk than compile version of jdk.

    Regards,
    Mamun

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •