Is there a way to support opencmis 1.1 with Java 6 for connecting to Alfresco CMS?

144 Views Asked by At

I'm getting below error when connecting opencmis 1.1 with Java 6.

    Exception in thread "main" java.lang.UnsupportedClassVersionError: JVMCFRE003 bad major 
    version; class=org/apache/chemistry/opencmis/client/api/SessionFactory, offset=6
    at java.lang.ClassLoader.defineClassImpl(Native Method)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:265)
    at java.security.SecureClassLoader.defineClass(Unknown Source)
    at java.net.URLClassLoader.defineClass(URLClassLoader.java:493)
    at java.net.URLClassLoader.access$300(URLClassLoader.java:64)
1

There are 1 best solutions below

0
e.g78 On

The problem is you're using a library compiled for a superior java version. Anyway you can download the sources (https://www.apache.org/dyn/closer.lua/chemistry/opencmis/1.1.0/chemistry-opencmis-1.1.0-source-release.zip) and compile it targeting java 1.6, just modifying pom.xml :

<maven.compile.target>1.6</maven.compile.target>

You can also take a look here : https://issues.apache.org/jira/browse/CMIS-1022