Jump to content
We've recently updated our Privacy Statement, available here ×

JasperStudio dataAdapter uses JDK8, JDK11 is needed


richard.w.leir

Recommended Posts

Hi team

I have some class files  exported from PTC Windchill 12.0.2. (Windchill used Java11).

Jasper Studio data adapter seems to use JDK8 to compiles some Java using Windchill's exported class files and gives this error:

java.lang.UnsupportedClassVersionError: com/ptc/wbr/datasource/providers/Site_PartReportWNCProvider has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:763)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:467)
at java.net.URLClassLoader.access$100(URLClassLoader.java:73)
at java.net.URLClassLoader$1.run(URLClassLoader.java:368)
at java.net.URLClassLoader$1.run(URLClassLoader.java:362)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:361)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at java.net.FactoryURLClassLoader.loadClass(URLClassLoader.java:814)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at net.sf.jasperreports.eclipse.classpath.JavaProjectClassLoader.findClass(JavaProjectClassLoader.java:335)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at java.lang.ClassLoader.loadClass(ClassLoader.java:411)
at java.lang.ClassLoader.loadClass(ClassLoader.java:411)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:348)
at net.sf.jasperreports.engine.util.JRClassLoader.loadClassForRealName(JRClassLoader.java:190)
at net.sf.jasperreports.data.provider.DataSourceProviderDataAdapterService.getProvider(DataSourceProviderDataAdapterService.java:92)
at com.jaspersoft.studio.data.jrdsprovider.JrdsProviderDataAdapterDescriptor.getFieldProvider(JrdsProviderDataAdapterDescriptor.java:70)
at com.jaspersoft.studio.data.jrdsprovider.JrdsProviderDataAdapterDescriptor.getFields(JrdsProviderDataAdapterDescriptor.java:55)

 

It looks as if Jasper is compiling using Java8, but the classes exported from Windchill are Java11. I have attempted to change the Jasper project to use Jdk11 but it still seems to be using JDK8.

Java11 is backwards compatible, but Jdk8 does not accept jdk11 class files.

How can I configure the dataAdapter to use Java11? What is needed to get this working?

thanks -- Rick

Link to comment
Share on other sites

  • Replies 4
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

The Community Edition - Jaspersoft Studio version 6.15.0 (2020-10-07) readme file contains : 
--------------------------------------------

- RCP stand-alone version now ships AdoptOpenJDK JRE 11.0.8

- Improved Java 11 support

Hence ensure you are using at least this version.

Also refer to:

https://community.jaspersoft.com/questions/1190481/jaspersoft-studio-using-adoptopenjdk-11-why-jre-java-18

Link to comment
Share on other sites

Hi vchiem

Yes, my version has Java11. And I have been all through the preferences, checking Java versions. In one setting it was Java8 and I changed it to Java11. But the component which creates the data adaptor still  runs Java8 despite all my efforts. I cannot find any preferences screen for that component. Where is it?

thanks

Rick

Link to comment
Share on other sites

Another workaround would be if PTC Windchill was able to export using Java8. I tried that. The PTC exporter program was compiled using Java11 so I cannot run it using Java8 

  java.lang.UnsupportedClassVersionError: com/ptc/util/wbr/export/ExportDataSource has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0[/code]

Now my big question is: in Jasper Studio 7.9.0 , how can I configure the execution environment for the dataAdaptor to run using Java11. Some help from Jaspersoft staff would be greatly appreciated!

thanks

Rick

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...