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

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.

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.

Related

Need help on publishing xml report with the plugin parasoft findings in TeamCity

I added a build step for my project in teamcity which consists on using the plugin Parasoft Findings to publish an XML report of all the code violations. the problem is that teamcity is failing to parse XML report. It says there is an unexpected report format and to see log (which I couldn't find).
I already checked the report location pattern which is right. I don't use SOAtest but C++ test so I only put "Parasof analyzers 10.x" for the report type
I'm sorry but you did not provide any additional details regarding your question and it's hard to help you.
Please, provide:
error message
your configuration of build step and version of TeamCity and C++test
command line used to start C++test ( if you are using variables,
replace variables with real values used in your run)
By log I think, you should check your build step log, and provide us the right content.
You can find such logs on two different ways:
You can download it by clicking "Download full build log" on build
log page (Recommended).
Try to find the raw output from the build agent by looking in the
agents logs directory, for example in
c:\TeamCity_dir_agent\logs\teamcity-build.log
Following article from JetBrains' TeamCity manual might good point to start
Edit:
Parasoft updated the plugin which fixed the issue:
https://plugins.jetbrains.com/plugin/9949-parasoft-findings
I have the same issue. Error messages in build log:
Unexpected report format: <path-to>\report.xml. See log for details.
Failed to parse XML report
Failed to parse XML report
Step test results (Parasoft Findings) failed
teamcity-agent.log and teamcity-build.log are having no entries within this build step because there is no piece of code which would write that into during this error case.
Edit/Workaround:
In the report the node <ExecutedTestsDetails> must be below the node <Exec>. The node still has the right indendation but it is at the same level as <Exec>. The xsl of TeamCity Plugin works perfectly if you fix the report xml manually.
To make it work you can add the Build Feature "File Content Replacer" like that:
Regex: (?s)(<ExecutedTestsDetails.*?<\/ExecutedTestsDetails>).*?(<Exec.*?>)
Replace with: $2 $1

Microsoft.Quantum.Canon.nuspec missing

I am playing around with Microsoft's Q# library, and I've gone through the install, however the build is failing and I am having a tough time figuring out the problem. My first suspicion is Microsoft.Quantum.Canon
EXEC : error QS1001: Assembly E:\Projects\Quantum\Microsoft.Quantum.Canon\bin\Debug\Microsoft.Quantum.Canon.dll not found
I also have noticed Microsoft.Quantum.Canon.nuspec is missing. I've tried to do a Nuget.exe restore on the solutions but that did not work.
Has anyone worked through this?
It's been reported on GitHub already, although it appears to be intentional. See the comments in the .gitignore file:
# These files are generated by bootstrap from a .v.template (version template).
# Any changes must be done to the corresponding the .v.template file directly
Microsoft.Quantum.Canon/Microsoft.Quantum.Canon.nuspec
I can't find any info on this .v.template file, probably it's part of internal Microsoft build tooling. You can copy the template file and fill in the missing parameters if you wish, but the file not existing doesn't make the build fail , does it?

Error in NS2 debugging using Eclipse: "Cant find a source file at... "

I am trying to debug NS-2.34 using Eclipse Luna 4.4.2 under Ubuntu 13.10, and I had successfully configured NS2 and Eclipse for debugging by following the instructions from here "https://erl1.wordpress.com/2012/01/11/using-ns-2-with-eclipse/." The problem is, when I start debugging, debugging will not continue due to the error
Can't find a source file at "/build/buildd/eglibc-2/17/elf/dl-debug.c"
Locate the file or edit the source lookup path to include its location
I tried to locate the file in my system but I can't seem to figure that part out. How can I solve this error?
I think that's one of the many reasons why a lot of people transfer from NS2 to NS3 when they find that the module they would like to use is available in NS3.
For your problem, the page you are referring to has been a long time ago and there might be conflicts caused by new version.
For me, as a ns2er, when I modified some code or add new files, I just do "make" command and see what I got in the terminal. It works in most of the time.
Cheers,
Zeyu

Eclipse Repositories fail "Unable to read repository at"

I generally don't use Eclipse, so perhaps I'm doing something wrong, but I've spent several hours going over this and can't find a problem.
I needed a plugin for Eclipse (PigEditor or PigPen) and attempted to install it via repository, this failed with the error below. When it wouldn't install, I downloaded the .zip version, extracted the archive, found the folder containing features and plugins directory and tried installing it. This also failed. I also tried a PigPen .jar and it wasn't picked up at all when placing it into the plugins folder.
I noticed along the way that I received a bunch of error messages where it looked like Eclipse was trying to fetch dependencies. For example...
Error
Unable to read repository at http://download.eclipse.org/eclipse/updates/4.3.
java.io.IOException: http://download.eclipse.org/eclipse/updates/4.3 is not a valid repository location.
That -should- be a valid repository location, it's listed about halfway down here. This unable to read repository is the same error that I got when trying to install the previous plugin from repository.
I then went to the Preferences -> Available Software Sites and tried all of the default installed repositories. There were 2 checked (the one listed above, and http://download.eclipse.org/releases/kepler) and 2 unchecked (http://download.eclipse.org/egit/updates and http://www.eclipse.org/modeling/updates). I hit reload on any of those and receive the same error message as above.
I can access websites from the internal browser. I've also tried changing my Network Connections preference to "Direct".
Really all I care about is getting a working Pig plugin, so I'll accept that as an answer. I'm getting the feeling though that my failure to get any repositories is a symptom of a bigger problem (and I really want to know what's going on), so if you have troubleshooting steps I'm willing to try anything.
Sites I'm trying to get the Pig editor from:
https://wiki.apache.org/pig/PigPen
http://romainr.github.io/PigEditor/
https://github.com/romainr/PigEditor
Solution :
Open up .exe eclipse file from command promtp followed by command -vmargs -Djava.net.preferIPv4Stack=true
or
changed in eclipse.init file.

Build error with PostSharp 2.1.6 (NuGet)

I am evaluating PostSharp for a new project but cannot seem to get past the following error when I first build the project after changes:
Cannot copy file "C:\SourcePath\Output\Debug\MyApp.vshost.exe to
obj\Debug\Before-PostSharp\MyApp.vshost.exe: the file is locked by
process(es):MYAPP.VSHOST (8064)
The error only occurs in the first build attempt. If I immediately re-build, the error does not occur. I can only guess this is because the project isn't actually being rebuilt the second time.
I've read a few posts in the SharpCrafters forum that indicate this problem existed prior to v2.1 but was reportedly fixed. I am using v2.1.6.14 from NuGet (in VS 2010) and getting this error for every project I reference PostSharp. It is certainly not reasonable to require 2 builds every time, so I'm looking for a possible solution. I'm really pleased with what I've seen thus far but will have to go another direction if that can't be resolved.
UPDATE
Per Gael's request, I generated the diagnostic build log and sent it to him and it looks like he was able to resolve the problem in the latest release (2.1.6.14).
I believe part (or all) of the issue may be due to the fact that the build output for all of my projects is set to a common location (i.e. not the /bin/debug folder under each project). This is because we are using a MEF DirectoryCatalog which will discover Imports and Exports contained in the assemblies located in the output path. The PostSharp.targets file has the vshost.exe file excluded from the copy operation but only when it shares the name of the output assembly. In my case, the vshost.exe file has a different name and was, therefore, not being excluded.
The issue has been re-fixed in PostSharp 2.1.6.15.