Search code examples
jasper-reportsjasperservericinga2

Jasper reports 6 & Icinga2 unable to resolve class org.icinga.reporting.DateHelper


I have installed Jasper reports server 6.3.0 along with Icinga-reporting (from the git repo)

I can run sample reports without any problem, but when I try and run specific Icinga reports which have a time period they fail and error out with;

Errors were encountered when compiling report expressions class file: org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed: calculator_Service32activity32report32in32given32time_1484836971660_629753: 13: unable to resolve class org.icinga.reporting.DateHelper @ line 13, column 1. 1 error .

If you want the full stack trace please leave a comment and I will update the question.

I have done lots of googleing and have found afew links which reference the issue, but no one has actually said in (still valid) steps how to resolve the problem.

This looks like the closest fit - but the info referenced no longer exists (The entire Icinga wiki has been removed!)

I also found this but it links to very old jars which I've included in the WEB-INF/lib path but still getting the same error.

If I run a report that does not have a time/date then the report works (So I know Jasper is actually working)

If you need any additional info please leave a comment & I will update the question.


Solution

  • The problem turned out to be cause by icinga-reporting.jar missing from the tomcat WEB-INF/lib/ folder.

    When you build icinga-reporting.jar it includes the org.icinga.reporting.DateHelper functions that where the cause of the original error.

    When I installed the reporting the post deployment scripts where run and I'm sure it had copied the .jar file to the correct path, but when I later searched for it it was missing...

    Manually copying the file to the correct path resolved the issue & reports with a time/date element now run without errors.