Project

General

Profile

Defect #804

Cannot compile report when using Java 8

Added by Rossen Totev about 10 years ago. Updated almost 10 years ago.

Status:
Closed
Priority:
Immediate
Start date:
04/14/2014
Due date:
% Done:

0%

Estimated time:
Browser (if web client):

Description

Cannot compile reports when using Java 8. Getting the following error:

Error: JavaException: java.lang.Exception: Errors were encountered when compiling report expressions class file:
1. The type java.util.Map$Entry cannot be resolved. It is indirectly referenced from required .class files

History

#1

Updated by Rossen Totev about 10 years ago

The problem started after updating to Java 8. The rest of Servoy Server, Servoy Developer and Servoy Clients work fine - only the reports are affected.

#2

Updated by Rossen Totev about 10 years ago

Correction for the "Component version" above - the version of the plugin which was used when getting the error is: 4.0.2 beta 1

The method which fails is: compileReport

Here is how it is used in Servoy:

plugins.jasperPluginRMI.compileReport(<some_report_file.jrxml>)

See also: https://www.servoy.com/forum/viewtopic.php?f=15&t=20262

#3

Updated by Rossen Totev about 10 years ago

The problem is in the used version of the JDT Compiler.
Upgrading it to ecj-4.3.1.jar resolves the issue.
Please, update the plugin distribution package accordingly.

#4

Updated by Andrei Costache almost 10 years ago

  • Status changed from New to In Progress
  • Assignee set to Andrei Costache
#5

Updated by Andrei Costache almost 10 years ago

  • Component version changed from 4.2.0-b1 to 4.0.2-b1
#6

Updated by Andrei Costache almost 10 years ago

Hi Rossen,

I am not seeing this: compilation, report running work fine in my case (Java 8 for Mac application server and Windows 7 smart/web client). I have tested this with the 4.0.2 b1 version of the plugin and Servoy 7.4. Are you using something specific to Java 8 in your report? Could you please upload a sample report that you get this problem with?

Also, I am not sure about updating the jdt-compiler: it has not changed even in the latest jasperreports 5.5.1. That would need some thorough testing for the entire plugin distribution.

Moreover, I am not sure Jasperreports itself is 100% ready for Java 8; specially not sure about version 4.6 on which the currenty 4.0.2 plugin is based on. The people at Jasper say that ireport or jasper server do not support java 8 (jasper reports studio does, but not sure that is an option with the 4.0.2 b1 version of the plugin.. will be with the trunk, the new version). See http://community.jaspersoft.com/questions/824715/ireport-compatibility-java8, http://community.jaspersoft.com/questions/825539/jasper-server-and-java-18-error-during-server-startup.
What is interesting is that it seems compiling should itself work (http://community.jaspersoft.com/jasperreports-server/issues/3498)-then again, this is linked to jasperreports Server.

I will update this case with more info.

Regards,
Andrei

#7

Updated by Rossen Totev almost 10 years ago

The newer version of the ecj jar is needed in our case because a few other plugins which we use require it. Manually updating & resigning it resolves the issue for us and so far we have had no problems running the JasperReports on Java 8. Yes, the iReport designer does not work with Java 8 so we have to use the new Jaspersoft Studio for designing the reports (considering that the iReport designer is now in maintenance mode only and that the Jaspersoft (now TIBCO :-) guys explicitly say that the Jaspersoft Studio is from now on the official design tool for the Jasper reports I think that it sooner or later everyone will move to the new designer)

Unfortunately there are some new features and changes which have been introduced in 5.5.1 which require sometime to manually tinker with the .jrxml file to make it usable with the Servoy JasperReports plugin (specifically, we need to remove some of the new properties which the Jaspersoft Studio is adding to the .jrxml) What are the plans of updating the Servoy plugin to a newer version of the JasperReports engine?

#8

Updated by Andrei Costache almost 10 years ago

  • Status changed from In Progress to Closed

Hi Rossen,

First, regarding the ecj jar: if needed by other plugins, you can update/modify libraries at will, but also at your own risk :). From our tests, compiling, running reports works fine, as noted in my previous answer. We will not modify the distribution of the 4.x plugin version, for the ecj library. This may cause unwanted side-effects regarding the standard Jasper library set, Servoy and the plugin usage.

Secondly, upgrading the Jasper 5.5.1 in a new version of the plugin is in progress (you already know: https://www.servoyforge.net/issues/780). It is soon (coming days) to be released. Again, there is no official "say" on the Java 8 topic from Jasper, apart from what has already been mentioned above, in the urls I provided. From my testing, the soon to come plugin works with Java 8 as well. But the recommendation is Java 7, because of Jasper.
The people at Jasper have already said some months ago that JasperSoft Studio should be used, for versions 5.5.1 and up of their library. So this new Servoy-Jasper plugin version will be used with "Studio".

Please keep an eye on https://www.servoyforge.net/issues/780.

Best regards,
Andrei

Also available in: Atom PDF